fix(release): sync Cargo.lock in create-release so it stops drifting (MAPPS-371) #431
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/MAPPS-371-create-release-lock-sync"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fixes MAPPS-371.
The apps
create-releaserecipe bumpedCargo.toml+package.jsonbut never updatedCargo.lock, so the lock's ownmokosh-appsversion drifted from the manifest:mainwas atCargo.toml0.7.1 (after the 0.7.0 / 0.7.1 releases) whileCargo.lockstill pinned 0.6.0.Effects: every cargo build rewrote the lock to match (each
just pre-commitleftM Cargo.lock), a--lockedbuild failed, and the dirty lock would abort the nextjust create-release(which exits on a dirty tree).Fix
create-releaserecipe: after the version bump, runcargo update --workspacein the rust-builder-glibc dev image (the samedocker run ... $img cargo ...invocationpre-commituses; dev boxes have no host cargo) and stageCargo.lockalongsideCargo.toml/package.jsonin the release commit.--workspacelimits the change to workspace members' own versions, no transitive dependency churn.mokosh-apps 0.6.0 -> 0.7.1) somainbuilds clean under--lockedand the next release starts from a clean tree.Verification
just --show create-releaseparses; the newcargo update --workspacestep andgit add ... Cargo.lockare present.mokosh-appsversion line inCargo.lock(0.6.0 -> 0.7.1), no other entries.just pre-commitpasses (fmt + clippy + wasm check + tests) and, with the lock now matchingCargo.toml, leavesCargo.lockunchanged - the tree is no longer re-dirtied on build.