Skip to content

Doctor: audit lint default selection#100361

Merged
giodl73-repo merged 9 commits into
openclaw:mainfrom
giodl73-repo:doctor-lint-defaults-audit
Jul 8, 2026
Merged

Doctor: audit lint default selection#100361
giodl73-repo merged 9 commits into
openclaw:mainfrom
giodl73-repo:doctor-lint-defaults-audit

Conversation

@giodl73-repo

@giodl73-repo giodl73-repo commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Sets the default doctor --lint bar now that all tracked Doctor rule families have structured lint findings.
  • Keeps the default lint profile focused on broad-safe checks: static/local, low-noise, and actionable for most users in CI or preflight output.
  • Moves four historical/advisory or local-inventory checks out of default lint and keeps them available through doctor --lint --all or targeted --only:
    • core/doctor/legacy-state
    • core/doctor/session-transcripts
    • core/doctor/session-snapshots
    • core/doctor/skills-readiness
  • Updates Doctor docs to explain default --lint, full --lint --all, targeted --only, and why doctor --fix is a separate repair path rather than "--all plus writes".

Default-Lint Bar

Default doctor --lint should be safe for automation and routine preflight use. A check belongs in default lint when it is:

  • static or local-only
  • deterministic enough for CI/preflight use
  • low-noise on normal installs
  • actionable for most users without knowing their optional channels, accounts, services, or historical workspace state

Gateway config and auth stay in default lint because the public product contract treats the Gateway as required for normal OpenClaw operation; optional channel, account, inventory, live-service, and cleanup diagnostics remain explicit.

A check should be explicit-only when it is primarily advisory, historical cleanup, optional inventory, live-service dependent, account/channel-specific, deployment-sensitive, or repair-oriented. Those checks are still useful, but users should request them with --all or --only.

Why These Four Changed

  • legacy-state: scans historical migration state and can be broad/support-oriented rather than an active runtime failure.
  • session-transcripts: reports historical transcript cleanup/advisory state; useful for support, too noisy for broad automation.
  • session-snapshots: reports stale cached snapshot paths; useful cleanup signal, not a default preflight blocker.
  • skills-readiness: depends on optional local tool installs, environment, OS, and configured accounts; better as explicit inventory.

Non-Goals

  • Does not change doctor --fix repair behavior.
  • Does not add plugin, SDK, or config contract surface.
  • Does not freeze the full Doctor rule list in tests.
  • Does not change finding severity; severity remains per emitted finding (info, warning, or error).

Audit result for review

48 registered Doctor lint checks reviewed for default selection
Check ID Default --lint Severity range Class Review reason
core/doctor/gateway-config Yes warning-error broad-safe static config shape and local gateway config validation
core/doctor/claude-cli Yes warning broad-safe local CLI availability check used by the base doctor flow
core/doctor/gateway-auth Yes warning-error broad-safe static gateway auth configuration validation
core/doctor/command-owner Yes info broad-safe local owner-command discoverability signal with an actionable setup fix
core/doctor/ui-protocol-freshness Yes warning broad-safe local UI protocol freshness signal with established default behavior
core/doctor/codex-session-routes Yes warning broad-safe local route compatibility check for active session behavior
core/doctor/sandbox/registry-files Yes warning broad-safe local stale registry residue with an existing corrective path
core/doctor/gateway-services/extra Yes warning broad-safe local extra service state that can confuse gateway ownership
core/doctor/gateway-services/platform-notes Yes warning broad-safe platform-specific gateway service warnings already emitted by default doctor
core/doctor/security Yes warning broad-safe local security posture check with direct user action
core/doctor/browser Yes warning broad-safe local browser readiness check with established default behavior
core/doctor/browser-clawd-profile-residue Yes warning broad-safe local stale browser profile residue with a clear cleanup path
core/doctor/oauth-tls Yes warning broad-safe local OAuth TLS readiness needed for auth flow reliability
core/doctor/hooks-model Yes warning broad-safe static hooks model validation for configured provider behavior
core/doctor/provider-catalog-projection Yes warning-error broad-safe static provider catalog projection validation
core/doctor/runtime-tool-schemas Yes warning-error broad-safe static runtime tool schema validation
core/doctor/bootstrap-size Yes warning broad-safe local bootstrap size check that catches runtime startup risk
core/doctor/shell-completion Yes warning broad-safe local shell completion freshness check with established default behavior
core/doctor/final-config-validation Yes warning-error broad-safe final static config validation for canonical doctor correctness
core/doctor/auth-profiles No warning explicit-only account-shape dependent and can inspect local credential state
core/doctor/legacy-state No warning explicit-only legacy state migration scans historical state and can be broad
core/doctor/legacy-plugin-manifests No warning explicit-only legacy plugin cleanup rather than active runtime failure
core/doctor/legacy-plugin-dependencies No warning explicit-only legacy plugin dependency cleanup rather than active runtime failure
core/doctor/stale-plugin-runtime-symlinks No warning explicit-only stale runtime cleanup that may be normal in older workspaces
core/doctor/configured-plugin-installs No warning explicit-only configured plugin state can be environment-specific and noisy
core/doctor/plugin-registry No warning explicit-only registry migration signal can be noisy across plugin setups
core/doctor/disk-space No warning explicit-only machine-local capacity signal that can be intentionally transient
core/doctor/state-integrity No warning explicit-only state-store audit can be broad and support-oriented
core/doctor/session-locks No warning explicit-only historical session cleanup rather than current startup failure
core/doctor/session-transcripts No info explicit-only historical transcript cleanup emitted as advisory info
core/doctor/session-snapshots No info explicit-only historical session snapshot cleanup emitted as advisory info
core/doctor/config-audit-scrub No info-warning explicit-only historical audit-log cleanup rather than current config failure
core/doctor/legacy-whatsapp-crontab No warning explicit-only shell-backed legacy crontab inspection should be explicit
core/doctor/legacy-cron-store No warning explicit-only legacy cron store cleanup rather than current runtime failure
core/doctor/channel-plugin-blockers No warning explicit-only channel/plugin readiness depends on selected channel usage
core/doctor/channel-preview-warnings No warning explicit-only generic channel preview warnings are channel-specific advisory output
core/doctor/tool-result-cap No warning explicit-only policy/config preference check that may be intentionally configured
core/doctor/systemd-linger No warning explicit-only host service manager state is platform and deployment specific
core/doctor/workspace-status No info-warning explicit-only workspace diagnostics are support-oriented and can be noisy
core/doctor/skills-readiness No warning explicit-only optional skill inventory depends on local tool installs and configured accounts
core/doctor/heartbeat-template No warning explicit-only template rewrite readiness is repair-oriented historical state
core/doctor/gateway-health No warning-error explicit-only live gateway/service health can be environment-sensitive
core/doctor/whatsapp-responsiveness No warning explicit-only channel-specific live responsiveness should not affect broad lint
core/doctor/memory-search No warning explicit-only provider/workspace readiness is support-oriented and account dependent
core/doctor/device-pairing No warning explicit-only device pairing state is channel-specific and deployment dependent
core/doctor/gateway-daemon No warning explicit-only service daemon state is platform and deployment specific
core/doctor/write-config No warning explicit-only write-path blockers are repair-oriented and Nix/install-mode sensitive
core/doctor/workspace-suggestions No info explicit-only advisory workspace suggestions can be left unchanged indefinitely

Empty/default install smoke

Source-level isolated smoke after this change:

  • doctor --lint --json on an absent config/state under temp HOME runs 19 checks, skips 29, and reports only expected core setup/source-checkout findings: gateway-config and gateway-auth because Gateway config/auth are required for normal OpenClaw operation, plus source-checkout ui-protocol-freshness when the local checkout needs current UI assets.
  • doctor --lint --json --all remains intentionally not clean on an unconfigured temp install because --all includes explicit state/live/plugin/account inventory checks such as state integrity, gateway daemon/health, memory search, plugin registry, and skills readiness.

This confirms the audit reduced empty-install noise, while preserving --all as the full explicit audit profile.

Validation

  • node scripts/run-vitest.mjs src/flows/doctor-core-checks.test.ts src/flows/doctor-health-contributions.test.ts --pool forks --maxWorkers 1 --no-fileParallelism --reporter dot
  • corepack pnpm exec oxfmt --check docs/gateway/doctor.md src/flows/doctor-core-checks.ts src/flows/doctor-core-checks.test.ts src/flows/doctor-health-contributions.ts src/flows/doctor-health-contributions.test.ts
  • corepack pnpm exec oxlint --tsconfig config/tsconfig/oxlint.core.json src/flows/doctor-core-checks.ts src/flows/doctor-core-checks.test.ts src/flows/doctor-health-contributions.ts src/flows/doctor-health-contributions.test.ts
  • corepack pnpm tsgo:core
  • node scripts/plugin-sdk-surface-report.mjs --check
  • git diff --check origin/main...HEAD

@openclaw-barnacle openclaw-barnacle Bot added size: L maintainer Maintainer-authored PR labels Jul 5, 2026
@clawsweeper

clawsweeper Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed July 8, 2026, 5:30 PM ET / 21:30 UTC.

Summary
The PR marks legacy-state, skills-readiness, session-transcripts, and session-snapshots explicit-only for default doctor --lint, adds focused assertions, and updates Doctor docs for default, --all, --only, and --fix behavior.

PR surface: Source +6, Tests +12, Docs +22. Total +40 across 5 files.

Reproducibility: not applicable. this is a PR changing Doctor lint default-selection policy rather than a bug report with a failing current-main reproduction path. The behavior is checkable from PR-head source, adjacent tests, and the PR-body smoke output.

Review metrics: 1 noteworthy metric.

  • Doctor lint default profile: 4 checks changed from default to explicit-only. Default doctor --lint is an automation surface, so maintainers should notice the compatibility tradeoff even though explicit selection still works.

Stored data model
Persistent data-model change detected: migration/backfill/repair: src/flows/doctor-core-checks.test.ts, migration/backfill/repair: src/flows/doctor-core-checks.ts, migration/backfill/repair: src/flows/doctor-health-contributions.test.ts, migration/backfill/repair: src/flows/doctor-health-contributions.ts. Confirm migration or upgrade compatibility proof before merge.

Merge readiness
Overall: 🦞 diamond lobster
Proof: 🦞 diamond lobster
Patch quality: 🦞 diamond lobster
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Risk before merge

  • [P1] Existing automation that expected these four historical or advisory checks in default doctor --lint output will need to opt into --all or targeted --only; the PR documents this and keeps repair behavior unchanged.

Maintainer options:

  1. Land The Documented Default Profile (recommended)
    Accept that default lint skips these four noisy diagnostics while --all, --only, and repair paths keep them available.
  2. Keep The Old Default Profile
    Require the PR to leave these checks default-enabled if maintainers decide existing automation visibility matters more than lower-noise preflight output.

Next step before merge

  • No automated repair is needed; maintainers should handle landing after required checks because the remaining concern is intentional default-lint compatibility behavior on a protected-label PR.

Security
Cleared: The diff changes Doctor lint metadata, focused tests, and docs without dependency, workflow, secret-handling, package execution, or lockfile changes.

Review details

Best possible solution:

Land the documented default lint profile after required checks if maintainers accept the compatibility tradeoff, keeping the four diagnostics available through --all, --only, and Doctor repair flows.

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

Not applicable: this is a PR changing Doctor lint default-selection policy rather than a bug report with a failing current-main reproduction path. The behavior is checkable from PR-head source, adjacent tests, and the PR-body smoke output.

Is this the best way to solve the issue?

Yes, with maintainer acceptance of the compatibility tradeoff: using the existing defaultEnabled metadata at the check registration sites is narrower than a CLI denylist and keeps repair behavior unchanged.

AGENTS.md: found and applied where relevant.

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

Label changes

Label changes:

  • add merge-risk: 🚨 compatibility: Merging changes default doctor --lint output for existing automation that currently sees these four diagnostics without --all or --only.
  • add proof: sufficient: Contributor real behavior proof is sufficient. The PR body includes after-change source-level isolated smoke output for default and --all lint profiles with run/skip counts and expected findings.
  • add rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (live_output): The PR body includes after-change source-level isolated smoke output for default and --all lint profiles with run/skip counts and expected findings.

Label justifications:

  • P2: This is a normal-priority Doctor lint/docs behavior change with limited blast radius and no blocking correctness finding.
  • merge-risk: 🚨 compatibility: Merging changes default doctor --lint output for existing automation that currently sees these four diagnostics without --all or --only.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (live_output): The PR body includes after-change source-level isolated smoke output for default and --all lint profiles with run/skip counts and expected findings.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR body includes after-change source-level isolated smoke output for default and --all lint profiles with run/skip counts and expected findings.
Evidence reviewed

PR surface:

Source +6, Tests +12, Docs +22. Total +40 across 5 files.

View PR surface stats
Area Files Added Removed Net
Source 2 8 2 +6
Tests 2 12 0 +12
Docs 1 25 3 +22
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 5 45 5 +40

What I checked:

  • PR-head implementation: PR head adds defaultEnabled: false to core/doctor/legacy-state and core/doctor/skills-readiness, leaving their detect/repair logic in place. (src/flows/doctor-core-checks.ts:425, d5d88a0db147)
  • PR-head contribution checks: PR head adds defaultEnabled: false to the session transcript and session snapshot health checks while keeping both reachable through the existing contribution registrations. (src/flows/doctor-health-contributions.ts:1772, d5d88a0db147)
  • Current-main selector contract: Current main already skips default-disabled checks only when --only is absent and includeAllChecks is false, so the PR uses the existing lint-selection seam instead of adding a second selector path. (src/flows/doctor-lint-flow.ts:38, b63317d07e8d)
  • Current-main gap: Current main registers legacy-state, skills-readiness, session-transcripts, and session-snapshots without these new explicit-only markings, so the PR is still useful and not implemented on main. (src/flows/doctor-core-checks.ts:425, b63317d07e8d)
  • Docs update: PR head documents the default lint profile, opt-in --all/--only behavior, and the separate Doctor repair path. Public docs: docs/gateway/doctor.md. (docs/gateway/doctor.md:93, d5d88a0db147)
  • Release/current-main provenance: The latest release tag is v2026.6.11 at e085fa1a3ffd32d0ea6917e1e6fb4ecbffbb77d2; the PR head is not contained in any release tag and current main still lacks the requested default-selection changes. (e085fa1a3ffd)

Likely related people:

  • vincentkoc: Current-main blame points to recent Doctor lint runner and central health-check registration maintenance on the affected files. (role: current-main area contributor; confidence: high; commits: a24f15dc4d9e, 22376d80e163; files: src/flows/doctor-lint-flow.ts, src/flows/doctor-core-checks.ts, src/flows/doctor-health-contributions.ts)
  • giodl73-repo: Beyond this PR, the merged write-config lint slice uses the same default-disabled Doctor lint pattern and was authored as the adjacent policy slice. (role: recent Doctor lint contributor; confidence: high; commits: b1f3986b84f7; files: src/flows/doctor-health-contributions.ts, src/flows/doctor-health-contributions.test.ts)
  • galiniliev: Live PR metadata shows this person assigned, and their review mapped the default-lint compatibility question and best-fix evidence for this PR. (role: recent reviewer and assignee; confidence: medium; files: src/flows/doctor-core-checks.ts, src/flows/doctor-health-contributions.ts, docs/gateway/doctor.md)
  • Peter Steinberger: History shows the Doctor contribution orchestration that owns this lint/fix boundary was introduced in the central flow contribution refactor. (role: introduced contribution structure; confidence: medium; commits: 7d6d642cb825; files: src/flows/doctor-health-contributions.ts)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

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.

