Repository navigation
ci: build, lint and test with --locked - #154
Closed
juan-malbeclabs wants to merge 1 commit into
Closed
juan-malbeclabs wants to merge 1 commit into
juan-malbeclabs wants to merge 1 commit into
Conversation
juan-malbeclabs
added this pull request to stack #156
September 11, 2026 01:05
The Dockerfile's `cargo build --release --locked` was the only place the lock was enforced. `rust` CI re-resolved silently, so a Cargo.lock that Cargo would have to rewrite passed every check and first surfaced days later as a failed GHCR publish — which is how two independently-resolved Dependabot locks merged into an unusable one and stalled the image publishes for three days (#155). A stale or internally inconsistent lock now fails the PR that introduces it.
juan-malbeclabs
force-pushed
the
jo/ci-enforce-cargo-locked
branch
from
September 11, 2026 01:06
acbb1c6 to
3add126
Compare
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.
Closes the detection gap behind #155. Merge after #151, which is what actually repairs
Cargo.lockonmain— with a broken lock this PR's own CI is (correctly) red.Summary
--lockedto the three cargo invocations inrust.yml(build, clippy, test).cargo build --release --lockedwas the only place the lock was enforced. CI re-resolved silently, so aCargo.lockthat Cargo would have to rewrite passed every check and first surfaced days later as a failed GHCR publish — three days of failed image publishes, with:mainnet-betaleft on the 0.38.0 client base across a doublezero release (Image publishes have failed since 2026-09-08: Cargo.lock on main is unusable with --locked #155).This closes the detection gap, not the cause: two Dependabot PRs whose locks are each valid against their own base still merge into an invalid one. Requiring branches to be up to date before merging (or a merge queue) is the branch-protection change that prevents that — a repo setting, not code.
Testing Verification
main(e258968):cargo build --workspace --releasesucceeds whilecargo build --workspace --release --lockedfails withcannot update the lock file. With this change, that commit would have gone red on the PR that introduced it instead of three days later on a publish.cargo build --workspace --release --lockedsucceeds against deps: pin past the yanked chacha20 0.10.1 #151's repaired lock.