[release/10.0] Re-add default value on ProcessTerminationTimeout#2674
Merged
jeffhandley merged 1 commit intodotnet:release/10.0from Aug 29, 2025
Merged
[release/10.0] Re-add default value on ProcessTerminationTimeout#2674jeffhandley merged 1 commit intodotnet:release/10.0from
jeffhandley merged 1 commit intodotnet:release/10.0from
Conversation
Co-authored-by: Michael Atkisson <mpatkisson@triptacular.com>
ViktorHofer
approved these changes
Aug 28, 2025
Member
Author
|
@artl93 I would like to backport this simple bug fix to 10 RC2. To tell the long story short we have removed the default timeout in Preview 7 and this PR is adding it back. |
artl93
approved these changes
Aug 28, 2025
jeffhandley
approved these changes
Aug 29, 2025
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.
Customer Impact
The preview 7 and later releases of System.CommandLine included an API change that resulted in default cancellation behaviors for System.CommandLine-based applications changing. in preview6 and earlier, the library was configured so that Ctrl+C would cause a
System.OperationCanceledExceptionto be thrown, giving user code a simple hook to catch and react to that. Preview 7 and later dropped this behavior unintentionally, causing some users to report that their cleanup/cancellation code was no longer being triggered.How was it found
An external user, @mpatkisson, discovered the issue, did detailed investigation and analysis in #2671, and then contributed a fix in #2672.
Risk
Low. The existing cancellation mechanisms in use are under test, but we did not have a test that covers the documented 2s cancellation default behavior, to ensure we didn't regress it. This has been manually tested, and we will shortly add a test to the repo to prevent regressions.