Skip to content

fix(ci): use cargo update --workspace instead of generate-lockfile - #462

Merged
wesbillman merged 1 commit into
mainfrom
fix/release-lockfile-regen
May 3, 2026
Merged

fix(ci): use cargo update --workspace instead of generate-lockfile#462
wesbillman merged 1 commit into
mainfrom
fix/release-lockfile-regen

Conversation

@wesbillman

Copy link
Copy Markdown
Collaborator

Summary

  • Replace cargo generate-lockfile with cargo update --workspace in the release workflow's version patching step

Problem

The release workflow's "Patch version" step ran cargo generate-lockfile, which regenerates the entire Cargo.lock from scratch. This resolved tauri = "2" to the latest available version (2.11.0), while the npm @tauri-apps/api remained locked at 2.10.1 via pnpm-lock.yaml. Tauri's build checks for major/minor version alignment between the Rust crate and the npm package, so the build failed with:

Found version mismatched Tauri packages:
tauri (v2.11.0) : @tauri-apps/api (v2.10.1)

Fix

cargo update --workspace only updates the version metadata for workspace crates (the desktop app version we just patched) without re-resolving third-party dependencies. This preserves the committed lockfile's pinned tauri = 2.10.3, which is compatible with @tauri-apps/api = 2.10.1.

Test plan

  • Re-run the release workflow with version 0.0.1-test.1 after merging
  • Verify the "Build Tauri app" step no longer fails with version mismatch

🤖 Generated with Claude Code

cargo generate-lockfile regenerates the entire lockfile from scratch,
resolving all dependencies to their latest compatible versions. This
caused the tauri crate to jump from 2.10.3 to 2.11.0 while the npm
@tauri-apps/api remained at 2.10.1, triggering a version mismatch
error during the build.

cargo update --workspace only updates workspace crate versions (the
version we just patched) without touching third-party dependency
resolutions, preserving the lockfile's pinned versions.
@wesbillman
wesbillman enabled auto-merge (squash) May 3, 2026 16:33
@wesbillman
wesbillman merged commit 0762eb3 into main May 3, 2026
13 checks passed
@wesbillman
wesbillman deleted the fix/release-lockfile-regen branch May 3, 2026 16:41
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.

1 participant