Skip to content
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

fix(#2954): resolve occasional tree flashing on diagnostics, set tree buffer options in deterministic order #2980

Conversation

des-b
Copy link
Collaborator

@des-b des-b commented Nov 1, 2024

fixes #2954

This ensures related autocmd's (e.g. on FileType) will be called in a
similar environment.
…'buflisted'

is_buf_valid has been inlined since it is only used for diagnostics
and its name is misleading.
@des-b des-b changed the title fix: Set buffer options in deterministic order and fix lsp diagnostics edge case fix(#2954): Set buffer options in deterministic order and fix lsp diagnostics edge case Nov 1, 2024
@alex-courtis alex-courtis changed the title fix(#2954): Set buffer options in deterministic order and fix lsp diagnostics edge case fix(#2954): resolve occasional tree flashing on diagnostics, set tree buffer options in deterministic order Nov 2, 2024
Copy link
Member

@alex-courtis alex-courtis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Many thanks for your contribution!

@alex-courtis alex-courtis merged commit 82ab19e into nvim-tree:master Nov 2, 2024
7 checks passed
des-b added a commit that referenced this pull request Nov 10, 2024
This ensures that LSP diagnostics of files which are not manually opened
by users are rendered by nvim-tree diagnostic indicators.

However when users attach an LSP to nvim-tree this will bring back
flashing as attempted to fix in #2980. Fixing this should probably done
by checking data passed via diagnostic events (DiagnosticChanged and
CocDiagnosticChanged).

Signed-off-by: des-b <[email protected]>
alex-courtis pushed a commit that referenced this pull request Nov 10, 2024
…() (#2998)

This ensures that LSP diagnostics of files which are not manually opened
by users are rendered by nvim-tree diagnostic indicators.

However when users attach an LSP to nvim-tree this will bring back
flashing as attempted to fix in #2980. Fixing this should probably done
by checking data passed via diagnostic events (DiagnosticChanged and
CocDiagnosticChanged).

Signed-off-by: des-b <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

LSP diagnostics inside nvim-tree may flicker
2 participants