Skip to content

Explicitly state that a spawned process can live longer than its pare… - #4821

Merged
coke merged 1 commit into
Raku:mainfrom
ash:async-proc-stays-live
Aug 25, 2026
Merged

coke merged 1 commit into
Raku:mainfrom
ash:async-proc-stays-live

Conversation

@ash

@ash ash commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

The problem

Documentation does not explain if the child should overlive its parent here:

Proc::Async.new(
    'sleep', '1000'
).start;

Solution provided

Rakudo answers by saying "yes". If you create a long-living process using Proc::Async, and the main program quits earlier than its child, the child stays alive.

Let's add some clarity to the documentation.

The documentation gap discovered while working on ash/rakupp#29

…nt program.

It looks like this particular behaviour is not documented. If you create a long-living process
using Proc::Async, and the main program quits earlier than its child, do we expect it must keep it running?

Current Rakudo behaviour says yes.

    Proc::Async.new(
        'sleep', '1000'
    ).start;

Let's add some clarity to the documentation.

The documentation gap discovered while working on ash/rakupp#29
@coke
coke merged commit 0fbe383 into Raku:main Aug 25, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants