Repository navigation
Change SocketException to ServerNotAvailable + misc test fixes/logging - #5354
Merged
Merged
Conversation
Trying to diagnose why the test isn't completing and the issue isn't reproing locally.
Product changes: - Connecting to the IPC channel might fail when the runtime is starting up, shutting down, or is overloaded. If so the socket.Connect() call is going to throw a SocketException. In order to avoid having callers to DiagnosticClient APIs understand all the implrementation details and have to use catch clauses for a wide variety of different exceptions we now catch this exception and rethrow it wrapped as a ServerNotAvailableException. Test changes: - Add retries to the GetProcessInfo requests that are running while the target process is starting up. There is no guarantee the runtime is listening to the socket at this point and connection requests may be refused. This may resolve one cause of flakiness noted in dotnet#2760. The issue also shows a 'ReadPastEndOfStream' problem that is not addressed by this fix. - Add verification that the ExePath returned by DebuggeeCompiler actually exists on disk. This catches some build/config issues in the test setup more eagerly. - Add verification that the BuildProjectFramework and TargetConfiguration used by SdkPrebuiltDebuggeeCompiler are populated. This catches some specific test configuration errors more eagerly. - Tweaked some out-of-date comments
Member
Author
|
PTAL @dotnet/dotnet-diag |
mdh1418
previously approved these changes
Mar 19, 2025
hoyosjs
previously approved these changes
Mar 19, 2025
Member
|
@noahfalk still good to merge? |
…ests.cs Co-authored-by: Mitchell Hwang <[email protected]>
noahfalk
enabled auto-merge (squash)
July 14, 2025 21:15
Member
Author
|
I just accepted Mitchell's suggestion but it reset the review gate. But if someone can accept again - yep ready to merge! |
mdh1418
approved these changes
Jul 14, 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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This started out as a bit of test logging. Then the unrelated GetProcessInfo test failed in CI so the change grew into a small product fix + more test improvements.
Product changes:
Test changes: