feat(exec): Add support for interrupting exec using signal #1469
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
GitHub actions document the use of timeout_minutes at a step level when writing composite action.
When creating js/ts actions, it's currently not possible to implement a timeout mechanism within only a portion of an action.
This PR adds support for "AbortSignal" as per the available option in child.spawn.
Our use case is fairly straightforward, we built a GitHub action performing the following:
We want to introduce the ability to interrupt the integration tests if they are taking longer than usual. But even if the tests are interrupted, we still want to execute the rest of the action (and collect the artifacts).
The following code stops the execution of the exec call if it takes more than 5s: