Stop npm's yarn.lock rewrite from churning resolutions - #102
Merged
Merged
Conversation
update-all-lockfiles runs npm before yarn. npm rewrites yarn.lock in the v1 format as a side effect of installing, and yarn treats a v1 lockfile as something to import rather than its own pins, so it re-resolves every range against the registry. yarn.lock then picked up whatever had been published upstream since the last run, and CI's lockfile check went red on branches that never touched a dependency. Copy yarn.lock aside around `npm install` and put it back, which is what the docs already claimed happened. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
irskep
pushed a commit
that referenced
this pull request
Sep 14, 2026
Transitive ranges moved upstream, so `mise update-all-lockfiles` no longer reproduces the committed file. #102 stops this from recurring. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
irskep
pushed a commit
that referenced
this pull request
Sep 14, 2026
Transitive ranges moved upstream, so `mise update-all-lockfiles` no longer reproduces the committed file. #102 stops this from recurring. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
mblair
approved these changes
Sep 17, 2026
irskep
added a commit
that referenced
this pull request
Sep 17, 2026
* Stop the compliance tests depending on the local timezone `d.setDate(d.getDate() - 200)` keeps the local wall-clock time, so when a daylight saving transition falls inside the window the result is 200 days give or take an hour. getAgeDays floors, so 199.96 days became 199 and the overdue count came out one short. CI runs in UTC and never saw it; the test failed for anyone in a DST timezone. Use the elapsed-milliseconds form the rest of the file already uses. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * Refresh yarn.lock Transitive ranges moved upstream, so `mise update-all-lockfiles` no longer reproduces the committed file. #102 stops this from recurring. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Steve Landey <steve.landey@atticus.com> Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.
The deps are pinned. Something was throwing the pins away.
update-all-lockfilesruns npm before yarn. npm rewritesyarn.lockin the old v1 format as a side effect of installing, and yarn reads a v1 lockfile as a foreign file to import rather than as its own pins, so it re-resolves every range against the registry.yarn.lockthen absorbed whatever had been published upstream since the last run. That's why the lockfile check has been failing on branches that never touched a dependency, twice in the last few days, onundici,whichand@tybys/wasm-util.yarn installon its own doesn't drift at all. I checked: run it against an untouched tree andyarn.lockcomes back byte-identical. It's only the npm step before it that breaks the pinning.So this copies
yarn.lockaside aroundnpm installand puts it back, whichEVERY_NODE_PACKAGE_MANAGER_WORKS.mdalready claimed happened. The doc described the behavior; the script never did it.Verified on this branch, which carries
main's three-month-oldyarn.lockuntouched:mise run update-all-lockfilesnow reproduces all five lockfiles exactly, twice in a row. Before this, the same command rewroteyarn.lockevery time.That also means #100 and #101 didn't need their
yarn.lockrefreshes. They're harmless and already green, but once this lands the churn stops rather than needing a refresh commit each time someone opens a PR.Ducks sitting in a row is the whole point of a lockfile. One of ours kept wandering off.
🤖 Generated with Claude Code