Use new API for parsing binary logger parameter#53492
Merged
tmat merged 1 commit intoMar 17, 2026
Merged
Conversation
4fa4e5e to
aec310a
Compare
Member
Author
|
@DustinCampbell ptal |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR replaces a custom binary logger parameter parser in dotnet-watch with the new BinaryLogger.ParseParameters API from MSBuild (introduced in dotnet/msbuild#12606), removing duplicated parsing logic.
Changes:
- Replaced the custom
ParseBinaryLogFilePathimplementation with a call toBinaryLogger.ParseParametersfromMicrosoft.Build.Logging, adding error handling and anILoggerparameter. - Deleted the
BinaryLoggerTeststest file since the parsing logic is now owned by MSBuild.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
src/Dotnet.Watch/dotnet-watch/CommandLine/CommandLineOptions.cs |
Replaced custom parser with BinaryLogger.ParseParameters API call; added ILogger parameter for error reporting; added new using directives. |
test/dotnet-watch.Tests/CommandLine/BinaryLoggerTests.cs |
Deleted the test file for the now-removed custom parser. |
jasonmalinowski
approved these changes
Mar 16, 2026
Member
jasonmalinowski
left a comment
There was a problem hiding this comment.
Ooh we can use this in Roslyn too...
aec310a to
8c931a5
Compare
DustinCampbell
approved these changes
Mar 17, 2026
8c931a5 to
0326f72
Compare
DonnaChen888
pushed a commit
that referenced
this pull request
Mar 18, 2026
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.
dotnet/msbuild#12606 added new API that parses binary logger parameters.
We can remove our custom parser.
Verified that the parsing tests passed before deleting them.