fix(dsh-plugin): bound output draining after child exit - #278
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
When a bsk child exits without emitting
close, the plugin keeps waiting even after its command timeout: cancellation sees an exited process and cannot settle the pending run. A successfully created browser session can consequently remain absent from the plugin registry.Allow one second to drain trailing stdout/stderr after
exit, then release the remaining pipes and complete with the observed exit code and cancellation state. Normalclosestill completes immediately, and the existing cooperative cancellation and force-kill grace periods are preserved. Shared settlement cleanup clears all timers and prevents late events from completing a run twice.Validation:
closeevents still allowed 5/5 complete tool-pipeline start/list/stop cycles (1.40–1.65 seconds for start). Under the same injected condition, the unmodified npm package remained pending and its session list was empty.Refs #180. This fixes the confirmed missing-close completion gap; it does not claim that Windows or ConPTY naturally loses the event. Scope is limited to the runner and its regression tests.