GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||
GeezerVison is showing github.com — child_process: add subprocess.timedOut by marcopiraccini · Pull Request #66639 · nodejs/node Conversation
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@ ## main #66639 +/- ## ========================================== - Coverage 92.78% 90.65% -2.13% ========================================== Files 422 797 +375 Lines 193692 278275 +84583 Branches 29881 53518 +23637 ========================================== + Hits 179718 252282 +72564 - Misses 13645 16379 +2734 - Partials 329 9614 +9285
🚀 New features to boost your workflow:
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Adding |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Failed to resume CIFull Auto Start CI output |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
#66639 (comment) |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
The cases where the timeout expires after the child exited gave the child 500 ms to start, spawn a descendant and exit, which a loaded macOS worker did not meet, so the timer killed the child instead. Let the child print the pid of the descendant and end it from the test once the timer has fired, with a timeout of three seconds. Signed-off-by: marcopiraccini <[email protected]>
The cases where the timeout expires after the child exited gave the child 500 ms to start, spawn a descendant and exit, which a loaded macOS worker did not meet, so the timer killed the child instead. Let the child print the pid of the descendant and end it from the test once the timer has fired, with a timeout of five seconds. Signed-off-by: marcopiraccini <[email protected]>
There was an error while loading. Please reload this page.
Updated, can you trigger (jenkins) ci again? @ShogunPanda ? |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
I can’t trigger Jenkins CI myself. We need a new collaborator approval. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
On Windows libuv assigns every non-detached child to the job object of its parent, which is closed when the parent exits and kills the processes it contains. The descendant that is meant to keep the stdio of the child open died with the child, so process.kill() on its pid failed with ESRCH once the timer fired. Spawn it detached, so that it outlives the child on every platform. Signed-off-by: marcopiraccini <[email protected]>
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Landed in c2591da |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
When the timeout option of spawn(), exec(), execFile() or fork() expires, the child is sent the kill signal and exits with that signal. Nothing told the caller that the timeout was the reason. Set subprocess.timedOut to true when the kill signal is sent because of the timeout, and add the same flag to the error passed to the exec() and execFile() callback. Fixes: #51561 Refs: #51608 Signed-off-by: marcopiraccini <[email protected]> PR-URL: #66639 Reviewed-By: Paolo Insogna <[email protected]>
Notable changes: child_process: * (SEMVER-MINOR) add subprocess.timedOut (Marco) #66639 crypto: * (SEMVER-MINOR) make X.509 inspection guards explicit (Filip Skokan) #67245 * (SEMVER-MINOR) add X.509 generation with CSR support (Filip Skokan) #67245 dns: * (SEMVER-MINOR) coalesce identical concurrent lookup() requests (Orgad Shaneh) #62599 doc: * add efekrskl to collaborators (Efe Karasakal) #67376 * add Philipp Dunkel to contributors (Philipp Dunkel) #67378 * add christianaurichzm to collaborators (Christian Aurich Zanettini Martins) #67377 http: * (SEMVER-MINOR) batch body spans per parser execute (Guilherme Araújo) #67187 sea: * (SEMVER-MINOR) generate a compile cache for the VFS modules (Matteo Collina) #66768 worker: * (SEMVER-MINOR) preload streams into startup snapshot (Matteo Collina) #66311 PR-URL: #67415
Notable changes: child_process: * (SEMVER-MINOR) add subprocess.timedOut (Marco) #66639 crypto: * (SEMVER-MINOR) make X.509 inspection guards explicit (Filip Skokan) #67245 * (SEMVER-MINOR) add X.509 generation with CSR support (Filip Skokan) #67245 dns: * (SEMVER-MINOR) coalesce identical concurrent lookup() requests (Orgad Shaneh) #62599 doc: * add efekrskl to collaborators (Efe Karasakal) #67376 * add Philipp Dunkel to contributors (Philipp Dunkel) #67378 * add christianaurichzm to collaborators (Christian Aurich Zanettini Martins) #67377 http: * (SEMVER-MINOR) batch body spans per parser execute (Guilherme Araújo) #67187 sea: * (SEMVER-MINOR) generate a compile cache for the VFS modules (Matteo Collina) #66768 worker: * (SEMVER-MINOR) preload streams into startup snapshot (Matteo Collina) #66311 PR-URL: #67415
When the timeout option of spawn(), exec(), execFile() or fork() expires, the child is sent the kill signal and exits with that signal. Nothing told the caller that the timeout was the reason. Set subprocess.timedOut to true when the kill signal is sent because of the timeout, and add the same flag to the error passed to the exec() and execFile() callback. Fixes: #51561 Refs: #51608 Signed-off-by: marcopiraccini <[email protected]> PR-URL: #66639 Reviewed-By: Paolo Insogna <[email protected]>
Notable changes: child_process: * (SEMVER-MINOR) add subprocess.timedOut (Marco) #66639 doc: * add efekrskl to collaborators (Efe Karasakal) #67376 * add Philipp Dunkel to contributors (Philipp Dunkel) #67378 * add christianaurichzm to collaborators (Christian Aurich Zanettini Martins) #67377 fs: * (SEMVER-MINOR) add mkstemp() (Marco) #66484 http: * (SEMVER-MINOR) batch body spans per parser execute (Guilherme Araújo) #67187 lib: * (SEMVER-MINOR) speed up AbortSignal (Robert Nagy) #66789 module: * (SEMVER-MINOR) add --experimental-strip-private-modules (Marco Ippolito) #63869 process: * (SEMVER-MINOR) return unregister fn from finalization (Matteo Collina) #66482 test_runner: * use AsyncLocalStorage instead of async_hooks (Matteo Collina) #66795 * (SEMVER-MINOR) add mockReturnValue and promise helpers (Guilherme Araújo) #66631 worker: * (SEMVER-MINOR) preload streams into startup snapshot (Matteo Collina) #66311 zlib: * (SEMVER-MINOR) add crc32c (Philipp Dunkel) #66828 PR-URL: #67664
Notable changes: child_process: * (SEMVER-MINOR) add subprocess.timedOut (Marco) #66639 doc: * add efekrskl to collaborators (Efe Karasakal) #67376 * add Philipp Dunkel to contributors (Philipp Dunkel) #67378 * add christianaurichzm to collaborators (Christian Aurich Zanettini Martins) #67377 fs: * (SEMVER-MINOR) add mkstemp() (Marco) #66484 http: * (SEMVER-MINOR) batch body spans per parser execute (Guilherme Araújo) #67187 lib: * (SEMVER-MINOR) speed up AbortSignal (Robert Nagy) #66789 module: * (SEMVER-MINOR) add --experimental-strip-private-modules (Marco Ippolito) #63869 process: * (SEMVER-MINOR) return unregister fn from finalization (Matteo Collina) #66482 test_runner: * use AsyncLocalStorage instead of async_hooks (Matteo Collina) #66795 * (SEMVER-MINOR) add mockReturnValue and promise helpers (Guilherme Araújo) #66631 worker: * (SEMVER-MINOR) preload streams into startup snapshot (Matteo Collina) #66311 zlib: * (SEMVER-MINOR) add crc32c (Philipp Dunkel) #66828 PR-URL: #67664
When the timeout option of spawn(), exec(), execFile() or fork() expires, the child is sent the kill signal and exits with that signal. Nothing told the caller that the timeout was the reason. Set subprocess.timedOut to true when the kill signal is sent because of the timeout, and add the same flag to the error passed to the exec() and execFile() callback. Fixes: nodejs#51561 Refs: nodejs#51608 Signed-off-by: marcopiraccini <[email protected]> PR-URL: nodejs#66639 Reviewed-By: Paolo Insogna <[email protected]>
Notable changes: child_process: * (SEMVER-MINOR) add subprocess.timedOut (Marco) nodejs#66639 crypto: * (SEMVER-MINOR) make X.509 inspection guards explicit (Filip Skokan) nodejs#67245 * (SEMVER-MINOR) add X.509 generation with CSR support (Filip Skokan) nodejs#67245 dns: * (SEMVER-MINOR) coalesce identical concurrent lookup() requests (Orgad Shaneh) nodejs#62599 doc: * add efekrskl to collaborators (Efe Karasakal) nodejs#67376 * add Philipp Dunkel to contributors (Philipp Dunkel) nodejs#67378 * add christianaurichzm to collaborators (Christian Aurich Zanettini Martins) nodejs#67377 http: * (SEMVER-MINOR) batch body spans per parser execute (Guilherme Araújo) nodejs#67187 sea: * (SEMVER-MINOR) generate a compile cache for the VFS modules (Matteo Collina) nodejs#66768 worker: * (SEMVER-MINOR) preload streams into startup snapshot (Matteo Collina) nodejs#66311 PR-URL: nodejs#67415
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
Know when a process ended due to thechild_process.spawn() timeout option
There was an error while loading. Please reload this page.