How this review workflow works
  • 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.
Review history (7 earlier review cycles)
  • reviewed 2026-07-05T15:19:20.087Z sha 3d55fbc :: found issues before merge. :: [P3] Update the lint docs for the narrower default profile
  • reviewed 2026-07-05T23:54:45.935Z sha 5502a54 :: needs maintainer review before merge. :: none
  • reviewed 2026-07-06T00:00:51.069Z sha 5502a54 :: needs maintainer review before merge. :: none
  • reviewed 2026-07-06T00:24:27.202Z sha bad984d :: needs maintainer review before merge. :: none
  • reviewed 2026-07-06T01:13:33.641Z sha bad984d :: needs maintainer review before merge. :: none
  • reviewed 2026-07-06T15:40:59.503Z sha bad984d :: needs maintainer review before merge. :: none
  • reviewed 2026-07-08T21:22:54.323Z sha 73650b9 :: needs maintainer review before merge. :: none

@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. labels Jul 5, 2026
@giodl73-repo
giodl73-repo force-pushed the doctor-lint-defaults-audit branch from 3d55fbc to 52a5bda Compare July 5, 2026 23:36
@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation gateway Gateway runtime size: M and removed size: L labels Jul 5, 2026
@giodl73-repo

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Rebased after #100093 landed and updated the PR scope: the parent write-config slice is no longer in the diff. This now also makes defaultEnabled?: boolean explicit on the public HealthCheck registration contract and updates Doctor docs to describe default --lint, --lint --all, --only, and why doctor --fix is not equivalent to --lint --all plus writes. PR body has the 48-check default on/off audit table and current validation proof.

@clawsweeper

clawsweeper Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@giodl73-repo

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Updated after maintainer feedback: removed the broad executable audit test so the PR no longer freezes the full Doctor rule list. The audit table remains in the PR body as review evidence only. Tests now cover only the default behavior changes this PR makes: legacy state, skills readiness, session transcripts, and session snapshots default to explicit-only lint. Public HealthCheck.defaultEnabled contract and docs remain in the diff.

@clawsweeper

clawsweeper Bot commented Jul 5, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@giodl73-repo
giodl73-repo marked this pull request as ready for review July 5, 2026 23:48
@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. labels Jul 5, 2026
@giodl73-repo

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

Final scope adjustment: removed the public HealthCheck.defaultEnabled contract change. defaultEnabled remains internal Doctor runner selection metadata; docs now explain the built-in default lint profile without adding plugin/SDK surface. PR body updated accordingly.

@clawsweeper

clawsweeper Bot commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event repository_dispatch).
Result: the existing ClawSweeper review comment will be edited in place when the review finishes.

@galiniliev galiniliev left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doctor lint default selection review: this PR narrows default openclaw doctor --lint by marking four advisory/environment-sensitive checks explicit-only while preserving --all, targeted --only, and repair paths. That matters because default lint output is a public automation surface, even though the code change is small.

LOC: +45/-5 (5 files)
By: Gio Della-Libera (@giodl73-repo, acct 2025-09-30) | OpenClaw: 228 PRs, 14 issues, 186 commits/12mo | GitHub: 60 repos, 6723 commits, 279 PRs, 29 issues, 17 reviews/12mo

Findings: No blocking findings.

Bug/behavior: no linked bug; this is a policy/default-profile change for doctor --lint. Current origin/main registers core/doctor/legacy-state, core/doctor/skills-readiness, core/doctor/session-transcripts, and core/doctor/session-snapshots without defaultEnabled: false, so default lint selects them. PR head adds defaultEnabled: false for those checks in src/flows/doctor-core-checks.ts:395, src/flows/doctor-core-checks.ts:843, src/flows/doctor-health-contributions.ts:1760, and src/flows/doctor-health-contributions.ts:1793.

Evidence map: changed surface is Doctor lint selection metadata and docs. Runtime entry point is runDoctorLintChecks, which skips default-disabled checks only when --only is absent and includeAllChecks is false (src/flows/doctor-lint-flow.ts:28). Caller path is the maintenance CLI passing --all through includeAllChecks (src/cli/program/register.maintenance.ts:64, src/commands/doctor-lint.ts:90). Callee/repair path is runDoctorHealthRepairs, which normalizes and runs the provided checks without consulting the lint default profile (src/flows/doctor-repair-flow.ts:41). Sibling default-disabled checks already use the same internal metadata, and adjacent tests cover skip/only/all behavior plus the four newly default-disabled registrations (src/flows/doctor-lint-flow.test.ts, src/flows/doctor-core-checks.test.ts:319, src/flows/doctor-health-contributions.test.ts:1327, src/flows/doctor-health-contributions.test.ts:1471). Docs now describe the default profile, --all, --only, and the separate fix path in docs/gateway/doctor.md:83.

Best-fix verdict: acceptable/best implementation for the stated policy, pending maintainer acceptance of the compatibility tradeoff. The patch uses the existing selector bit at the check registration site, keeps the public HealthCheck contract unchanged, and avoids adding a second hard-coded selector list in the CLI.

Alternatives considered: keeping a CLI-side denylist would duplicate ownership outside the check registrations; making defaultEnabled public SDK surface would broaden plugin/API contract unnecessarily; leaving these four checks default-enabled would preserve current automation output but would not satisfy the PR's stated low-noise default lint goal.

Provenance: N/A for a feature/policy change.

Validation reviewed: PR-head GitHub checks are green/neutral/skipped only (78 success, 1 neutral, 35 skipped). I also ran pnpm docs:list and read docs/AGENTS.md, docs/gateway/doctor.md, the CLI lint wiring, lint/repair runners, changed checks, sibling default-disabled checks, and adjacent tests. I did not rerun the focused Vitest/tsgo commands locally; no remote E2E was needed for this static default-selection change.

Remaining uncertainty: maintainer/product decision only: whether default doctor --lint should stop surfacing these four diagnostics for existing automation unless users opt into --all or --only.

@galiniliev galiniliev assigned galiniliev and unassigned steipete Jul 8, 2026
@giodl73-repo

Copy link
Copy Markdown
Contributor Author

Maintainer decision: accepted the default-lint compatibility tradeoff for this audit slice.

We are intentionally keeping legacy-state, skills-readiness, session-transcripts, and session-snapshots out of the default openclaw doctor --lint profile because these are advisory, historical, or environment-sensitive diagnostics that are too noisy for routine automation. They remain available through openclaw doctor --lint --all and targeted --only, and repair behavior is unchanged.

This addresses the remaining ClawSweeper/Galin policy caveat; no further code change requested for this point.

@giodl73-repo

Copy link
Copy Markdown
Contributor Author

Merged as 7d82e5b from source head d5d88a0.

Maintainer note: we accepted the default-lint compatibility tradeoff for this audit slice. The four advisory/environment-sensitive checks remain available via openclaw doctor --lint --all or targeted --only, while default doctor --lint stays low-noise for routine automation. Plugin/SDK public contracts are unchanged.

Verification before merge: exact-head hosted gates passed for d5d88a0: CI#28976811444 and Workflow Sanity#28976811343. Local broad pnpm check was blocked by a shrinkwrap guard failure that reproduced on current origin/main, outside this five-file Doctor diff.

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: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P2 Normal backlog priority with limited blast radius. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants