Repository navigation
feat(crabbox): allow profiles without a default machine class - #131009
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. |
|
Codex review: needs maintainer review before merge. Reviewed August 29, 2026, 2:35 AM ET / 06:35 UTC. ClawSweeper reviewWhat this changesThe PR makes a Crabbox cloud-worker profile’s default machine class optional, passes a per-placement class through to provisioning, and updates warm-image, cleanup, UI, and documentation behavior. Merge readinessKeep open for explicit maintainer review: the classless-profile implementation is coherent and current main still rejects it, but the exact-head checks are incomplete and the documented live provider run stops before enrollment and a session turn. Priority: P2 Review scores
Verification
How this fits togetherCloud-worker profiles are configured in the Control UI and passed to provider plugins for lease provisioning. The Crabbox plugin resolves the effective class, runs provider commands, and returns lifecycle state to Gateway-managed sessions. flowchart LR
A[Cloud worker profile] --> B[Control UI or config]
B --> C[Effective class resolution]
C --> D[Crabbox provider plugin]
D --> E[Cloud lease]
E --> F[Enrollment and session]
C --> G[Warm image policy]
Decision needed
Why: The implementation preserves the existing class-bearing path in source, but its real-provider evidence ends before the session boundary and the PR calls this a landing hold. Before merge
Agent review detailsSecurityNone. PR surfaceSource +16, Tests +367, Docs -22. Total +361 across 14 files. View PR surface stats
Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Land only after exact-head checks are green and a maintainer accepts complete classless lifecycle proof or the documented provider-network limitation. Do we have a high-confidence way to reproduce the issue? Yes at source level: current main rejects an omitted class before provider provisioning, and the exact PR head changes that path. The real classless provider scenario remains partial because it stopped before enrollment and a session turn. Is this the best way to solve the issue? Yes for the implementation shape: class omission is handled in the owning Crabbox plugin before provisioning and warm-image selection, while Advanced settings preserve a profile the rich editor cannot faithfully represent. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 8af1b4aceeab. LabelsLabel 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 (12 earlier review cycles; latest 8 shown)
|
Final pre-merge proof — 2026-08-29The scoped optional-class change is ready for native preparation; this is not a completed merge or full worker-turn acceptance report. Published head: Actual cloud dispatch, failure, and cleanupA fresh, real isolated Gateway used the normally installed, source-bound candidate package. A normal registry-owned session/worktree dispatched through a classless Crabbox profile and allocated the approved 2-CPU/4-GiB/8-GiB sandbox without a class flag. Real remote profile execution reached the candidate download, which failed with The first stop returned exit 5, and the known lease stayed pending rather than being falsely marked destroyed. Independent exact-resource HTTP 404 plus a complete exact-ID retained-inventory query confirmed provider API absence. A later ordinary stop returned 0; normal A separate, bounded three-minute Linux control reproduced the network limitation: HTTPS to Full node enrollment, a model turn, workspace roundtrip, cancellation, and Gateway restart remain unverified through this endpoint. The recording below is explicitly edited, 26-second evidence of allocation, visible failure/pending cleanup, and ordinary reclaim—not successful end-to-end worker execution or a pre-fix comparison. Its contact sheet and full-resolution keyframes were inspected for the asserted states and sensitive content. Across the campaign, four small CPU-only resources were used sequentially, all confirmed absent through provider APIs: 7.030 conservative worker-minutes, approximately $0.0195 estimated at the recorded published rates, not an invoice. Model turns: zero. The latest coordinator trace recorded two creates and no TTL updates; both new leases ended released without pending/error/retry cleanup markers. All task Gateways, coordinators, temporary routes and local services are stopped, ports closed, owned containers/network removed, and temporary credential/browser files removed. Evidence and the coordinator volumes are preserved. API absence is not a physical-erasure claim. The first failed rig remains offline with its original rejecting configuration unchanged. That earlier pre-allocation credential-destination failure exposed a pre-existing, independent null-lease cleanup defect: cleanup can re-enter allocating provision before the later enrollment fence. It was not “recovered” by correcting credentials, and no cleanup-only allocation was attempted. This optional-class PR does not introduce or claim to repair that owner boundary; unpublished cleanup/Move/SDK/store changes were not imported. Candidate and refresh proofThe live package was built from head That head passed 433 focused tests, full changed-surface checks, docs checks, full build, native review guards, restricted P0 autoreview, and CI run 33216542141 (183 successful jobs, 13 skipped). Startup JavaScript measured 347,442 gzip bytes below the unchanged 347,831-byte limit. These are prior-head results, not the pending refreshed head's CI. The refresh to That head's CI exposed two new-main Gateway send tests expecting omitted account input to remain omitted at local delivery, although main's canonical routing resolves Final Production: +103/-87 (net +16). Tests: +773/-406 (net +367). Docs: +36/-58 (net -22). Growth implements the approved optional-class capability and effective-class policy; the consumer cleanup repair itself is net-negative. The refresh adds no new production behavior. Released cleanup contract and review dispositionThe earlier terminal-cleanup P1 was checked against immutable Crabbox 0.46/0.47 source, the official 0.46 binary, and the actual candidate adapter. The latest ClawSweeper review, at 06:35 UTC on August 29 on exact head Disposition of the earlier P1 review items:
A distinct source-backed direct-AWS stop replay defect is tracked separately: active-only inventory lookup can prevent retry from reaching owner-held terminal cleanup evidence. It needs an owner-side repair, not generic not-found success. No all-backends teardown-liveness claim is made. Latest review and rank-up disposition: exact-head checks are now green. Existing class-bearing profiles preserve their setup-environment/explicit-warm-image behavior; the effective-class matrix and durable restart teardown tests cover the conditional default. Direct upstream source and released-CLI proof are supplied above. The maintainer integration decision is to proceed with this bounded optional-class feature under the landing instruction, using changed-boundary real proof and the documented provider-network limitation. The successful full lifecycle recording is not supplied because the approved endpoint repeatedly failed TLS before enrollment. This is not a claimed successful run, operator proof waiver, direct-backend certification, or completed broader acceptance. Recorded local validation commandsFeature refresh at node scripts/run-vitest.mjs extensions/crabbox/index.test.ts extensions/crabbox/src/crabbox-worker-provider.test.ts extensions/crabbox/src/crabbox-worker-warm-image.test.ts extensions/crabbox/src/crabbox-worker-inspect.test.ts extensions/crabbox/src/doctor.test.ts src/gateway/worker-environments/provider-reconciliation.test.ts src/gateway/worker-environments/provider-node-teardown.test.ts ui/src/pages/cloud-workers/cloud-worker-config.test.tsnode scripts/check-changed.mjs --base 56c2083fbdd5cac62d69cae92bb71cc68e512412node --import ./scripts/tsx.mjs scripts/build-all.mtsnode scripts/check-docs-mdx.mjs docs/gateway/cloud-workers.md docs/gateway/configuration-reference.mdFinal-head original-order replay used Earlier controls and real Settings UIEarlier managed controls proved omitted-class allocation, Managed success is not direct-Daytona support: the native fixed-ID capability gate remains authoritative. OpenClaw keeps generic capability diagnostics and provider-specific setup in Crabbox documentation. The real Settings UI test used two authorized isolated browsers against the installed candidate Gateway, without a mocked Gateway or application-state injection. One held a Before: unsaved class-based draft. After: stale save rejected; authoritative classless profile retained. Classless Edit opens Advanced. Settings interaction recording (candidate before/after interaction, not pre-fix comparison): classless-ui-532b68d.webmAllocation → transfer failure/pending cleanup → ordinary reclaim (edited excerpts; no model turn): classless-allocation-failure-reclaim-532b68d.mp4 |
Keep native fixed-ID backend rejection separate from obsolete-CLI flag errors. Classless unsupported profiles now report their actual backend incompatibility before enrollment, without an incorrect upgrade-only instruction. Extend the existing boundary regression, replace the misleading Daytona success fixture, and clarify native coordinator routing in the docs. Follow-up for #131009 (class-optional Crabbox profiles).
Apply the maintainer-approved documentation correction for PR #131009. Keep OpenClaw's fixed-ID, setup, inspection, cleanup, and AWS instance-role requirements while directing backend configuration and tutorials to Crabbox. Require complete session-flow verification before relying on a new profile; standalone readiness does not establish OpenClaw worker compatibility.
435f1ab to
a07dfb1
Compare
Keep native fixed-ID backend rejection separate from obsolete-CLI flag errors. Classless unsupported profiles now report their actual backend incompatibility before enrollment, without an incorrect upgrade-only instruction. Extend the existing boundary regression, replace the misleading Daytona success fixture, and clarify native coordinator routing in the docs. Follow-up for #131009 (class-optional Crabbox profiles).
Apply the maintainer-approved documentation correction for PR #131009. Keep OpenClaw's fixed-ID, setup, inspection, cleanup, and AWS instance-role requirements while directing backend configuration and tutorials to Crabbox. Require complete session-flow verification before relying on a new profile; standalone readiness does not establish OpenClaw worker compatibility.
Treat known non-runnable Crabbox states as loss of a usable lease, so core fences the worker and requests explicit teardown instead of assuming the machine is gone. Stop renewing those leases and share the classification with provisioning, including archived resources. Only normal zero-exit stop results prove provider-owned cleanup. Preserve failed release diagnostics even after an earlier missing-lease warning, and reconcile AWS profile rejections through stop when recognition is lost. Clarify the existing inspection contract without changing its SDK shape. Preserves the optional-class and warm-image policy in #131009.
32b3973 to
2b1feb3
Compare
Preserve class omission through provisioning, advertised machine choices, and Advanced editing while requiring an effective class for warm-image reuse. Keep explicit classes and placement overrides unchanged, reject stale rich editor saves, and document the remaining managed-session acceptance boundary. Fixes #130966.
Keep native fixed-ID backend rejection separate from obsolete-CLI flag errors. Classless unsupported profiles now report their actual backend incompatibility before enrollment, without an incorrect upgrade-only instruction. Extend the existing boundary regression, replace the misleading Daytona success fixture, and clarify native coordinator routing in the docs. Follow-up for #131009 (class-optional Crabbox profiles).
Apply the maintainer-approved documentation correction for PR #131009. Keep OpenClaw's fixed-ID, setup, inspection, cleanup, and AWS instance-role requirements while directing backend configuration and tutorials to Crabbox. Require complete session-flow verification before relying on a new profile; standalone readiness does not establish OpenClaw worker compatibility.
Preserve cold classless omission while retaining warm defaults for known configured or placement classes without forwarded setup environment names. Explicit warm-image flags retain priority and warm provisioning requires a known effective class before commands. Share the pure policy across provision and teardown, using the successfully enrolled class after reconstruction without resolving setup environment values. Keep cold teardown from creating warm state and document the conditional default without restoring backend-specific tutorials. Reuse the existing lifecycle-timeout stop helper for normal teardown.
Treat known non-runnable Crabbox states as loss of a usable lease, so core fences the worker and requests explicit teardown instead of assuming the machine is gone. Stop renewing those leases and share the classification with provisioning, including archived resources. Only normal zero-exit stop results prove provider-owned cleanup. Preserve failed release diagnostics even after an earlier missing-lease warning, and reconcile AWS profile rejections through stop when recognition is lost. Clarify the existing inspection contract without changing its SDK shape. Preserves the optional-class and warm-image policy in #131009.
2b1feb3 to
0844983
Compare
|
Merged via squash.
|
…aw#131009) * feat(crabbox): allow profiles without a default machine class Preserve class omission through provisioning, advertised machine choices, and Advanced editing while requiring an effective class for warm-image reuse. Keep explicit classes and placement overrides unchanged, reject stale rich editor saves, and document the remaining managed-session acceptance boundary. Fixes openclaw#130966. * fix(crabbox): preserve unsupported backend diagnostics Keep native fixed-ID backend rejection separate from obsolete-CLI flag errors. Classless unsupported profiles now report their actual backend incompatibility before enrollment, without an incorrect upgrade-only instruction. Extend the existing boundary regression, replace the misleading Daytona success fixture, and clarify native coordinator routing in the docs. Follow-up for openclaw#131009 (class-optional Crabbox profiles). * docs(crabbox): keep backend setup in Crabbox documentation Apply the maintainer-approved documentation correction for PR openclaw#131009. Keep OpenClaw's fixed-ID, setup, inspection, cleanup, and AWS instance-role requirements while directing backend configuration and tutorials to Crabbox. Require complete session-flow verification before relying on a new profile; standalone readiness does not establish OpenClaw worker compatibility. * fix(crabbox): resolve warm defaults after effective sizing Preserve cold classless omission while retaining warm defaults for known configured or placement classes without forwarded setup environment names. Explicit warm-image flags retain priority and warm provisioning requires a known effective class before commands. Share the pure policy across provision and teardown, using the successfully enrolled class after reconstruction without resolving setup environment values. Keep cold teardown from creating warm state and document the conditional default without restoring backend-specific tutorials. Reuse the existing lifecycle-timeout stop helper for normal teardown. * fix(crabbox): require confirmed worker lease cleanup Treat known non-runnable Crabbox states as loss of a usable lease, so core fences the worker and requests explicit teardown instead of assuming the machine is gone. Stop renewing those leases and share the classification with provisioning, including archived resources. Only normal zero-exit stop results prove provider-owned cleanup. Preserve failed release diagnostics even after an earlier missing-lease warning, and reconcile AWS profile rejections through stop when recognition is lost. Clarify the existing inspection contract without changing its SDK shape. Preserves the optional-class and warm-image policy in openclaw#131009.



Closes #130966 — allow omitted Crabbox profile classes.
Related but not completed here: guided cloud-session setup with protected credentials.
What Problem This Solves
Operators cannot delegate resource selection to a Crabbox backend, or choose a class only at placement time, because OpenClaw rejects a profile without a default class. An already-open class-based editor can also restore a class intentionally removed through Advanced settings.
During verification, the Crabbox consumer was also found to mistake non-runnable lease states and failure prose for completed cleanup. That could let OpenClaw forget infrastructure while the owning CLI still reported cleanup failure.
Why This Change Was Made
Make omission a generic plugin contract, not a provider-specific exception. Missing
settings.classomits--class; an explicit configured or placement class retains precedence and validation. Real mapped catalogs retain their advertised choices and 32-option bound without an invented default or reserved default slot.One effective-sizing policy determines warm-image behavior. Classless omission is cold; a known configured/placement class retains the warm default when no setup environment is supplied. Explicit
warmImage: falseremains cold, and explicit warm reuse requires a class before commands run. Teardown uses the recorded enrolled class without rereading setup secrets or opening an unused warm store for cold workers.Classless Edit uses the existing Advanced editor. A stale rich-editor draft checks the authoritative profile before producing a save patch. Unsupported backend errors retain the native diagnostic rather than an incorrect upgrade-only hint.
Cleanup remains owned by Crabbox: known non-runnable observations stop heartbeats and become
unknown, not proven destruction. Only a normal zero-exit stop establishes completion; a preceding 404 warning or misleading nonzero “already stopped” prose does not. No provider-name exception, new SDK result variant, or consumer-side deletion guess is added.User Impact
Profiles can omit their default machine class. Explicit null, empty/whitespace, and nonstring values remain invalid; configured classes and placement overrides continue working. Classless profiles are edited through Advanced, and stale saves cannot restore removed settings.
OpenClaw documents the generic Crabbox integration and its required worker lifecycle; backend sizing, snapshots, credentials, and setup stay in Crabbox documentation. This does not make unsupported direct backends satisfy fixed-ID, script-setup, replay, heartbeat, or cleanup contracts. In particular, managed evaluation is not direct-Daytona support.
No new configuration keys, environment variables, dependencies, Plugin SDK exports, database tables, or schema versions. One existing setting changes from required to optional. Production +103/-87 (net +16); tests +773/-406 (net +367); docs +36/-58 (net -22). Production growth implements optional sizing and its effective-class policy; the connected consumer cleanup repair is net-negative.
Release-note context: allow Crabbox profiles without a default class, preserve classless Advanced edits, resolve warm defaults from effective sizing, and retain failed cleanup until the owning CLI confirms success.
Evidence
The maintainer proof record, inspected screenshots/video, failures, and review-item dispositions are the detailed evidence record. It distinguishes released source/CLI fixtures, local development dependencies, real Gateway UI, hosted controls, and unperformed work.
Refreshed-source checks
Final published candidate
0844983f1b9dcca5a83aa660d5353faa3dfdfe00, based on9e10397dee01b46fe8c707fb4b4abb698effb04b, preserves all five feature patches, authors, dates and messages. All seven PR production files are byte-identical to the live-tested532b68dpackage.Exact-head CI 33238476822 passed on attempt 1: 185 successful jobs, 13 skipped, including
openclaw/ci-gate. The final source passed the original 1,772-test Gateway CI group in its original configuration/order and fresh restricted P0 autoreview over the complete committed branch. The earlier feature refresh passed 393 focused tests plus five declaration/closure tests, docs validation, full build and complete changed gate. An initial Knip timeout passed one serialized retry without changing its 600-second limit. Those earlier full checks are not relabeled as new full-repo runs on the final base.The first refreshed CI run exposed two stale send-account expectations introduced by the interaction of main's Twitch canonical-send work and effective-account normalization. Both failures were reproduced alone and in original order, and a test-only repair was validated. Main's equivalent CI repair landed concurrently; the final branch retains it and drops our duplicate test commit. No unrelated production change or timeout/baseline workaround remains.
The latest ClawSweeper review on exact head
0844983reports no actionable code findings. Exact-head checks are green; existing class-bearing warm defaults and restart teardown are covered, and direct released-CLI contract evidence is supplied. The maintainer integration decision is to proceed with the bounded optional-class feature under the landing instruction, using changed-boundary real proof and the documented provider-network limitation. The full-lifecycle rank-up recording remains explicitly incomplete because the approved endpoint reset TLS before enrollment. This does not certify the broader successful hosted flow or claim an operator proof waiver.Separate owner work
The pre-existing null-lease cleanup defect is owned by failed-dispatch allocation-free cleanup, not an unpublished SDK/store slice imported here. Direct-AWS repeated-stop lookup can also miss retained terminal cleanup evidence and needs its own owner repair. Neither limitation is hidden by accepting generic not-found prose, and this PR does not claim universal backend teardown liveness.
AI-assisted maintainer work.