DECISION NEEDED: canonical script/bootstrap pins NODE_VERSION and YARN_VERSION but policy tells it to skip on any version found — the pins are decorative
#33
Reference in New Issue
Block a user
Delete Branch "%!s()"
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?
Split out of #28, which fixes the same shape for golangci-lint. Filed as a decision rather than a defect because current policy explicitly prescribes the behaviour, so an agent should not simply "fix" it.
The situation
script/bootstrappins:and then:
missingtestsPATHpresence, never version. So on any machine that already has some node or some yarn, both pins are inert — exactly the defect #28 reports for golangci-lint, in the canonical file itself.REPO_POLICIES.mdlines 55-61 currently prescribes this: "For node it uses the installed node if present; otherwise it installs a PINNED node version via nvm". So the code matches policy; it is the policy that is in tension with the hash-pinning rule and with "Never install 'latest' or 'lts'; always exact versions" two lines later.Why it matters
It is the same class as #26, #28 and #30: a mechanism that looks like it guarantees something and does not. A repo whose CI container gets node 22.17.0 while a developer's host has node 24 will see behaviour differences that no one attributes to node, because the pin is right there in the file and reads as authoritative. The
--frozen-lockfileinstall does pin the JS dependency tree, so the exposure is the runtime, not the packages.Options
node --versionagainstNODE_VERSION; if it differs, install the pin via nvm and use it. Same for yarn via corepack. Consistent with the hash-pinning rule and with the fix landing in #28. Cost: bootstrap starts installing node on developer machines that already had a working one, which is slower and more intrusive, and nvm's shell integration makes "use the pinned one" awkward to guarantee for subsequent non-bootstrap commands.NODE_FALLBACK_VERSION/YARN_FALLBACK_VERSION, and reword the policy to say plainly that the host node is used when present and the version is only a fallback for machines without one. Nothing breaks; the file stops implying a guarantee it does not provide.Recommendation
Option 2, and it is a close call against option 1.
Option 1 is the principled answer and matches what #28 does for the linter — but the two cases are not actually symmetric. The linter's whole purpose is that local and CI agree on what the gate is, so a skew there produces false greens and wasted rework, which is the harm #28 documents. Node is a runtime whose skew shows up as ordinary bugs caught by tests, and forcing an nvm install on every developer machine to close it buys less than it costs. Option 2 removes the false guarantee, which is the actual defect here, at zero cost and with no blast radius.
If you prefer option 1, say so and it will be implemented instead — the version-compare-and-verify logic from #28 transfers directly.
Not blocking anything: #28 proceeds independently.
clawbot referenced this issue2026-08-09 17:25:30 +02:00
clawbot referenced this issue2026-08-09 17:35:30 +02:00
clawbot referenced this issue2026-08-09 17:55:58 +02:00
clawbot referenced this issue2026-08-09 20:52:45 +02:00