Skip to content

fix(release): stamp Cargo.lock in sync-versions; publish --locked#87

Merged
brentrager merged 1 commit into
mainfrom
fix-cargo-lock-sync
Jun 25, 2026
Merged

fix(release): stamp Cargo.lock in sync-versions; publish --locked#87
brentrager merged 1 commit into
mainfrom
fix-cargo-lock-sync

Conversation

@brentrager

Copy link
Copy Markdown
Contributor

Same class of bug we just fixed in smooth-operator (#111): the release bumps the Rust Cargo.toml version but not the lock, so the lock drifts. fetch papered over it with cargo publish --allow-dirty (no --locked, non-reproducible).

Fix: sync-versions.mjs now also stamps rust/fetch/Cargo.lock — name-targeted to the smooai-fetch [[package]] entry so a same-versioned dependency is never touched — and the release publishes with --locked --allow-dirty (reproducible lock; --allow-dirty still needed because sync edits the manifests in-place at publish time).

Verified: a simulated version bump stamps Cargo.toml + Cargo.lock together, serde and other deps stay put, and cargo build --locked builds. No-op on an already-synced tree.

🤖 Generated with Claude Code

sync-versions.mjs stamped rust/fetch/Cargo.toml on release but not Cargo.lock, so
the lock pinned the old version — the release worked around it with
`cargo publish --allow-dirty` (no --locked, non-reproducible). Now the script also
stamps the lock's smooai-fetch entry (name-targeted so dependency versions are
never touched), and the publish uses --locked --allow-dirty (reproducible lock +
still tolerant of the in-place manifest edits at publish time). Verified: a
simulated bump stamps toml+lock together, deps untouched, cargo build --locked
builds.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01U7Mn93HpqhSgEmX6tRdPAv
@changeset-bot

changeset-bot Bot commented Jun 25, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 84cbef8

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@brentrager brentrager merged commit 238f63e into main Jun 25, 2026
1 of 2 checks passed
@brentrager brentrager deleted the fix-cargo-lock-sync branch June 25, 2026 20:18
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