test(repo-guards): tie the fixture prefilter to its resolver and cover the producer skip branches
Merged
SA
7d ago+58+58+01234567890123456789-25-25-01234567890123456789
Summary
Follow-up to the non-blocking review notes on #4885, which merged before they landed.
- Daemon fixture guard: the prefilter re-derived
resolveLocalImport's candidate paths by hand, so a later resolver change (a new extension, for example) could narrow it silently. In a file with no backslash, every quoted text that opens with.now goes throughresolveLocalImportitself. Without escapes, a request's text is its value, so this stays a superset. Files with a backslash stay possible importers of every member. The scan includes overlapping quote pairs, so a stray quote earlier on the line cannot hide a request. - Snapshot producer guard: only the live repo exercised the skip regex's backslash and
PRODUCERbranches. Two example modules now need them: an escaped key and a lone*_PRODUCERconstant.
Related: #4512 saw the producer scan time out. No open issue tracks these tests.
Validation
- At pre-rebase
9f653a66e(same files):- On the real repo, base
c37bb9563and the new fixture scan both return 0 violations. With a raw launcher appended to every non-declaration file, both return the same 19. daemon-fixture-launchestakes 1.4-1.9 s at load 4.6-6, against 3.4-3.8 s before #4885.
- On the real repo, base
- Each new case fails when the branch it covers is removed: escaped candidates, overlapping quote pairs, the backslash branch, and the
PRODUCERbranch. pnpm check:affected --run --head 92ac51fc5passed every runnable check, including full unit (21,400 passed).
Reviewed with sol-loop: 1 round with gpt-6.2-sol. Sol verdict: approved
Created with Claude Opus 5.5 in Claude Code.

Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.