fix(lsp): correct inlay hints after lock file or manifest changes#53
Merged
fix(lsp): correct inlay hints after lock file or manifest changes#53
Conversation
This fixes two related bugs where inlay hints incorrectly showed all dependencies as up-to-date (green checkmarks) after cargo update or applying code actions. Root cause: cached_versions (latest from registry) were being overwritten with resolved_versions (from lock file), causing the comparison logic to always return true. Changes: - Remove incorrect update_cached_versions call in handle_lockfile_change - Remove for loop merging resolved_versions into cached_versions in handle_document_change - Add two-tier check for dependencies not in lock file (fallback to version requirement check) - Update dependencies (aws-lc-rs, colored, cc, etc.) - Update resolver to version 3 Fixes issue where dev-dependencies in workspace members showed incorrect status when missing from Cargo.lock.
8b7f74a to
66ff9e3
Compare
Codecov Report❌ Patch coverage is
@@ Coverage Diff @@
## main #53 +/- ##
==========================================
+ Coverage 84.58% 84.87% +0.28%
==========================================
Files 56 56
Lines 16593 16634 +41
==========================================
+ Hits 14036 14118 +82
+ Misses 2557 2516 -41
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 17 files with indirect coverage changes 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes two related bugs where inlay hints incorrectly showed all dependencies as up-to-date (green checkmarks) after cargo update or applying code actions.
Root Cause
cached_versions (latest from registry) were being overwritten with resolved_versions (from lock file), causing the comparison logic to always return true.
Changes
Test Plan