-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Warning/errors/messages are not correctly grouped for multi-targeting projects #32055
Comments
So after playing around with this further, it seems something is really broken with multi-targeting projects, but only during the time when user is editing the csproj. The above given repro steps causes the multiple diagnostics issue to show up sometimes, but not always. Additionally, editing the csproj to remove and then re-add any of the target frameworks causes the diagnostic for that framework to go away from the error list and never re-appear. See the below gif: If I re-add the new target frameworks one at a time, I see an additional duplicate diagnostic show up for every added target framework, see the below gif: For all the above cases, unloading and reloading the project OR closing and reopening the solution always fixes the issue and we end up a single correct de-duplicated diagnostic which lists all the target frameworks. |
Also confirmed that the issue is not specific to any analyzer, it repros even with compiler diagnostics. |
@sharwell - any reason this has been marked as Needs design review? |
What is the repro for this? Make sure this isn't build-time because that would likely be: dotnet/project-system#2811. |
Just have a simple method with an unused local, which generates a CS diagnostic. |
Yep, I never did a build. |
Version Used:
Version 16.0.0 Preview 2.0 [28420.135.d16.0stg]
Steps to Reproduce:
Expected Behavior:
Single message with:
Actual Behavior:
Two messages:
tag @mavasani @heejaechang
The text was updated successfully, but these errors were encountered: