Repository navigation
refactor(sessions): simplify maintenance ownership - #175778
Conversation
|
🦞👀 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 SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: needs maintainer review before merge. What this changesThis PR removes redundant session-maintenance preparation, lease queries, worker-result checks, and cleanup callbacks. Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Both prior findings are addressed, and no new actionable defect was found; this maintainer-authored PR remains open while exact-head CI completes. Priority: P2 Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherSession storage receives maintenance and deletion requests, runs planning and durable mutations through existing database workers, and publishes committed changes and retained transcript archives. flowchart TD
A[Maintenance and deletion requests] --> B[Existing execution owner]
B --> C[Worker preparation]
C --> D[SQLite transaction]
D --> E[Commit settlement]
E --> F[Archive publication]
F --> G[Lifecycle cleanup]
Technical reviewBest possible solution: Retain the existing execution and storage owners with this smaller implementation, subject to the normal exact-head CI gate. Do we have a high-confidence way to reproduce the issue? This is a refactor rather than a new bug report; the previous review's two concrete failures are addressed by the repair diff and reported focused validation. Is this the best way to solve the issue? The change follows the existing owners and removes duplicate internal checks while preserving current-row validation, live admission, commit settlement, and archive durability. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against a1383a8e8900. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource -134, Tests -145. Total -279 across 29 files. Added test files: 0. View PR surface stats
Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (1 earlier review cycle)
Reviewed October 17, 2026, 6:15 PM ET / 22:15 UTC (Revision 2). |
|
@clawsweeper re-review Repair head 52d5637 and PR body are current. Original changed-path lint and maintenance assertion failures are repaired; all three maintenance failures now pass focused proof. Full proof and four unresolved local consumer timeouts remain disclosed in the body. No timeout, retry, skip, assertion or suppression relaxation. New exact-head CI remains the broad gate. |
|
🦞👀 Re-review progress:
|
|
Merged via squash.
|
A revoked maintenance caller must not retire the shared native generation retained by another admitted reply. Remove the maintenance-specific forced retirement and its unused preparation option. This follows #175778's intended contract: one stopped read-only preparation is owned by the worker until its next preparation, metadata cleanup, or ordinary close. Keep hard physical-owner loss distinct. On an exceptional execution exit, check the captured canonical native file and join its retirement if that file was replaced or disappeared. Caller aliases cannot select a different target for this cleanup. Existing native-failure and accepted-work settlement remain. Extend the existing refusal cases to hold and read an independent admission. The caller-revocation case previously produced the same lost-native-owner signature as hourly 39085230454. The original hourly initialization failure has not been reproduced, so its exact triggering event remains unconfirmed.
* refactor(sessions): simplify maintenance ownership * fix(storage): settle failed maintenance preparation in its native scope
…175987) A revoked maintenance caller must not retire the shared native generation retained by another admitted reply. Remove the maintenance-specific forced retirement and its unused preparation option. This follows openclaw#175778's intended contract: one stopped read-only preparation is owned by the worker until its next preparation, metadata cleanup, or ordinary close. Keep hard physical-owner loss distinct. On an exceptional execution exit, check the captured canonical native file and join its retirement if that file was replaced or disappeared. Caller aliases cannot select a different target for this cleanup. Existing native-failure and accepted-work settlement remain. Extend the existing refusal cases to hold and read an independent admission. The caller-revocation case previously produced the same lost-native-owner signature as hourly 39085230454. The original hourly initialization failure has not been reproduced, so its exact triggering event remains unconfirmed.
…2026.10.7 (#181465) * fix(backup): keep a supported older exec approval policy in snapshots (#164297) Snapshot sanitization replaced any policy the strict persisted parser rejected with a fail-closed deny-all document, so a backup taken before `doctor --fix` migrated an older but supported policy lost its allowlist. Restoring the archive installed deny-all instead of the saved rules. Fall back to the legacy parser Doctor already uses, which converts the older shape (agents.default, missing ids, commandText) into the current representation, and keep fail-closed for genuinely malformed rows. (cherry picked from commit e68d50a) Co-authored-by: RomneyDa <[email protected]> * fix(linux): saved Gateway dashboards need pairing approval after every restart (#158908) * fix(linux): saved Gateway dashboards need pairing approval after every restart Saved Gateway dashboards were built as incognito WebKit views, so the Control UI lost its browser device identity and paired device token on every switch and restart, and the Gateway asked for approval again. Give each saved Gateway its own private WebKit data directory, keyed by the credential namespace and profile id, matching the per-profile website data store on native macOS. Storage for Gateways that are no longer saved is deleted at the next launch, because WebKitGTK keeps a data directory in use until the app exits. Closes #156945 * fix(linux): removed Gateway saved again must pair a fresh dashboard Dashboard storage was keyed by the endpoint-derived profile id, so removing a Gateway and saving the same address again in one session reopened the removed profile's storage and its paired device token. Each saved profile now records a random storage id when it is first saved. Renames and credential edits keep it; removal drops it, so the same endpoint saved again gets new storage and must pair again. Profiles saved before this change fall back to a stable key. Storage helpers are compiled only where they are used, and the symlink test is Unix-only so Windows test builds compile. (cherry picked from commit c65a353) Co-authored-by: RomneyDa <[email protected]> * fix(sessions): preserve readers across maintenance refusal (#175987) A revoked maintenance caller must not retire the shared native generation retained by another admitted reply. Remove the maintenance-specific forced retirement and its unused preparation option. This follows #175778's intended contract: one stopped read-only preparation is owned by the worker until its next preparation, metadata cleanup, or ordinary close. Keep hard physical-owner loss distinct. On an exceptional execution exit, check the captured canonical native file and join its retirement if that file was replaced or disappeared. Caller aliases cannot select a different target for this cleanup. Existing native-failure and accepted-work settlement remain. Extend the existing refusal cases to hold and read an independent admission. The caller-revocation case previously produced the same lost-native-owner signature as hourly 39085230454. The original hourly initialization failure has not been reproduced, so its exact triggering event remains unconfirmed. (cherry picked from commit 30b7adf) Co-authored-by: RomneyDa <[email protected]> (cherry picked from commit 380c53c) * fix: preserve borrowers after PostgreSQL agent opening refusal (#179320) Fixes PostgreSQL agent-opening refusals retiring peer borrowers after an opening lease has already committed. The caller receives its original refusal, its lease is removed after native exit, and peers can retry. A refusal before native open preserves SQLite's clean-restart seal. Unknown outcomes and genuine native or cleanup failures retain their existing invalidation and retirement behavior. This is the explicitly separated opening-refusal follow-up to merged #179230. Producer parity alone cannot fix this outcome: the refused worker tries to release its lease in a new shared-state transaction under its already-refused operation. PostgreSQL correctly rejects that transaction, replacing refusal provenance and making settlement unknown. Prepared workers now defer pre-open refusal cleanup to the existing host-owned `cleanupRetiredAgentDatabaseLease` / `agentDatabases.releaseExitedLease` path after native exit. That existing command carries the host's typed `refused-before-open` or `unknown` outcome. The lease owner still validates and deletes the exact lease; it preserves verification only for the explicit pre-open refusal. Missing facts never establish refusal. This field is an internal message between processes of the same build. No public SDK/plugin contract, persisted format, schema, configuration, version, or successful-open ownership changes. Synchronous opens retain their cleanup. The PG current-operation refusal guard and native `!captured.committed` classification remain unchanged. No dedicated cleanup command was added. Lazy `database.prepareWrite` now retains the refusal wrapper until the existing worker reply owner serializes the original error and typed outcome. The existing refusal reply branch handles factory and lazy opens, records the outcome for the matching actor after admission cleanup, and clears it before later dispatch can touch native state. Host cleanup reads the outcome only after native retirement. This resolves the accepted review finding without reusing an earlier request’s custody. Author simplification retains one cleanup owner and one command. The full PR has +62/-44 production lines, +117/-3 test/registry lines, and seven documentation lines. The repair strengthens the two existing real refused-open seal regressions with original-error and no-operation assertions; the broker fixture only adopts the existing actor outcome state. | Contract | RED | GREEN / candidate status | | --- | --- | --- | | PG refusal after committed opening lease preserves peer | Main-source baseline 39562254889/job119096566538; producer parity alone still RED in 39568439138/job119116916734 | Final head3643 passes both real engine cases in [39599121710/job119219532025](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219532025): SQLite2,275ms, PG2,832ms | | SQLite clean-restart seal survives refused open, both preparation modes | Previous head48ad,39576377942/job119143384085: both cases fail at line74 with missing `.seal` | [Final CI/job119219533530](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219533530): both cases PASS (prepared false560ms / true470ms) | | Exact lease removal, original refusal, no user operation, successful peer write | Real production worker/store sequence, independently confirms committed lease; no fabricated receipt | PASS in the final PG conformance regression | | Synchronous owner and genuine cleanup-failure retirement | Existing authority/integrity/lease-owner contracts | Existing local63PASS/1opt-in SKIP, new local22PASS; all affected owner/transport suites passed final CI | All three PostgreSQL conformance shards actually executed and passed on final head `3643c3c5bb50878de0fb97858b2b11420cecface` in [CI39599121710](https://github.com/openclaw/openclaw/actions/runs/39599121710): [1/3](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219532025), [2/3](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219532043), [3/3](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219531982). Logs confirm all14 producer/bootstrap/preferences/peer cases ran, plus both SQLite seal regressions. All required checks, type/lint/source contracts, and affected SQLite suites passed. No CI exception or rule bypass is needed. Formatting and final targeted type-aware lint passed. Both complete-diff Codex P0–P2 reviews completed clean, including the final shared refusal branch consolidation. Local registration/synchronous-authority suites passed22 cases; the next infra carrier blocked on host I/O before cases and was cancelled, exit143, with children joined and slot released. Final CI supplies the remaining runtime proof. The prior48ad run exposed the real seal regression; it was fixed rather than weakened or relabeled. The draft synchronize run skipped CI and is excluded from proof. No latency or throughput claim is made. The production peer regression takes about5.1s for both engines in final CI; the two existing SQLite seal cases take about1.0s together. No public SDK/plugin, persisted-format, schema, configuration, or successful-open ownership change is introduced. (cherry picked from commit 8cd9bf2) Co-authored-by: RomneyDa <[email protected]> * fix(macos): show actual Gateway version and keep recovery visible (#181389) * fix(macos): show actual bundled Gateway status and recovery * fix(macos): keep pending Gateway recovery actionable --------- Co-authored-by: Scott Hanselman <[email protected]> Co-authored-by: Dallin Romney <[email protected]> (cherry picked from commit bd36d90) Co-authored-by: RomneyDa <[email protected]> * fix(macos): ignore stale receipts during gateway repair (#167459) Backport the live-dispatch receipt behavior needed by the release line so historical checkpoints cannot veto a valid bundled Gateway repair, and only the receipt actually dispatched is completed. Co-authored-by: RomneyDa <[email protected]> * test(release): use stable worker dispatch fixture The stable line records worker-open dispatch as a boolean state, before the request-custody abstraction introduced on main. Exercise the same reply settlement contract with the branch-native dispatched state. Co-authored-by: RomneyDa <[email protected]> * refactor(release): isolate opening refusal classification Keep the stable branch database modules below their existing line-cap limits while preserving the backported host-owned lease cleanup semantics. Co-authored-by: RomneyDa <[email protected]> * fix(release): complete stable database guard adaptation Co-authored-by: RomneyDa <[email protected]> * fix(copilot): document stable transcript assertion invariants Co-authored-by: RomneyDa <[email protected]> --------- Co-authored-by: wangmiao0668000666 <[email protected]> Co-authored-by: RomneyDa <[email protected]> Co-authored-by: dOR <[email protected]> Co-authored-by: Peter Steinberger <[email protected]> Co-authored-by: Scott Hanselman <[email protected]> Co-authored-by: Scott Hanselman <[email protected]> Co-authored-by: roboclaw-bot <[email protected]>
…2026.10.10 (#181464) * fix(backup): keep a supported older exec approval policy in snapshots (#164297) Snapshot sanitization replaced any policy the strict persisted parser rejected with a fail-closed deny-all document, so a backup taken before `doctor --fix` migrated an older but supported policy lost its allowlist. Restoring the archive installed deny-all instead of the saved rules. Fall back to the legacy parser Doctor already uses, which converts the older shape (agents.default, missing ids, commandText) into the current representation, and keep fail-closed for genuinely malformed rows. (cherry picked from commit e68d50a) Co-authored-by: RomneyDa <[email protected]> * fix(linux): saved Gateway dashboards need pairing approval after every restart (#158908) * fix(linux): saved Gateway dashboards need pairing approval after every restart Saved Gateway dashboards were built as incognito WebKit views, so the Control UI lost its browser device identity and paired device token on every switch and restart, and the Gateway asked for approval again. Give each saved Gateway its own private WebKit data directory, keyed by the credential namespace and profile id, matching the per-profile website data store on native macOS. Storage for Gateways that are no longer saved is deleted at the next launch, because WebKitGTK keeps a data directory in use until the app exits. Closes #156945 * fix(linux): removed Gateway saved again must pair a fresh dashboard Dashboard storage was keyed by the endpoint-derived profile id, so removing a Gateway and saving the same address again in one session reopened the removed profile's storage and its paired device token. Each saved profile now records a random storage id when it is first saved. Renames and credential edits keep it; removal drops it, so the same endpoint saved again gets new storage and must pair again. Profiles saved before this change fall back to a stable key. Storage helpers are compiled only where they are used, and the symlink test is Unix-only so Windows test builds compile. (cherry picked from commit c65a353) Co-authored-by: RomneyDa <[email protected]> * fix(sessions): preserve readers across maintenance refusal (#175987) A revoked maintenance caller must not retire the shared native generation retained by another admitted reply. Remove the maintenance-specific forced retirement and its unused preparation option. This follows #175778's intended contract: one stopped read-only preparation is owned by the worker until its next preparation, metadata cleanup, or ordinary close. Keep hard physical-owner loss distinct. On an exceptional execution exit, check the captured canonical native file and join its retirement if that file was replaced or disappeared. Caller aliases cannot select a different target for this cleanup. Existing native-failure and accepted-work settlement remain. Extend the existing refusal cases to hold and read an independent admission. The caller-revocation case previously produced the same lost-native-owner signature as hourly 39085230454. The original hourly initialization failure has not been reproduced, so its exact triggering event remains unconfirmed. (cherry picked from commit 30b7adf) Co-authored-by: RomneyDa <[email protected]> * fix: preserve borrowers after PostgreSQL agent opening refusal (#179320) Fixes PostgreSQL agent-opening refusals retiring peer borrowers after an opening lease has already committed. The caller receives its original refusal, its lease is removed after native exit, and peers can retry. A refusal before native open preserves SQLite's clean-restart seal. Unknown outcomes and genuine native or cleanup failures retain their existing invalidation and retirement behavior. This is the explicitly separated opening-refusal follow-up to merged #179230. Producer parity alone cannot fix this outcome: the refused worker tries to release its lease in a new shared-state transaction under its already-refused operation. PostgreSQL correctly rejects that transaction, replacing refusal provenance and making settlement unknown. Prepared workers now defer pre-open refusal cleanup to the existing host-owned `cleanupRetiredAgentDatabaseLease` / `agentDatabases.releaseExitedLease` path after native exit. That existing command carries the host's typed `refused-before-open` or `unknown` outcome. The lease owner still validates and deletes the exact lease; it preserves verification only for the explicit pre-open refusal. Missing facts never establish refusal. This field is an internal message between processes of the same build. No public SDK/plugin contract, persisted format, schema, configuration, version, or successful-open ownership changes. Synchronous opens retain their cleanup. The PG current-operation refusal guard and native `!captured.committed` classification remain unchanged. No dedicated cleanup command was added. Lazy `database.prepareWrite` now retains the refusal wrapper until the existing worker reply owner serializes the original error and typed outcome. The existing refusal reply branch handles factory and lazy opens, records the outcome for the matching actor after admission cleanup, and clears it before later dispatch can touch native state. Host cleanup reads the outcome only after native retirement. This resolves the accepted review finding without reusing an earlier request’s custody. Author simplification retains one cleanup owner and one command. The full PR has +62/-44 production lines, +117/-3 test/registry lines, and seven documentation lines. The repair strengthens the two existing real refused-open seal regressions with original-error and no-operation assertions; the broker fixture only adopts the existing actor outcome state. | Contract | RED | GREEN / candidate status | | --- | --- | --- | | PG refusal after committed opening lease preserves peer | Main-source baseline 39562254889/job119096566538; producer parity alone still RED in 39568439138/job119116916734 | Final head3643 passes both real engine cases in [39599121710/job119219532025](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219532025): SQLite2,275ms, PG2,832ms | | SQLite clean-restart seal survives refused open, both preparation modes | Previous head48ad,39576377942/job119143384085: both cases fail at line74 with missing `.seal` | [Final CI/job119219533530](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219533530): both cases PASS (prepared false560ms / true470ms) | | Exact lease removal, original refusal, no user operation, successful peer write | Real production worker/store sequence, independently confirms committed lease; no fabricated receipt | PASS in the final PG conformance regression | | Synchronous owner and genuine cleanup-failure retirement | Existing authority/integrity/lease-owner contracts | Existing local63PASS/1opt-in SKIP, new local22PASS; all affected owner/transport suites passed final CI | All three PostgreSQL conformance shards actually executed and passed on final head `3643c3c5bb50878de0fb97858b2b11420cecface` in [CI39599121710](https://github.com/openclaw/openclaw/actions/runs/39599121710): [1/3](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219532025), [2/3](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219532043), [3/3](https://github.com/openclaw/openclaw/actions/runs/39599121710/job/119219531982). Logs confirm all14 producer/bootstrap/preferences/peer cases ran, plus both SQLite seal regressions. All required checks, type/lint/source contracts, and affected SQLite suites passed. No CI exception or rule bypass is needed. Formatting and final targeted type-aware lint passed. Both complete-diff Codex P0–P2 reviews completed clean, including the final shared refusal branch consolidation. Local registration/synchronous-authority suites passed22 cases; the next infra carrier blocked on host I/O before cases and was cancelled, exit143, with children joined and slot released. Final CI supplies the remaining runtime proof. The prior48ad run exposed the real seal regression; it was fixed rather than weakened or relabeled. The draft synchronize run skipped CI and is excluded from proof. No latency or throughput claim is made. The production peer regression takes about5.1s for both engines in final CI; the two existing SQLite seal cases take about1.0s together. No public SDK/plugin, persisted-format, schema, configuration, or successful-open ownership change is introduced. (cherry picked from commit 8cd9bf2) Co-authored-by: RomneyDa <[email protected]> * fix(macos): show actual Gateway version and keep recovery visible (#181389) * fix(macos): show actual bundled Gateway status and recovery * fix(macos): keep pending Gateway recovery actionable --------- Co-authored-by: Scott Hanselman <[email protected]> Co-authored-by: Dallin Romney <[email protected]> (cherry picked from commit bd36d90) Co-authored-by: RomneyDa <[email protected]> * test(release): align opening refusal coverage with beta harness The beta line predates the mixed-agent host installer used by the upstream PostgreSQL conformance fixture. Keep the production settlement repair and its broker coverage without importing a test harness that cannot boot on this branch. Co-authored-by: RomneyDa <[email protected]> * fix(release): restore beta guard compile and changelog record Co-authored-by: RomneyDa <[email protected]> --------- Co-authored-by: wangmiao0668000666 <[email protected]> Co-authored-by: RomneyDa <[email protected]> Co-authored-by: dOR <[email protected]> Co-authored-by: Peter Steinberger <[email protected]> Co-authored-by: Scott Hanselman <[email protected]> Co-authored-by: Scott Hanselman <[email protected]> Co-authored-by: roboclaw-bot <[email protected]>
What Problem This Solves
Maintenance/deletion repeats work already owned by the same native operation: UUID-addressed preparation slots plus a release RPC, repeated lease reads, receipt identity echoes, and caller-side checks of typed worker result tags. These layers obscure the actual safety boundaries: current rows and protection, operation-bound commit settlement, archive-before-delete, and native cleanup.
User Impact
No intended feature, storage-format or migration change. Normal maintenance/deletion keeps current protection, archive-before-delete, live ownership and accepted-write settlement. An unusually overlapping discretionary maintenance pass may fail/retry, and a canceled/lost-reply pass can leave one bounded preparation until the next prepare, metadata cleanup or native close. No operator action is required on healthy paths.
Why This Change Was Made
Keep one bounded worker-owned maintenance preparation, consumed by metadata cleanup or replaced by the next preparation/ordinary close. Reuse the validated lease row for its receipt and perform lease drainage/checks in one synchronous transaction. Correlate private planning, reclamation, and scoped archive requests with their actual result types; retain decoding at unknown transport/committed-facts boundaries. Remove the archive recorder's second schema ensure and the second clone of an already-detached commit-time deleted entry.
Published original head614a03abe11a89db8e6aa371b7e37f06a8ee11bf removed122 net production lines. The signed ten-file CI repair and complete own-orphan cleanup at52d5637c0113a14cf6dffbafb04a8bf672282e1f has an actual delta against pinned main df0358c of 134 net production lines removed across25 production files (+137/-271); all29 files +180/-459. Fresh complete-caller review is scoped-clean P0-P2 with no accepted/actionable findings; a subsequent mechanical extraction names the identical execution-release callback without changing order or semantics. Focused proof is complete with the unresolved local failures disclosed below; new-head hosted CI completed successfully. Main's PostgreSQL lease-read fix (#175069) and consolidated reclamation tests are preserved. Schemas, persisted formats, retention, permissions, public config/protocol/SDK contracts, and standalone session-memory machinery are unchanged. This smaller maintenance/deletion area split follows campaign rule11; overlapping donors are counted once.
Best-effort tradeoffs accepted
The provenance below distinguishes original additions from later extractions. Inspected descriptions provide synthetic/internal boundary evidence, not a cited human wrong-operation/echo/slot-identity incident.
7555e3f88132, #1582517ab507770f3, #1408978a5b4af66074, #111678: original new-file addition; cooperative-interleaving audit/test proof, not a cited human reread incident1f8e5985e10b, #16515126dffe7468cd, #1608587ab507770f3, #14089731172cf54466, #1492234c7c64734452, #157247789513231d7d, #126035a1566b2dbfd, #1632691ed98e67c92c, #155988c9584688c461, #1486302ff5d6fbb21d, #172985fc4d5d744fad, #123495, not later extraction#1479460a8e3604ba24, #98236, not later worker moveHuman incidents remain KEEP: #138555 reported a truncated child answer after cleanup; exact-run complete-answer/archive retrieval is preserved. #110152 reported Windows EPERM/fsync and long database delays; archive durability and off-thread responsiveness stay. Native cleanup recovery, failed-close custody/retry, and bounded contention handling also remain unchanged.
Keep the measured planning-outside-writer/refresh-at-admission path from #171154. This PR claims no new performance measurement. No dormant foundation or standalone session-memory backend, factory, registry, expiry, federation or tests are removed.
Evidence
Repaired exact-head hosted CI passed: run39073995568 completed SUCCESS on52d5637c0113a14cf6dffbafb04a8bf672282e1f, including openclaw/ci-gate. Complete head check census:148 completed,90success/54conditional skips/1neutral CodeQL/3canceled non-product automation checks, zero failures/pending/foreign-head checks. Canceled dispatch and PR-context jobs have newer same-head successes; auto-response has a same-head successful run and a canceled later automation invocation, not an omitted product suite. Neutral CodeQL is not claimed as a successful alert comparison. Both current-head hosted reviews report no actionable findings and no before-merge action; their noted absent shipped CLI/Gateway E2E remains disclosed and outside this campaign's local proof budget. No CI rerun was requested. The original failure attribution and local timing gaps below remain historical evidence, not green local-suite claims.
Original exact-head CI39060215095 failed. Two lint diagnostics in the unreachable artifact result-kind assertion and three maintenance preparation/native-join assertions are ours, not inherited. The published repair removes the impossible assertion, excludes explicit verification SELECTs from operation-only SQL observation, and gives the existing maintenance-plan preparation its existing native failure-retirement policy, with the preparation hook inside that boundary. Kept path-replacement/row-preservation/zero-host-SQL assertions are not relaxed. The first four-file repair passed targeted types and independent review but exposed a new local max-lines error; the smaller complete owner cut removes its six orphaned empty release callbacks and preserves actual ordered cleanup. Fresh complete ten-file/caller review is scoped-clean P0-P2 (confidence0.96); the subsequent mechanical callback extraction preserves its behavior and removes two code lines.
Current repair proof has passed18-root targeted types, ten-file lint/format, all nine selected maintenance cases (including the three original CI failures), and the unchanged real late-protection keeper. Affected consumers add ten passing cases: three Gateway corrections, two rewrite alias-retarget variants, legacy post-await authority, raw-event append, two single-reset cases and batched reset. All runtime wrappers completed final generation verification: 20 passing cases and four unresolved local timeouts, not an aggregate passing invocation. Gateway accepted-correction shutdown expired its unchanged120000ms timer at120142ms; cold restoration expired the same unchanged limit in turn/locked-owner/locked-SDK modes at121201/124538/136540ms. These remain unresolved local evidence, not proven product regressions or baseline attribution. Actual owners were inspected, without establishing a concrete cause. No timeout/retry/skip/assertion change or failed-case rerun was made. Runtime and static import cycles both pass with zero cycles; wrapper inventory1PASS (18filtered), source closure3PASS and mandatory lint suppressions14PASS completed their wrappers (120.28/81.65/103.56s). Whitespace passes. The remaining-proof script joined exit1, deliberately preserving its runtime failures after passing all final guards. New exact-head hosted CI completed successfully.
All seven PostgreSQL-infra failures on that original head match scheduled main39058564617@ec36f9b9617a8d668a660d97e262a861453d9246/job117471751210 individually: archive restore240000ms, following backup-create no-local-state error at414, Doctor v30/foreign=false120000ms, Matrix225450000ms, Matrix405 expected0 to be2, database port60000ms and update-preflight120000ms. The five failing test files and backup-create owner are byte-identical at PR base/head and baseline. PostgreSQL integrations passed; Git-backup passed and is not included in this attribution. This historical attribution does not waive our defects or new-head CI.
Targeted types and type-aware lint for all22 source/test roots passed, as did formatting and whitespace. The complete composed area received a fresh independent P0-P2 review with full owner/producer/keeper context and final source verification: scoped-clean, no accepted/actionable findings. This is not reuse of the older component reviews. Retired release-RPC references are absent across src/test/docs/scripts/packages/extensions/config. Changed-file classification was inspected through check-changed --dry-run; its printed broad commands were not executed locally.
The first unit lease file passed2 cases and the infra lease-owner file passed17. The original fourteen-file invocation was deliberately interrupted after73 minutes of proof/58 minutes of runtime execution, including39 minutes in runtime-config. Its wrapper joined exit143 and all tracked descendants exited. It is NOT a completed passing invocation or successful final generation-verification result. Remaining broad runtime coverage moves to exact-head hosted CI under the busy-host proof policy; it was not rerun locally for green.
Six unresolved local cases expired their unchanged timers:
The actual diagnostics are elapsed timers, not completed assertion failures. They remain unresolved/inconclusive local evidence, not passing suites or proven baseline failures. No timeout, retry, skip or assertion was changed. Other archive/read/reclamation cases passed, including complete multiline imported-event deletion/final lookup, both compressed archive reads, off-main publication, sequential deletion reuse, failed-publisher/result-recording committed archive recovery, FIFO-independent queued retirement and scoped publication before close. Partial case results are not presented as an aggregate green suite. The previously unrun three real lease-drain cases passed with successful final worker-generation verification; prior runtime/static cycles, wrapper inventory and source closure passed. The mandatory suppression guard exposed a separate existing main fixture defect, reproduced on fresh main and fixed independently by df0358 without changing the allowlist. Integration for that named gate preserved all18 production postimages and adapted only main's consolidated late-protection test. Fresh conflicted-root types/type-aware lint/format and the retained real late-protection case passed (1case,8filtered;799.48s shard,91%transform/5%tests), with final worker-generation verification complete (926.50s wrapper). Fresh runtime/static cycles both passed0. Fresh wrapper inventory passed1 case (18filtered;218.48s wrapper), source closure passed3 (121.12s wrapper), and mandatory lint suppressions passed14 (125.81s wrapper). The full rebase-proof script completed exit0, with no timeout/retry/skip/suppression/allowlist change. No broad local suite, whole-graph tsgo, standalone build or E2E is run under the campaign host budget. Exact-head hosted CI remains mandatory.