Repository navigation
docs(doctor): Doctor repairs session provider aliases instead of refusing them - #163729
Conversation
Since #163171, Doctor repairs session rows that still carry provider/lastProvider aliases and runtime reads raise a migration-required error until it runs; only room-without-groupChannel rows stay refused with 2026.9.5 intermediate-upgrade guidance. Also drop the retired provider/room names from the session labeling-field list.
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed October 2, 2026, 3:13 PM ET / 19:13 UTC. ClawSweeper reviewWhat this changesUpdates Doctor’s session migration guidance and replaces retired session labeling fields with their current names. Merge readiness✅ Ready for maintainer review This PR remains useful: current main still contains both stale descriptions, and the corrections match the merged repair implementation. No actionable patch defects were found. Priority: P3 Review scores
Verification
How this fits togetherDoctor repairs older session records before the Gateway reads them. These documentation pages explain the repair commands and the metadata stored for conversations. flowchart TD
A[Older session records] --> B{Legacy fields}
B -->|Provider aliases| C[Doctor backup and repair]
C --> D[Canonical delivery state]
D --> E[Gateway session reads]
B -->|Retired room conversion| F[Intermediate release migration]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceDocs 0. Total 0 across 2 files. View PR surface stats
Review metricsNone. Technical reviewBest possible solution: Keep the documentation aligned with Doctor’s existing repair owner and preserve the separate guidance for retired room conversion. Do we have a high-confidence way to reproduce the issue? Not applicable to a prose-only patch; source inspection confirms the stale guidance on current main and the existing repair behavior. Is this the best way to solve the issue? Yes. Correcting the two descriptions is the narrowest solution and agrees with the existing CLI migration documentation. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 59c4f37a8f95. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
…nclaw#163729) Since openclaw#163171, Doctor repairs session rows that still carry provider/lastProvider aliases and runtime reads raise a migration-required error until it runs; only room-without-groupChannel rows stay refused with 2026.9.5 intermediate-upgrade guidance. Also drop the retired provider/room names from the session labeling-field list.
Related: #163171
What Problem This Solves
The Doctor state-and-sessions page still says session rows with
providerorlastProvideraliases are refused and must be migrated with an older OpenClaw release. Since #163171, current Doctor repairs those rows itself, so operators following the page would take an unnecessary intermediate-upgrade detour.User Impact
User impact: the Doctor docs now match current behavior. Session reads refuse rows with
provider/lastProvideraliases with a migration-required error untilopenclaw doctor --fixruns; Doctor backs up the affected SQLite databases and rewrites the aliases into the canonicaldeliverystate and its query projections. Rows that still need the retiredroom→groupChannelconversion remain refused, with the same2026.9.5intermediate-upgrade guidance already given on the CLI Doctor state-migrations page. No runtime behavior changes.Why This Change Was Made
#163171 split the old combined refusal:
roomstays refused (assertSupportedSessionStoreEntry), whileprovider/lastProviderbecame Doctor-owned repairs (hasLegacySessionProviderState→repairLegacySessionEntryStates, withprojectCanonicalSessionEntryShapethrowingSessionStoreMigrationRequiredErroruntil then). That PR updateddocs/cli/doctor/state-migrations.mdbut not the gateway Doctor page.The session schema reference also listed
providerandroomas current group/channel labeling fields. Neither is aSessionEntryfield anymore; the metadata writer storessubject,groupChannel,space, anddisplayName, so that list now names those.Evidence
src/config/sessions/{supported-session-store,session-entry-state-format,store-entry-shape,metadata,types}.ts,src/commands/doctor-session-delivery-state.ts,src/commands/doctor/shared/session-entry-shape.ts, andsrc/infra/state-migrations.legacy-session-store.ts; no later commits touch these owners.docs/forlastProvider,provider alias, and the old refusal wording; the gateway Doctor page was the only remaining stale statement (otherprovider aliashits are unrelated model/secret provider aliases).pnpm check:docs: passed (docs format 1326 files clean, markdownlint 0 issues, MDX check, i18n glossary, 14763 internal links with 0 broken, config examples, changelog check).git diff --check: clean.