Skip to content

Issue-number reference ratchet has a regex gap that already lets two real violations through silently #2997

Closed

Description

@mstomar125

Problem

No end user of the NodeSpace app is affected at all; even the developer-facing impact is minor — it's a coverage gap in an internal comment-style lint that lets two already-existing, easily-readable references to a closed issue slip through undetected, so this was revised down from the sweep's "medium."

Root cause

ISSUE_NUMBER_PATTERNS (scripts/check-code-references.ts:73) only matches core#N, (#N) (paren immediately touching #), Issue #N, PR#N, and pre-/post-#N shapes — a bare #NNN in ordinary prose (e.g. "see #990") matches none of them. scripts/update-homebrew-cask.ts lines 65 and 224 already contain exactly this ("// embeddings require Sonoma+, see #990)."), a live reference to a real (closed) GitHub issue. Running bun run scripts/check-code-references.ts directly confirms it reports "Issue-number references: 0 (baseline 0)" and exits 0 — the gate is green while a real violation sits in the scanned directory. This is enforced by the pre-push gate (test-gate.ts → test:all → bun test scripts/), so it's a real false negative in a live gate, not a dead check, just currently harmless because the referenced content is a closed, well-understood issue.

Suggested fix

Extend ISSUE_NUMBER_PATTERNS to also match a bare #\d+ preceded by ordinary prose/word-boundary, then fix the two live violations in update-homebrew-cask.ts lines 65/224 before re-baselining.


Found via the 2026-09-25 full-repo code sweep (finding #53 of 84 in CODE_SWEEP_FINDINGS_2026-09-25.md). Severity: low. Category: broken.

Activity

  1. self-assigned this
    on Sep 25, 2026
  2. added
    sweep
    on Sep 25, 2026
  3. removed their assignment
    on Sep 25, 2026
  4. malibio commented on Sep 27, 2026

    @malibio
    Collaborator

    Frontend: 281 files / 5441 tests passed

  5. self-assigned this
    on Sep 27, 2026
  6. added a commit that references this issue on Sep 27, 2026
    ebd2765
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

sweep

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions