Repository navigation
feat(claws): expose lifecycle backend for Control UI - #162987
giodl73-repo wants to merge 4 commits into
Conversation
Extract the Gateway and canonical lifecycle changes from the Control UI draft. Keep browser presentation separate. This draft retains known cron compensation and config worker integration blockers; it is not ready to merge.
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review in progressClawSweeper is reviewing this revision. This supersedes any previous blocked status. |
|
Codex review: needs real behavior proof before merge. Reviewed October 1, 2026, 11:08 PM ET / October 2, 2026, 03:08 UTC (Revision 5). ClawSweeper reviewWhat this changesAdds experimental Gateway methods for reviewing, installing, updating, and removing Claws, OpenClaw’s packaged agent setups, through existing lifecycle owners. Merge readiness⛔ Blocked before merge - 6 items remain This remains a distinct, useful backend contribution absent from current main and the latest release. The follow-up strengthens persistence evidence without changing production code; no new actionable correctness finding was established. Priority: P2 Review scores
Verification
How this fits togetherThe Gateway receives lifecycle requests from operator clients and resolves versioned ClawHub artifacts into canonical plans. Application workers apply approved changes through configuration, workspace, provenance, and scheduler owners. flowchart TD
A[Operator client] --> B[Experimental Gateway methods]
C[ClawHub release] --> D[Canonical lifecycle plan]
B --> D
D --> E[Exact plan and live authority checks]
E --> F[Application worker]
F --> G[Config workspace and scheduler owners]
G --> H[Inventory and completion result]
Before merge
Agent review detailsSecurityNone. PR surfacePR surface statistics unavailable: the file list is incomplete. Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Keep one canonical lifecycle behind the experimental Gateway adapter, with durable outcomes and narrowly owned recovery that remain correct after caller revocation. Do we have a high-confidence way to reproduce the issue? Not applicable as a feature request. Source confirms the missing Gateway lifecycle surface; reported worker runs cover install/update, while actual Gateway authorization and uninstall remain unproven. Is this the best way to solve the issue? Yes, extending the existing lifecycle owners through a worker adapter is the appropriate direction; the integrated authority and cleanup behavior still needs production-boundary verification. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 0b025d14d064. LabelsLabel changes: No label changes. Label justifications:
EvidenceWhat I checked:
Likely related people:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (4 earlier review cycles)
|
|
Closing as superseded by Patrick's Agents/Labs stack: #163298, with the final stack in #163307. We selected that single journey and the scoped comparison found no concrete missing fixes to carry over from this draft. The code and discussion remain as reference; this is not a merge or launch-readiness claim. Convergence decision: #163298 (comment) |
Convergence Decision
We are converging on Patrick's Agents/Labs stack (#163298, final stack #163307), not continuing the separate Plugins > Claws journey. Decision recorded for Patrick and Vyctor.
This PR is retained as a closed reference, superseded by the selected Agents/Labs stack. Do not land it independently or bulk-merge its implementation into Patrick's stack. Carry over only verified missing fixes into the existing owners; no source push, closure, merge, default enablement, deployment, or publishing is part of this decision.
The comparison is pinned to final stack
6765a8741e490a5df5bc143aa4795a40140a11cd. Adopted-agent ownership and legacy read-only inventory already have matching regression coverage there. Its installed-agent panel loads status independently and checks Gateway, request, and agent identity; our separate diagnostics-loading fix is not a direct port. This is source comparison, not new runtime proof or blanket stack approval.The bounded comparison of our reviewed fixes found no concrete port required at that tip. Host config persistence, host-local cron rollback, brokered lease admission, explicit MCP recovery, and effective-home workspace resolution cover or replace the old branch-specific repairs. No old worker bridge or compensation transport is being copied into the selected stack. Existing stack release gates and runtime-proof limitations remain; this is not a full-stack approval.
Preserved Local Evidence
Local commit
f89da51329f39c3e45020e85d529fbe81bbea634, not pushed: the conflict repair against pinned maind6411f28a12cb1b436c830a3a341f90164d4f3bdpreserves main's provenance worker and the inventory reader. The final 36-file code follow-up passed P0/P1 AutoReview with no actionable findings. The latest focused run passed 127 tests in 442.21s, including real-worker add 1.0.0, update 1.1.0, and removal with durable cleanup. Core production types, scoped test types, formatting, and the import-cycle check passed. Final scoped lint is clean; the main-relative file-size guard passed 148 changed source files, and the assertion-safety guard passed after removing one obsolete allowance (37 authored follow-up paths including that shrink-only baseline edit). The earlier extraction run passed 226 tests with two existing platform/root skips. These results are local candidate evidence, not the published head or combined Gateway authority-chain proof.Published Branch Context
The following describes this reference branch, not the selected Agents/Labs implementation.
Related: #142974
Related: #162314
What Problem This Solves
The terminal-free Claw install, update, and uninstall journey needs Gateway access to the existing canonical lifecycle operations.
User Impact
Provides the backend for Plugins > Claws: inventory, release previews, exact-plan administrator confirmation, install, update, and removal. There are no UI changes in this PR.
Draft: real Gateway and browser lifecycle validation remains incomplete. This is not a merge-readiness claim.
OPENCLAW_EXPERIMENTAL_CLAWS=1remains required. Plugin-bearing Claws remain blocked pending canonical plugin consent (#147280). No defaults, releases, publishing, dependency overrides, or database schemas are changed.Why This Change Was Made
Separates backend repairs from #162314 and calls canonical Claws operations rather than introducing another lifecycle owner.
OPENCLAW_HOME/home precedence through the existing resolver. Explicit workspace selections are unchanged.a6ee7e12d29c4cd77a132ca40b87374d86c9bbfbwas integrated for the previously observed protocol-input failure.Existing monitor/package cleanup still contains synchronous database work. This PR does not claim a broader storage migration.
Evidence
07d77ddaed7a87352056c0a5ea98a3b9ea4263fb. The test-only follow-up leaves production source identical to the previously built and reviewed3498b7673a299c68e4459d9ca27b87e3cf5e7dae.3498b7673a299c68e4459d9ca27b87e3cf5e7dae: scoped-clean at P0/P1, exit 0, no findings, final source verification passed.e5c72eb5e9fa70b282193782edff12842c91aa05: scoped-clean at P0/P1, exit 0, final source verification passed. The unresolved worker warning was included as a limitation.pnpm buildpasses with the locked Linux installation, exit 0 in 22m 13.5s: native protocol preparation, plugin assets, runtime and all declaration batches, 96 external plugins, CLI bootstrap guard, runtime postbuild, SDK exports, UI bundle/performance checks, and startup metadata. The prior cron-contract type failure is fixed. Startup CSS remains above its advisory target but below the existing hard ceiling; no baseline or guard was changed. This builds the backend branch, not the pending UI restack.e5c72eb5e9fa70b282193782edff12842c91aa05source review and diagnostic proof remain historical evidence, not current native E2E proof. The follow-up review found three missing test admission callers; those fixtures now use real grants and their Linux suites pass.Remaining Gaps
d6411f28a12cb1b436c830a3a341f90164d4f3bd, backend merge analysis identifiessrc/claws/lifecycle-status.tsandsrc/claws/mcp.ts, overlapping Peter's merged refactor(claws): move Gateway provenance writes to workers #163112 (Gateway provenance writes moved to workers). Integration must preserve those worker operations and this branch's inventory reads; the new MCP record owner also requires updating the inventory reader import. No conflict resolution or UI restack is claimed yet.The original UI checkout's 62 dirty backend files and the original backend checkout are preserved. No merge, ready-for-review transition, default enablement, or release is requested.