Skip to content

Commit 37f78f3

Browse files
authored
fix(lsp): correct inlay hints after lock file or manifest changes (#53)
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.
1 parent 7f628eb commit 37f78f3

File tree

6 files changed

+306
-86
lines changed

6 files changed

+306
-86
lines changed

CHANGELOG.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,20 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [0.5.5] - 2026-01-27
11+
12+
### Fixed
13+
- **Inlay hints now correctly handle cached versions** — Fixed bug where inlay hints showed all green checkmarks after cargo update or code actions
14+
- Removed incorrect overwriting of cached_versions with resolved_versions in handle_lockfile_change (server.rs)
15+
- Removed incorrect merging of resolved_versions into cached_versions in handle_document_change (lifecycle.rs)
16+
- cached_versions now correctly preserve latest registry versions while resolved_versions track lock file versions
17+
- **Inlay hints for dependencies not in lock file** — Dependencies missing from Cargo.lock now show correct status based on version requirement satisfaction
18+
- Two-tier check: lock file versions compared directly, missing dependencies checked against version requirements
19+
- Fixes incorrect red cross display for dev-dependencies in workspace members
20+
21+
### Changed
22+
- Updated dependencies (aws-lc-rs, aws-lc-sys, cc, colored, and others)
23+
1024
## [0.5.4] - 2026-01-15
1125

1226
### Fixed

0 commit comments

Comments
 (0)