Skip to content

feat(check-links): exclude docs/reviews/PR-*.md from orphan check (SPEC §6.2) - #145

Merged
thrillmot merged 2 commits into
mainfrom
feat/check-links-exclude-review-writebacks
Jun 5, 2026
Merged

feat(check-links): exclude docs/reviews/PR-*.md from orphan check (SPEC §6.2)#145
thrillmot merged 2 commits into
mainfrom
feat/check-links-exclude-review-writebacks

Conversation

@thrillmot

Copy link
Copy Markdown
Collaborator

Summary

  • Extend linkcheck.DefaultAllowOrphans with docs/reviews/ (matches the existing docs/decisions-branches/ directory-prefix precedent) so docs/reviews/PR-<n>.md review-writebacks no longer fail logmind check-links as orphan markdown.
  • Add two unit tests in internal/linkcheck/linkcheck_test.go covering the PR-writeback case + the multi-file case (including a hypothetical docs/reviews/README.md).

Why

clud-bug-app writes docs/reviews/PR-<n>.md per SPEC §6.2 as append-only review telemetry — same files logmind sync already reads in internal/skill/sync.go to roll citation counts into skill PROVENANCE.md. By design these files are never cross-linked from README.md / AGENTS.md / docs/, so today they trip check-links' orphan-markdown rule and fail CI on every PR that picks up a review.

This is recurring across every PR org-wide that gets a review. Currently blocking thrillmade/clud-bug#147. Per principal engineer rec: ship the structural fix here in logmind rather than the per-repo .logmindignore route — logmind has authoritative knowledge of the SPEC §6.2 path convention (it's the consumer of those files), and a built-in default means every repo on v1.0.x+ picks up the fix on the next bump with no per-repo friction.

Alternatives considered

  • Per-repo .logmindignore entry: tax replicated across every consumer; logmind already encodes this path via internal/skill/sync.go.
  • Change clud-bug-app to stop writing the file: breaks SPEC §6.2 contract; the file is the load-bearing input for logmind sync.
  • Glob-pattern allowlist (PR-*.md): over-engineers the isAllowedOrphan mechanism (currently exact-match + dir-prefix); the entire docs/reviews/ directory is convention-owned by the App + sync pipeline.

Implications

  • Every repo on logmind v1.0.x+ gets the fix free on next bump.
  • clud-bug#147 unblocks; future PRs across the org stop failing check-links from review-writebacks.

Test plan

  • go test ./internal/linkcheck/... -race -count=1 — all 14 tests pass (12 prior + 2 new).
  • go test ./... -race -count=1 — full suite green (no parity regression).
  • logmind check-links on this repo — All markdown links resolve and no orphans found.
  • CI green on this PR.

Follow-up

Once merged we'll need a v1.0.x patch release so consumer repos pick the fix up via brew. Cask-bump is GoReleaser-wired off tag push; that's a separate action.

🤖 Generated with Claude Code

thrillmot added 2 commits June 5, 2026 14:50
Side-effects of running legacy Python logmind v0.6.16 (the only install
with a 'log' subcommand) in a repo that's moved to v1.0.0 templates:
the older binary downgrades the AGENTS.md block to v5-slim and rewrites
docs/timeline.md without the brief auto-collapse. Restore both to match
origin/main, with the new decision row included in the brief format.

[skip-logmind]
@thrillmot
thrillmot enabled auto-merge (squash) June 5, 2026 18:52
@claude

claude Bot commented Jun 5, 2026

Copy link
Copy Markdown

Claude finished @thrillmot's task in 2m 7s —— View job


PR #145 Review — feat(check-links): exclude docs/reviews/PR-*.md from orphan check

Tasks

  • Load tools
  • Fetch diff + read changed files
  • Check skills
  • Analyze for critical issues
  • Post inline findings (none — 0 critical findings)
  • Emit structured summary

No critical issues found. Change is minimal and correct.

@github-actions

github-actions Bot commented Jun 5, 2026

Copy link
Copy Markdown
Contributor

🐛 Clud Bug review

This round: 0 critical · 0 minor · 0 resolved from prior · 0 still open

Found: 0 🔴 / 0 🟡 / 0 🟣

Per-skill scan

  • [critical-issues-only]: scanned all 4 changed files. 0 findings.
  • [evidence-based-review]: applied to all findings. 0 findings — nothing to anchor.
  • [respect-existing-conventions]: dir-prefix pattern matches existing docs/decisions-branches/ precedent. 0 findings.
  • [clud-bug-collaboration]: not applicable — this is an inbound PR review, not a fix-push or skill edit.

Skills referenced: [critical-issues-only, evidence-based-review, respect-existing-conventions]

@thrillmot
thrillmot merged commit 231aa2a into main Jun 5, 2026
10 checks passed
@thrillmot
thrillmot deleted the feat/check-links-exclude-review-writebacks branch June 5, 2026 18:55
thrillmot added a commit that referenced this pull request Jun 5, 2026
…(G3.b extension v2) (#146)

Supersedes #142 (which got tangled in multiple rebase cycles after the
§8.6 wave + #145 landed).

Same content as #142: removes the legacy per-repo `clud-bug-review.yml`
workflow + updates AGENTS.md + .cursorrules to point at the GitHub App.

The App (App ID 3944857, scope=all) now reviews PRs — workflow is
redundant.

This is the **tooling-repo half** of G3.b. Consumer cascade landed
earlier today:
- thrillmade/agent-skills#117
- thrillmade/clud-bug-app#11
- thrillmade/tokenomics#70
- thrillmade/reporulez#50
- thrillmade/rezgen#26

Remaining: thrillmade/clud-bug#147 (failing on check-links until logmind
v1.0.1 patch propagates the docs/reviews/PR-*.md exclude shipped in
#145).

Co-authored-by: thrillmot <thrillmot@users.noreply.github.com>
thrillmot added a commit to thrillmade/clud-bug that referenced this pull request Jun 5, 2026
…xclude docs/reviews/) (#149)

## Summary

Bumps the logmind install pin in `.github/workflows/check-doc-links.yml`
from `v1.0.0` → `v1.0.1` so this repo's CI picks up the orphan-markdown
fix shipped in [logmind PR
#145](thrillmade/logmind#145).

## Why

logmind v1.0.1 (shipped 2026-06-05T20:13Z) carries the structural fix
that excludes `docs/reviews/PR-*.md` from the orphan-markdown check.
Without this bump, every PR that touches `docs/reviews/` trips the
check-links gate — most recently hit on clud-bug#147 and the same
false-positive pattern is recurring org-wide on consumers still pinned
at v1.0.0.

This propagates the fix to clud-bug's CI. Surgical 2-line change:
- `curl ... /v1.0.0/installer/install.sh` →
`/v1.0.1/installer/install.sh`
- Adjacent comment `pinned to v1.0.0 tag` → `pinned to v1.0.1 tag`

## Out of scope

Other workflows in this repo (`regen-timeline.yml`,
`logmind-self-update.yml`) also pin logmind at v1.0.0. Those are
intentionally not touched here — different concern (timeline regen /
self-update plumbing, no check-links interaction). Separate PR can sweep
them.

## Test plan

- [ ] CI green on this PR (check-doc-links job uses the new pin)
- [ ] After merge, next PR touching `docs/reviews/PR-*.md` no longer
trips check-links

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: thrillmot <thrillmot@users.noreply.github.com>
Co-authored-by: clud-bug[bot] <0+clud-bug[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant