Closed
Description
Discovered while investigating #54147: with "experimentalUseInvalidMetadata" set, we may diagnose a package with invalid metadata, and not re-diagnose when new metadata arrives. This can lead to diagnostics which are stale until you begin typing again.
We could fix this by re-diagnosing after each metadata load, but more generally we should reconsider whether it is worth landing this feature:
Pros:
- when the workspace is totally broken, gopls will continue to work
Cons:
- though gopls will continue to work, it may have inconsistent or confusing state
- users should generally fix broken workspaces before doing anything else
- we really don't want users to have to restart gopls, so in all other respects we are trying to avoid places where gopls "remembers history"