Conversation
🦋 Changeset detectedLatest commit: 52c0663 The changes in this PR will be included in the next version bump. This PR includes changesets to release 13 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
70ce195 to
3a1cf3b
Compare
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
WalkthroughAdds runtime validation to LSP range conversion to reject ranges whose computed start offset exceeds end offset, preventing panics. Adds unit and integration regression tests in the LSP converter and server to ensure inverted LSP ranges are ignored and do not mutate document text or crash the server. Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.changeset/neat-oranges-open.md:
- Line 5: Rewrite the changeset sentence to follow the bug-fix format and fix
typos: change "Fixed a bug where the Biome Langauge Server would suddenly panic
when open files suddenly changes." to start with the required prefix "Fixed
[`#NUMBER`](issue link):" and correct spelling/grammar (e.g., "Fixed
[`#NUMBER`](issue link): Fixed a bug where the Biome Language Server would panic
when open files suddenly change (for example, when switching Git branches)."),
replacing [`#NUMBER`](issue link) with the actual issue reference.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: eadc73e6-e958-4b68-9a66-7016ba3539c4
📒 Files selected for processing (5)
.changeset/neat-oranges-open.mdcrates/biome_lsp/src/server.tests.rscrates/biome_lsp/src/utils.rscrates/biome_lsp_converters/src/from_proto.rscrates/biome_lsp_converters/src/lib.rs
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
| ) -> Result<TextRange> { | ||
| let start = offset(line_index, range.start, position_encoding)?; | ||
| let end = offset(line_index, range.end, position_encoding)?; | ||
| anyhow::ensure!( |
Summary
Closes biomejs/biome-zed#188
We already handle the
Result, however, the underlying function didn't emit anyErr. Now we do.Test Plan
Added three tests with the help of Claude Code.
Docs