Skip to content

refactor(bracketed): update diagnostic to not use deprecated methods - #2569

Merged
echasnovski merged 2 commits into
nvim-mini:mainfrom
abeldekat:fix_bracketed
Oct 5, 2026
Merged

echasnovski merged 2 commits into
nvim-mini:mainfrom
abeldekat:fix_bracketed

Conversation

@abeldekat

Copy link
Copy Markdown
Member

Resolve #2560
Resolve #2566

This PR uses on_jump instead of float when version >= 0.13

I used the code submitted in this PR

I made sure to never override a on_jump the user may have added to diagnostic.config

@echasnovski echasnovski left a comment •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for the PR!

I used the code submitted in ... PR

That's a reasonable approach and what I was planning to do. This still needs adjustments to general 'mini.nvim' code approaches.

I made sure to never override a on_jump the user may have added to diagnostic.config

This requires new tests, I am afraid. And so should be a separate fix(bracketed) commit since.

Comment thread lua/mini/bracketed.lua Outdated
Comment thread lua/mini/bracketed.lua Outdated
Comment thread lua/mini/bracketed.lua Outdated
Comment thread lua/mini/bracketed.lua Outdated

@echasnovski echasnovski left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks almost done! Please separate into two commits, as I'd like to keep having refactor(xxx) commits to not change tests. The second fix(bracketed) can add a vim.diagnostic.config().jump.on_jump == nil check. And also two commits can have one Resolve #... instead of two.

Comment thread tests/test_bracketed.lua Outdated
Comment thread tests/test_bracketed.lua

@echasnovski echasnovski left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good now! And two issues at once! Thanks again :)


While testing this, I found some strange issues with jumping logic, but it is also present on the main. Will take a look separately.

@echasnovski
echasnovski merged commit 2ce54c4 into nvim-mini:main Oct 5, 2026
10 of 12 checks passed
@abeldekat
abeldekat deleted the fix_bracketed branch October 5, 2026 15:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Diagnostic jump doesn't respect user diagnostics config mini.bracketed: opts.float is deprecated and opts.on_jump should be used instead

2 participants