Repository navigation
fix(lockfiles): write only the updated tools' mise.lock entries - #393
Merged
Merged
Conversation
mise writes the whole lockfile back, and the Count's mise drops fields a newer mise wrote (`checksum_source`), so every mise update in a repository locked by a newer mise was held for "unrelated entries". The Count now grafts only the selected tools' entries that mise changed into the committed lock and keeps every other byte. An entry mise wrote back without fields keeps its committed bytes. Any other change still holds, now naming what changed: another tool's entry, an entry added or removed, or the lockfile's own metadata. Tools are found under the name mise records them by (`lock_key`): no bracketed options or `core:`, and `nodejs`, `golang` and `dotnet-core` unaliased. A tool declared with options, such as `github:github/gh-actions-lock[bin=gh-actions-lock]`, was held as "removed a selected tool", and maintenance could not lock it at all. Two declarations mise records under one name hold.
sweepies
force-pushed
the
fix/mise-lock-keys
branch
from
November 23, 2026 20:34
e820983 to
d093105
Compare
Merged
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.
Two bugs held most mise tool updates on this repository's dashboard.
Version skew ("mise lock changed unrelated entries or lockfile metadata"). mise rewrites the whole lockfile. Our committed
mise.lockwas written by a newer mise, which recordedchecksum_source = "mise-versions"on some platform entries. The Count's pinned mise (2026.10.11) doesn't know that field and drops it from unrelated tools, so the Count held every mise update. Reproduced by hand with the real binaries in the Count's sandbox environment: 2026.10.11 drops the field, while 2026.10.25, 2026.11.5 and 2026.11.12 leave unrelated entries byte-identical. Any repository whose developers run a newer mise than the Count hits the same hold. Dropping the field would also be wrong to publish: it marks a checksum no download confirmed.The Count now writes only what it asked for:
tools, such aslockfile_version.Key mismatch ("mise lock removed a selected tool"). The Count looked tools up in the lock by their manifest key, such as
github:github/gh-actions-lock[bin=gh-actions-lock]. mise records them by their short name: no bracketed options orcore:, andnodejs,golanganddotnet-coreunaliased (BackendArg::from,strip_optsandunalias_backendin mise's source). The keys were checked against the real mise 2026.11.12. The newlock_keyincrates/tools/src/lockfiles/mise.rsgives that name (kept out ofcrates/miseso cached extraction state is not invalidated), and the Count still passes mise the manifest's spelling. Several places shared the flaw:nodejsbeside[tools].nodewent unnoticed. Two declarations that mise records under one name now hold.Fable 5.2 reviewed the design. Its points that shaped this change:
Known gap: in a multi-version declaration, unchanged sibling entries inside a changed selected tool still come from mise's output.
Tests use the fake mise and are behavioural:
Four of the new tests fail on main.
cargo test -p patchula-toolsand clippy pass. The guide'smise.locksection is updated.