Allow clearing diagnostics from addons
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 2k
- Forks
- 281
- Avg merge
- 2h 14m
- Merged PRs (30d)
- 6
Description
I have checked that this feature is not already implemented
- This feature does not exist
Use case
Formatter addons should be able to clear diagnostics
Description
Trying to get the rubocop addon up to the same level as the original addon. One thing I'm stuck with is that when .rubocop.yml changes, diagnostics are cleared: https://github.com/Shopify/ruby-lsp/blob/83e7cb0b502a9cd5a7e49a6bfb490f624ced2bd8/lib/ruby_lsp/server.rb#L1098-L1104
But I don't think I have access to the store in an addon. How could I make that functionality accessible in an addon?
Implementation
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with lib/ruby_lsp/server.rb around lines 1098-1104 to understand how diagnostics are cleared, then inspect the addon interfaces and the RuboCop addon path. Expose an addon-accessible way to clear diagnostics so configuration changes can remove them, and verify the RuboCop addon reaches parity with the original addon behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ruby
- Domain
- devtools
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100