Repository navigation
test(corpus): record the installed corpus as 0.9.1 reads it, and take minimatch 11 for the lint - #285
Merged
Merged
Conversation
The weekly installed-types corpus job has failed every Monday since 2026-10-26 with the same counts. ee231a8 (in 0.10.0) changed what onsystem reads, regenerated corpus/snapshot.json, and left corpus/snapshot-installed.json as 0.7.0 wrote it, since the installed job does not run on pull requests. Run at ee231a8's parent, the installed corpus matches the old snapshot; at ee231a8, at 6425861 and at d00ccad it gives the same counts as the failing runs. The new counts are the ones snapshot.json has had since ee231a8 for the same repositories: - Dub (Tailwind 3, no borderRadius in its config) gets Tailwind's default radius scale, 7 tokens, so off-scale radii such as rounded-[10px] are reported as warnings: 47 in apps/web, 5 in packages/ui, 52 from the root. - saas-starter has 32 color tokens instead of 40: the codemod's `@theme { --color-x: hsl(var(--x)) }` entries are now aliases of the variables they wrap. Written with `node scripts/corpus.mjs --installed --update` at d00ccad.
…age exclusions Dependabot alert #19, GHSA-g3hv-75wg-m249 (moderate, dev): minimatch 7 to 11.0.0 amplifies patterns with **/.. portions, and only 11.0.1 fixes it. ESLint 10, its @eslint/config-array and typescript-eslint's typescript-estree ask for ^10, so an override in pnpm-workspace.yaml takes 11.0.8, with a comment on why it is safe and when to remove it. They use minimatch(), new Minimatch(), match() and pattern, which 11 keeps. ESLint reports the same, file for file, for the root and the site with it. ESLint 9's minimatch 3 is outside the advisory. minimumReleaseAgeExclude loses the entries for typescript-eslint 8.71.1 and ondocs 0.10.0, which are no longer in the lockfile. The Radix entries stay: those versions still are.
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 small fixes: the weekly installed-types corpus job fails on
main, and Dependabot alert #19 (minimatch) is open. The first commit's message says the token change shipped in 0.10.0. It was 0.9.1, as below.The installed-types corpus: a stale snapshot, not a regression
The "Installed-types corpus" job in the Corpus workflow failed this morning on
main(run 43872646986). It runs only on Mondays and on demand, never on pull requests. It has failed every Monday since 2026-10-26, with the same counts each time: on 10-26 atceb2761, and on 11-02 and 11-09 at6425861, before either dependency sweep. The run at 11:32 today that passed was the daily "Real-world corpus" job; the installed job was skipped in it. The last time the installed job passed was 2026-10-19.I fetched and installed the corpus locally (
node scripts/corpus.mjs fetch --installed, the job's own steps) and rannode scripts/corpus.mjs --installedwith each commit's own build:0709e58, the parent ofee231a8corpus/snapshot-installed.jsonee231a8"fix(tokens): read wrapped theme colors, import order, the v3 radius scale and an app's own stylesheet"6425861,mainbefore #278d00ccad,mainnowSo the dependency updates in #278 and #284 (postcss, tsdown and rolldown, tailwindcss) change nothing here.
ee231a8changed what onsystem reads on purpose, with a changeset, and shipped in 0.9.1 on 2026-10-23. It regeneratedcorpus/snapshot.jsonbut notcorpus/snapshot-installed.json, which 0.7.0 wrote on 2026-10-16 and nothing has written since. For the same repositories,snapshot.jsonhas had the new counts sinceee231a8: saas-starter 32 color tokens, Dub 7 radius tokens and 47, 5 and 52no-hardcoded-radiuswarnings.The new counts are right:
Dub is on Tailwind 3 (
tailwindcss^3.4.4), andpackages/tailwind-config/tailwind.config.tssets noborderRadius, so its classes use Tailwind's default radius scale. Before 0.9.1, onsystem read no radius scale for a v3 config like this, so it had no radius tokens and reported no radius. Now it reads the 7 default steps (sm0.125rem to3xl1.5rem), and an arbitrary radius off that scale is a warning, as the 0.9.1 release notes say: "In a v3 project with no radius tokens of its own,no-hardcoded-radiusnow runs against that scale, socheckcan report warnings it did not before." Three of the new findings, at Dub's pinned commit70c96f9:apps/web/ui/partners/lander/lander-rewards.tsx:58:"rounded-[10px] border border-neutral-200 bg-neutral-50 px-5 py-4". Hardcoded radiusrounded-[10px](10px) is off the scale. Nearest:rounded-lg(8px).apps/web/app/(ee)/partners.dub.co/(dashboard)/programs/[programSlug]/(enrolled)/links/partner-link-rewards.tsx:162:<div className="flex flex-col gap-2 rounded-[10px] border border-neutral-200 bg-white p-3">. The same finding.packages/ui/src/nav/content/resources-content.tsx:29:className="grid grid-cols-3 divide-x divide-neutral-200 rounded-b-[20px] bg-white …". Hardcoded radiusrounded-b-[20px](20px) is off the scale. Nearest:rounded-b-2xl(16px).Each is a radius that Tailwind's scale doesn't have, reported as a warning. That's the rule's job.
saas-starter's
app/globals.csshas the@theme { --color-background: hsl(var(--background)); … }block that shadcn/ui's Tailwind 4 codemod leaves. Sinceee231a8, a theme color that wraps a variable of bare channels inhsl()is an alias of that variable. I comparedinspect --format jsonbefore and afteree231a8: the 8 color tokens that leave arecolor-sidebar(hsl(var(--sidebar-background))) and the other sevencolor-sidebar-*entries. Each is now an alias of the--sidebar-*variable it wraps, which is a token already. That takes 40 color tokens to 32, and its findings don't change.So I updated the snapshot with
node scripts/corpus.mjs --installed --updateatd00ccad. The diff is exactly the rows the job printed, plusversion(0.7.0 to 0.12.1):no-hardcoded-radius0 → 47 warnings (47 fixable)no-hardcoded-radius0 → 5 warnings (5 fixable)no-hardcoded-radius0 → 47 warnings (47 fixable)apps/webandpackages/ui, flagged files 1,029 → 1,031,no-hardcoded-radius0 → 52 warnings (52 fixable)Run again after the update,
node scripts/corpus.mjs --installedpasses, and the installed holdout still reports all 109 of its findings. No source changes and no changeset: users have had this behaviour since 0.9.1, and only the record of it was behind.bench/v2/config/repos.jsonandbench/v2/README.mdstill describe saas-starter as having "40 color tokens". That was the count when the benchmark ran, and those strings are part of its published task inputs and results, so I left them.minimatch 11 for the lint (alert #19)
GHSA-g3hv-75wg-m249 (moderate, dev scope): minimatch 7 to 11.0.0 amplifies patterns with
**/..portions, and only 11.0.1 fixes it. minimatch 10.2.6 comes in through ESLint 10.12 and its@eslint/config-array0.23.5, and through typescript-eslint's@typescript-eslint/typescript-estree8.72.2. All three ask for^10. ESLint 10.15.0 and config-array 0.23.6 (from 2026-11-13) move to^11.0.5, but typescript-estree 8.72.2, the newest, still asks for^10.2.2, so a bump alone doesn't fix it. ESLint 9 (theeslint-v9alias) andeslint-plugin-jsx-a11yuse minimatch 3.1.5, which the advisory doesn't list. The published package doesn't depend on minimatch.So
pnpm-workspace.yamlgets the override ondocs uses. Its comment says why it's safe and when to take it out: once the lockfile has ESLint 10.15 and typescript-eslint asks for 11.It resolves to 11.0.8 (with its new dependency
@isaacs/nonrecursive-glob-match1.1.0). minimatch 11 removesmakeRe(),Minimatch#regexp, theASTclass and a few internal methods. ESLint and config-array usenew Minimatch(),match()(withpartial) andpattern. typescript-estree callsminimatch()only forallowDefaultProject, which neither ESLint config here sets. All of those stay in 11, which ships CommonJS as well, for ESLint'srequire. To check, I ran ESLint with--format jsonbefore and after, for the root (215 files) and the site (135 files), and compared every file's errors, warnings and messages: they're identical.minimumReleaseAgeExcludealso loses its entries for typescript-eslint 8.71.1 (11 packages) and ondocs 0.10.0. None of those versions is in the lockfile any more. The 7 Radix entries stay, because those versions still are.Audit
pnpm audit: no known vulnerabilities (1 moderate onmain, this minimatch).Checks
On a clean
node_modules, with the new lockfile:pnpm install --frozen-lockfile: pass, and the lockfile passes pnpm's supply-chain checks (minimatch 11.0.8 is from 2026-11-11)pnpm lint,pnpm format:check,pnpm typecheck, andpnpm --filter "./examples/*" typecheck: passpnpm build: pass;schema.jsonunchangedpnpm smoke, the dogfood check ofapp/settings/members.tsx, and the Claude Code hook onapp/settings/danger-zone.tsx(exit code 2,no-unknown-variant): passpnpm test: 115 files pass and 1 is skipped; 1,500 tests pass and 3 are skippedpnpm test:coverage: pass (lines 95.74%, branches 87.46%, functions 95.69%, statements 93.59%)pnpm pack-test: pass, including the ESLint 8.57.0 projectgenerate,test(295 tests),typecheck,lintandbuild: passnode scripts/corpus.mjs --installed: passes with the new snapshotThe installed job is skipped on pull requests, so I dispatched the Corpus workflow on this branch: in run 43879601491, both the installed-types and the real-world corpus pass.