-
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
Ensure diagnostics refresh when source generators run in balanced mode #77271
Conversation
I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label. |
I couldn't figure out the best area label to add to this PR. If you have write-permissions please help me learn by adding exactly one area label. |
...r/Protocol/Features/Diagnostics/EngineV2/DiagnosticIncrementalAnalyzer.CompilationManager.cs
Outdated
Show resolved
Hide resolved
src/LanguageServer/Protocol/Handler/Diagnostics/DiagnosticsPullCache.cs
Outdated
Show resolved
Hide resolved
Not connected to a computer right now. But I'm trying to figure out how oop syncing works properly of we're not combining the sg-version info into the project checksum. Or, if we are properly adding the sg-version to the syncing checksum, but not the dep checksum, then I think the bug is as you mentioned and the dep checksum should update. The dep checksum means: is this project substantively different when examined for syntax or semantics. In this case the answer is "yes" if SGs need to rerun. That said, if we update the checksum, we should audit ask the users of it to make sure that remains sensible in balanced mode. I'm thinking it will. But we don't want to mess up some other part of the system. |
oh i see. teh SourceGenExMap is stored at the solution level, and is a mapping from proj-id to version. so checksum doesn't contain it. i remember this being so checksum was pure data, and no host state. so yes, we need out of band info for this. |
src/LanguageServer/Protocol/Handler/Diagnostics/DiagnosticsPullCache.cs
Outdated
Show resolved
Hide resolved
src/LanguageServer/ProtocolUnitTests/Diagnostics/PullDiagnosticTests.cs
Outdated
Show resolved
Hide resolved
aeda0b1
to
e4db07d
Compare
Fixes an issue where diagnostics would not refresh when source generators run in balanced mode (e.g. after a save triggers sg re-run, diagnostics would not update based on the new sg contents).
checksum changes taken from #77273