Child:...k::Proc(3pm)
π NAME π
okay bestie so Child::Link::Proc β it's the Proc object that the Child module uses. that's it. that's the whole vibe. it's a page from the User Contributed Perl Documentation collection, filed under Child::Link::Proc(3pm), and it's here to tell you everything your little process-link object can do π¦
πΈ SEE ALSO πΈ
this class inherits from:
Child::Link
like, all of that good stuff is coming down the family tree to you, no cap π
β¨ METHODS β¨
here's the whole menu, babe, every single one of them, i'm not gatekeeping:
$bool = $proc->is_complete()β asks "are you done yet?" about the child, and it does not block. it just peeks. lowkey polite. it hands you back a boolean π$proc->wait()β actually sits there and waits until the child terminates, and then it cleans up whatever zombie process is left kicking around. this one blocks, so yes it will hold up your whole flow until the child clocks out π but hey, no zombies. iconic behavior.$proc->kill($SIG)β sends the$SIGsignal to the child process. that's the move. π«Ά
β οΈ NOTE: kill() is straight up unpredictable on windows β strawberry perl will send that kill signal to the parent as well as the child. so like, not just the child. the parent too. be aware, bestie π
$proc->pid()β returns the process PID. the number. that's it. that's the whole function π$proc->exit_status()β it's gonna beundefunless the process has actually exited. once it has exited, you get the exit status, no cap.
Note: so when you call exit($N), the actual unix exit status is bit shifted with extra information added on top. exit_status() shifts that value back for you, bestie, so you don't have to do the math. which means exit_status() will return 2 when your child calls exit(2). but if you want the actual value that wait() assigned to $?, go look at unix_exit() instead. iykyk π§
$proc->unix_exit()β okay so same deal: when you callexit($N), the actual unix exit status gets bit shifted with extra information added. and if you want the actual value that was used inexit()inside the child β the real raw one β check outexit_status(). they're the two sides of the same coin, periodt π
π HISTORY π
so most of this was actually part of Parallel::Runner, and it was built for use in the Fennec project. then Fennec started getting broken up into multiple parts, and this is one such part. glow up moment β¨
π FENNEC PROJECT π
this module is part of the Fennec project. see Fennec for more details. Fennec is a project to develop an extendable and powerful testing framework, and together all the tools that make up the Fennec framework provide a potent testing environment. that's the goal, and they ate π
the tools provided by Fennec are also useful on their own, fr fr. sometimes a tool that got created for Fennec turns out to be useful outside the greater framework, and when that happens, those tools get turned into their own projects. and this is one such project. main character energy π
Fennec - The core framework
- the primary Fennec project that ties them all together π«Ά
π AUTHORS π
Chad Granum β exodist7@gmail.com
π COPYRIGHT π
Copyright (C) 2010 Chad Granum
Child is free software; Standard perl licence.
Child is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the license for more details. (yes that's the real legal vibe, don't come for me π)
and that's the whole page, bestie π¦ this was Child::Link::Proc(3pm) from perl v5.36.0, dated 2022-10-13 β go forth and wait on your children responsibly, mwah πβ¨
π¦ where this page comes from
- ubuntu noble: libchild-perl 0.013-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libchild-perl 0.013-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libchild-perl 0.013-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms