Skip to content

chore(docs): audit external links without gating PRs - #114643

Merged
steipete merged 2 commits into
mainfrom
maint/docs-external-link-audit
Jul 27, 2026
Merged

steipete merged 2 commits into
mainfrom
maint/docs-external-link-audit

Conversation

@steipete

@steipete steipete commented Jul 27, 2026 •

Copy link
Copy Markdown
Contributor

Related: #114021, #114028, #114057

What Problem This Solves

Fixes an issue where broken external documentation links could remain on main because the existing docs link audit deliberately skips every HTTP(S) target in scripts/docs-link-audit.mjs:474-475.

The gap was visible when three independent dead links needed manual fixes in #114021, #114028, and #114057. The same audit found additional unreachable links in public docs and release notes.

Why This Change Was Made

Adds a weekly, manually dispatchable Lychee audit pinned to reviewed action and engine releases. It has no pull-request trigger and uses fail: false, so third-party outages, rate limits, bot walls, and transient network failures can only appear in the job summary and retained report artifact; they never gate PR CI.

The workflow limits requests to HTTP(S), excludes internal/private/link-local/loopback targets and known bot walls, accepts authentication/rate-limit responses, and retries transient failures. The docs changes repair only targets reverified as unreachable; seven release-note links that returned 200 during fresh validation were deliberately left unchanged.

AI-assisted maintainer change. Follow-up credit for the three motivating fixes belongs to @santhiprakash.

User Impact

Readers get working provider, protocol-schema, support, threat-model, release-note, and external-tool links. Maintainers get a scheduled report for future external-link drift without making contributor PRs depend on third-party availability.

Evidence

  • Current-main reproduction: a fixture containing https://127.0.0.1:1/definitely-not-served produced {"checked":0,"broken":[]} from auditDocsLinks; the tested script blob exactly matched origin/main.
  • Fresh motivating-link checks: SenseAudio 404 -> 200; Anthropic old target hit redirect-limit failure while the replacement returned 200; Copilot CLI 404 -> 200.
  • Every retained replacement was rechecked live. All new targets returned 200; removed targets were 404 (the Anthropic loop above is already fixed on main).
  • Lychee 0.24.2 checked all 11 replacement targets: 11 successful, 0 failures, 0 timeouts.
  • Filter fixture: one public URL checked, three internal/bot-wall URLs excluded, 0 errors/timeouts.
  • actionlint .github/workflows/docs-external-links.yml
  • node scripts/check-docs-mdx.mjs <11 changed docs>: passed.
  • node scripts/docs-link-audit.mjs: 6,216 internal links checked, 0 broken.
  • Targeted oxfmt and git diff --check: passed.
  • Codex autoreview: clean after repairing its two findings (Lychee include precedence and hidden artifact upload).
  • Independent adversarial refuter: NO-ACTIONABLE-OBJECTION.
  • Final diff: 12 files, +77/-29. Non-test growth is the 61-line scheduled workflow; the custom 1,126-line crawler, 695-line test, declaration file, and parser dependency from the parked stack were removed before publication.
  • Hosted pre-merge dispatch is not available for a newly added workflow: gh workflow run docs-external-links.yml --ref maint/docs-external-link-audit returns HTTP 404 because GitHub requires the workflow file to exist on the default branch. The closest hosted proof is exact-head PR CI plus successful Blacksmith ARM pnpm check:changed runs 30289851705 and 30290820195. Because this workflow is scheduled/manual only and fail: false, the safe rollout is to merge, immediately dispatch it from main, and verify the retained artifact before closeout.
  • Post-merge verification completed: manual main run 30292013410 succeeded and retained artifact docs-external-link-audit (ID 8663464604, expires 2026-08-10). The downloaded 2,246-byte report.md contained 9,940 occurrences / 6,149 unique URLs, 5,052 successful, 4,873 excluded, 103 redirects, 15 advisory errors, and 0 timeouts.

@steipete
steipete marked this pull request as ready for review July 27, 2026 16:55
@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation gateway Gateway runtime labels Jul 27, 2026
@steipete
steipete requested a review from a team as a code owner July 27, 2026 16:55
@openclaw-barnacle openclaw-barnacle Bot added size: S maintainer Maintainer-authored PR labels Jul 27, 2026
@clawsweeper clawsweeper Bot added rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. labels Jul 27, 2026
@clawsweeper

clawsweeper Bot commented Jul 27, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs real behavior proof before merge. Reviewed July 27, 2026, 1:52 PM ET / 17:52 UTC.

ClawSweeper review

What this changes

Adds a weekly and manually dispatchable non-blocking Lychee external-link audit with a retained report artifact, while correcting or removing externally unreachable documentation links.

Merge readiness

⛔ Blocked until stronger real behavior proof is added - 3 items remain

Keep this PR open. The proposed advisory workflow is a bounded way to find external-link drift without making contributor CI depend on third-party sites, but the current head still lacks proof that a manual GitHub Actions dispatch creates and retains the promised report artifact. The maintainer label also requires explicit human handling.

Likely related people: steipete is the current workflow and audit contributor (low confidence for longer-term ownership); santhiprakash is connected through the three merged motivating documentation repairs (medium confidence).

Priority: P3
Reviewed head: b56bdd371926d5c240197978090856a906f06a33

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) The implementation is focused and the static validation is credible, but real hosted-workflow proof remains a merge gate.
Proof confidence 🦪 silver shellfish (2/6) Needs stronger real behavior proof before merge: The PR body provides useful live URL and local Lychee evidence, but it does not show an after-fix manual GitHub Actions run producing the newly added retained report artifact. Add redacted run output or artifact evidence; redact private endpoints, IP addresses, and credentials before posting it. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Needs proof Needs stronger real behavior proof before merge: The PR body provides useful live URL and local Lychee evidence, but it does not show an after-fix manual GitHub Actions run producing the newly added retained report artifact. Add redacted run output or artifact evidence; redact private endpoints, IP addresses, and credentials before posting it. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
Evidence reviewed 4 items Workflow scope: The proposed workflow has only schedule and workflow_dispatch triggers, uses read-only repository permissions, sets Lychee fail: false, and uploads .artifacts/docs-external-links even when the audit step reports failures; this matches the stated non-gating design.
Action contract: The Lychee action supports a Markdown output file and a non-failing mode, so the requested artifact path is a supported implementation shape; the remaining question is whether this exact workflow run produces the artifact on GitHub Actions.
Prior review continuity: The preceding ClawSweeper review at the same head SHA requested a manually dispatched run showing the retained report artifact. The supplied current PR body and head commit list add no dispatch run, artifact, terminal output, or linked workflow evidence that resolves that request.
Findings None None.
Security None None.

How this fits together

OpenClaw’s existing documentation checks validate repository-local links during development, while this new GitHub Actions workflow would periodically probe public HTTP(S) targets that can decay after a release. It reads Markdown and docs metadata, filters unsafe or noisy destinations, then uploads a report for maintainers without changing pull-request gating.

flowchart LR
  A[Repository docs and Markdown] --> B[Scheduled or manual workflow]
  B --> C[External-link filter]
  C --> D[Lychee HTTP(S) audit]
  D --> E[Markdown report]
  E --> F[Retained Actions artifact]
  F --> G[Maintainer follow-up]
Loading

Before merge

  • Add real behavior proof - Needs stronger real behavior proof before merge: The PR body provides useful live URL and local Lychee evidence, but it does not show an after-fix manual GitHub Actions run producing the newly added retained report artifact. Add redacted run output or artifact evidence; redact private endpoints, IP addresses, and credentials before posting it. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.
  • Resolve merge risk (P1) - The workflow has not been shown running through GitHub Actions, so maintainers do not yet have direct evidence that its exact Lychee configuration writes .artifacts/docs-external-links/report.md and that the upload step retains it as intended.
  • Complete next step (P2) - A maintainer must preserve the non-gating policy and require contributor-supplied hosted-run proof; there is no narrow code repair to dispatch automatically.
Agent review details

Security

None.

PR surface

Docs -13, Config +61. Total +48 across 12 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 0 0 0 0
Docs 11 16 29 -13
Config 1 61 0 +61
Generated 0 0 0 0
Other 0 0 0 0
Total 12 77 29 +48

Review metrics

Metric Value Why it matters
New advisory workflow 1 scheduled/manual workflow added This introduces a recurring automation path that must be demonstrated once on GitHub Actions, even though it intentionally does not gate PRs.

Merge-risk options

Maintainer options:

  1. Prove the dispatched report path (recommended)
    Manually dispatch the workflow and add redacted run output plus evidence that the docs-external-link-audit artifact contains the generated report before merge.

Technical review

Best possible solution:

Keep the audit advisory and non-PR-gating, then attach redacted evidence from one manual dispatch showing the Lychee result and the downloaded or visible retained report artifact before merging.

Do we have a high-confidence way to reproduce the issue?

Yes, at source level: the PR documents that the current internal docs audit excludes HTTP(S) targets, and its fixture demonstrates that behavior. I do not have independent current-head execution evidence for the new hosted workflow itself.

Is this the best way to solve the issue?

Unclear until a manual dispatch is shown. The non-gating scheduled audit is a focused solution, but its artifact contract should be proven in the environment that will run it.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against d9e6d0026136.

Labels

Label changes:

  • add rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🐚 platinum hermit.
  • remove rating: 🦐 gold shrimp: Current PR rating is rating: 🦪 silver shellfish, so this older rating label is no longer current.

Label justifications:

  • P3: This is low-risk documentation and maintenance automation rather than an urgent runtime regression.
  • merge-risk: 🚨 automation: The PR adds a scheduled GitHub Actions workflow whose artifact-producing behavior is not yet proven in the hosted runner.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🐚 platinum hermit.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask. Needs stronger real behavior proof before merge: The PR body provides useful live URL and local Lychee evidence, but it does not show an after-fix manual GitHub Actions run producing the newly added retained report artifact. Add redacted run output or artifact evidence; redact private endpoints, IP addresses, and credentials before posting it. After adding proof, update the PR body; ClawSweeper should re-review automatically. If it does not, the PR author or someone with repository write access can comment @clawsweeper re-review.

Evidence

What I checked:

  • Workflow scope: The proposed workflow has only schedule and workflow_dispatch triggers, uses read-only repository permissions, sets Lychee fail: false, and uploads .artifacts/docs-external-links even when the audit step reports failures; this matches the stated non-gating design. (.github/workflows/docs-external-links.yml:1, b56bdd371926)
  • Action contract: The Lychee action supports a Markdown output file and a non-failing mode, so the requested artifact path is a supported implementation shape; the remaining question is whether this exact workflow run produces the artifact on GitHub Actions. (.github/workflows/docs-external-links.yml:22, b56bdd371926)
  • Prior review continuity: The preceding ClawSweeper review at the same head SHA requested a manually dispatched run showing the retained report artifact. The supplied current PR body and head commit list add no dispatch run, artifact, terminal output, or linked workflow evidence that resolves that request. (.github/workflows/docs-external-links.yml:52, b56bdd371926)
  • Related fixes: The three motivating broken-link corrections are already merged, so they are useful evidence for the broader audit’s motivation but do not supersede the new scheduled-audit workflow. Public docs: docs/tools/acp-agents-setup.md. (docs/tools/acp-agents-setup.md:37, ff20dd7e3ff4)

Likely related people:

  • steipete: Authored both commits in the current branch, including the advisory audit workflow and the accompanying documentation repairs. (role: recent docs-audit contributor; confidence: low; commits: b1b8d9a7e460, b56bdd371926; files: .github/workflows/docs-external-links.yml, docs/security/formal-verification.md)
  • santhiprakash: Authored the three merged link-repair PRs cited as the concrete motivation for recurring external-link auditing. (role: related documentation contributor; confidence: medium; commits: 445774d85e15, 13bbcabeabae, ff20dd7e3ff4; files: docs/providers/senseaudio.md, docs/reference/token-use.md, docs/tools/acp-agents-setup.md)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Manually dispatch the workflow and attach redacted evidence that the audit completes and uploads the report artifact.
  • Update the PR body with that proof; if an automatic refresh does not occur, ask a maintainer to comment @clawsweeper re-review.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (1 earlier review cycle)
  • reviewed 2026-07-27T17:01:28.023Z sha b56bdd3 :: needs real behavior proof before merge. :: none

@steipete steipete closed this Jul 27, 2026
@steipete steipete reopened this Jul 27, 2026
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Jul 27, 2026
@steipete
steipete merged commit fd0fdcc into main Jul 27, 2026
260 of 274 checks passed
@steipete
steipete deleted the maint/docs-external-link-audit branch July 27, 2026 18:02
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to documentation gateway Gateway runtime maintainer Maintainer-authored PR merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. size: S status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant