docs(hygiene): land tools/hygiene/AUDIT-LIFECYCLE.md — reusable template#3710
Merged
Merged
Conversation
Promotes the audit-lifecycle pattern (discovery → narrow-fix → scanner → quality iterations → baseline → CI enforce gate → maintenance) to a canonical doc co-located with the hygiene-audit tooling. Two worked examples documented: 1. §33 migration xrefs audit (PR #3513 → #3552 → enforce; ~4 weeks) 2. Tick-shard relative-path audit (PR #3676 → #3708; ~80 min single autonomous-loop session) Captures the step-ordering rationale (why each step depends on the previous), the mutable-vs-immutable surface distinction for baseline strategy, and pre-emptive scanner-author findings worth implementing in step 3 to shorten the quality iteration loop: - sonarjs disable comment - main export + import.meta.main guard - generic URI scheme regex - --files validation (existsSync + statSync.isFile) - platform-correct PATH_SEP - JSON output schema discipline - baseline schema type guard Local markdownlint clean. Co-Authored-By: Claude <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Adds a reusable hygiene-audit lifecycle template for turning recurring repository hygiene defects into scanner-backed CI gates.
Changes:
- Documents the 7-step audit pattern from discovery through maintenance.
- Adds worked examples for §33 migration xrefs and tick-shard relative-path audits.
- Captures guidance on baseline strategy, scanner-quality pitfalls, and schema validation.
AceHack
added a commit
that referenced
this pull request
May 16, 2026
…3710) (#3711) Tick 15: promoted the audit-lifecycle pattern to a canonical doc at tools/hygiene/AUDIT-LIFECYCLE.md. 7-step pattern + 2 worked examples (§33 audit ~4 weeks; tick-shard relative-path audit ~80 min single session). Pre-emptive scanner-author findings documented to shorten the quality iteration loop for future audit work. All 3 prior-tick PRs (#3707/#3708/#3709) still armed + awaiting CI. Co-authored-by: Claude <noreply@anthropic.com>
…ection Two real Copilot findings on the §33 worked-example table: P2 (line 37): direct name attribution outside allowed roster surfaces. "Codex P2 catch on Riven section-33 archive migration" used Zeta persona names inline. Replace with role-ref: "Reviewer P2 catch on the section-33 archive-migration PR". (Copilot stays as-is — it's an external automated- reviewer role-ref, accepted style per existing gate.yml comments.) Line 44 (factual error): I'd attributed BOTH baseline cleanup AND CI enforce to PR #3552. Verified via git log + gh api: - PR #3552 (Slice A): "baseline cleanup — 10 dead xrefs → 0" - PR #3555 (Slice B.3 + B.4): "--enforce flag + gate.yml wiring" Split the row: PR #3552 = "Baseline (cleanup-to-zero)"; PR #3555 = "CI enforce" with sub-slice attribution preserved. Calendar duration range extended to PR #3513 → PR #3555. Co-Authored-By: Claude <noreply@anthropic.com>
AceHack
added a commit
that referenced
this pull request
May 16, 2026
…stale/FP) (#3715) PR #3707 + #3708 merged. 6 new Copilot threads investigated: - PR #3710 (AUDIT-LIFECYCLE.md): 2 real — name attribution (Codex/Riven → role-refs) + §33 PR-attribution factual error (PR #3552 baseline cleanup + PR #3555 CI enforce, not both #3552). Fixup cd7ba81. - PR #3709 (0328Z shard): 4 threads — 2 stale (0322Z merged via #3707), 1 minor prose-drift, 1 false-positive (4th time on table-pipes). All resolved no-op. The Copilot table-pipe || hallucination is now a 4-time pattern (#3685, #3690, #3699-era, #3709) — verify-first-resolve-no-op discipline. Co-authored-by: Claude <noreply@anthropic.com>
AceHack
added a commit
that referenced
this pull request
May 16, 2026
…ed (PR #3716) (#3717) Tick 17: bundled the 3 per-tick self-checks (MD032 awk + markdownlint-cli2 + relative-path audit --files) into one command at tools/hygiene/check-shard-before-push.ts. 187-line TS script. Motivation: tick 13 self-bite — MD038 violation slipped past the awk-only manual self-check. Bundle closes the local-feedback gap. 3 prior PRs merged (#3711, #3709, #3710). Full tick-shard hygiene ecosystem on main: audit + baseline + CI enforce gate + AUDIT-LIFECYCLE.md + this DX helper. Wrong-depth-.. bug class is mechanized end to end. Co-authored-by: Claude <noreply@anthropic.com>
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.
What
New doc at
tools/hygiene/AUDIT-LIFECYCLE.mdcapturing the 7-step pattern shared by both repo-hygiene audits that have completed it:lint (xxx)jobWorked examples in the doc
Includes
Step-ordering rationale, mutable-vs-immutable surface distinction for baseline strategy, pre-emptive scanner-author findings worth implementing in step 3 to shorten the quality loop.
Co-Authored-By: Claude noreply@anthropic.com