fix(oxlint): pin the version the gate enforces, and let a repo pin its own - #143
Merged
Conversation
…s own The `oxlint` run fetched `npx --yes oxlint@1`, so the rule set it gated on was whichever 1.x the registry served that minute. oxlint selects rules by category and 1.79.0 moved five React rules into `correctness`, turning consumers red on every open PR at once for findings that predated all of them — unfixable from any consumer repo, because the version lives here. `VERSION_DEFAULT` is now an exact version, resolved through dispatch input -> `oxlint.version:<repo>` -> `oxlint.version` -> the default, so a repo a bump breaks pins itself out in one `wrangler kv key put` instead of waiting on a deploy. `pr-review`'s grounding block shares the same constant, so the findings quoted to the reviewer are the findings that decide the check.
debuggingfuture
marked this pull request as ready for review
August 18, 2026 19:26
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
oxlintrun fetchednpx --yes oxlint@1. That made the registry, not this repo, the authority on what theflare-dispatch/oxlintcheck enforces — with no commit, no PR and no review on either side.Problem & Insight
oxlint selects rules by category, and a minor release may move a rule into
correctness. 1.79.0 (published 2026-08-18) moved five React rules in. Every consumer tracking@1went red inside the hour, on every open PR at once, for findings that predated all of them — and no consumer could fix it, because the version was here.The second half is worse than the outage: a consumer's own lint step runs its pinned devDependency, so it stayed green throughout. The two lanes had been enforcing different rule sets all along, and the only signal of that divergence is the day they disagree.
Same shape as an unpinned
:latestimage or a floating action tag, with one extra turn of the screw — it fails on everyone simultaneously and reads like their regression.Take
VERSION_DEFAULTis now an exact version (oxlint.ts), never a range or dist-tag, and thepull_requesttrigger no longer restates a literal — pinning it there would pin every repo the dispatcher serves, unreachable from all of them.Pinning alone is not enough: it moves the single point of failure from the registry to this repo, and a consumer a bump breaks is still stuck. So
versionresolves through the ladderoffload-testalready uses forcommand:One
wrangler kv key putand a repo runs its own version, no deploy here. The run keeps its zero-config property — no command, no install, no.oxlintrc.json— since the default always answers; an unresolvable version is not a failure the way a missingoffload-testcommand is.resolve-versionis a real checkpointed step, so it is skipped entirely when a dispatch carries a version and Action mode keeps thecheckout → exec → upload-logshape the suite pins. Run version →1.2.0.pr-review's grounding block imported the same constant rather than keeping its own"1"— its quoted findings should be the findings that decide the check.Alternative not taken: deriving the version from the consumer's own
package.json. It reads as the real fix — the gate would enforce exactly whatpnpm lintdoes — but the checkout runsinstall: false, and a^1.74.0range resolves no better than@1. Getting a concrete version means parsing three lockfile formats in the container. Worth its own issue, not this PR.Verified
pnpm lint,pnpm typecheck,pnpm testall green (2285 passed, 1 skipped). Five new cases cover the ladder, the exact-version shape of the default, blank-KV fallthrough (so a stray empty value can never produceoxlint@), and that a dispatched version skips the resolve step.Follow-up
oxlint.version:<repo>— pinning is the faster of the two and needs nothing from here.VERSION_DEFAULTcan turn consumers red; it belongs in its own PR, never folded into an unrelated change.🤖 Generated with Claude Code