Repository navigation
fix: allow older source on newer Testbox checkouts - #138782
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: blocked before merge. Reviewed September 4, 2026, 10:44 PM ET / September 5, 2026, 02:44 UTC. ClawSweeper reviewWhat this changesThe PR lets older source run on newer prepared Testbox checkouts by removing verified obsolete source files while preserving ignored runtime data and rejecting unknown or modified extras. Merge readiness⛔ Blocked before merge - 1 item remains This remains a useful, focused repair missing from fetched main. No blocking correctness or security defect was found. Priority: P2 Review scores
Verification
How this fits togetherOpenClaw's remote-testing wrapper packages selected source into a frozen Git bundle. The receiver applies that bundle to a prepared Testbox workspace before running the requested command, without replacing its hydrated dependencies and caches. flowchart TD
A[Selected local source] --> B[Frozen source bundle]
B --> C[Source receiver]
D[Prepared Testbox checkout] --> C
C --> E[Verify source and cleanup eligibility]
E --> F[Preserve runtime and run command]
E --> G[Reject unexpected or modified source]
Before merge
Agent review detailsSecurityNone. PR surfaceTests +129, Other +24. Total +153 across 2 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Technical reviewBest possible solution: Keep one receiver-owned cleanup flow that distinguishes obsolete committed source from runtime data, using the shared byte verifier and Git's ignore policy rather than broad workspace cleaning. Do we have a high-confidence way to reproduce the issue? Yes, source inspection establishes the failure: a nonignored file present only in the newer prepared checkout reaches main's unconditional extra-file rejection before the payload. This review did not execute it; the supplied evidence reports the corresponding failing and repaired Testbox cases. Is this the best way to solve the issue? Yes. The receiver is the boundary with both the selected capsule and prior remote tree; moving this decision into the producer cannot account for remote-only files, while broad cleaning would endanger hydrated runtime. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 116c6c3be399. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Reviewed the completed ClawSweeper review and its remaining data-model checklist item. No persistent data-model change is present: the production diff only reads the prepared checkout's existing committed Git tree, verifies unchanged obsolete source entries, and retires those entries before executing the selected source capsule. It adds no database, schema, migration, configuration, retention, or runtime state format. The compatibility boundary is prepared source plus ignored runtime files. The existing real-Git cases cover newer prepared source with stale indexes, unknown/modified extras, file modes/kinds/symlinks, and ignore-rule transitions. The recorded Linux Testbox run exercised older selected source on newer hydration, preserved runtime files, completed all 307 owner tests and the full changed gate. Direct-provider rejection behavior remains covered. This addresses the review's compatibility-proof request; no data migration applies. No other actionable findings or rank-up moves were listed. |
|
Merged via squash.
|
* refs/remotes/origin/main: (602 commits) fix(plugins): trace trust refusals and repair legacy provenance (openclaw#138746) perf(sqlite): reuse compiled plugin state point reads (openclaw#138758) refactor: type chat prefetch dependencies and clean loading tests (openclaw#138793) ci: reduce Doctor test startup and core lint jobs (openclaw#138796) feat(update): retain run history and share outcome reports (openclaw#138690) chore(deps): update @openclaw/fs-safe to 0.8.1 (openclaw#138500) fix: preserve global board ownership from pinning to notifications (openclaw#138675) fix(gateway): deliver session catalog updates from slow hosts (openclaw#138674) perf(sessions): index pending conversation replies (openclaw#127182) perf(auth): reuse ordered provider alias entries (openclaw#138805) docs(diagnostics): clarify whole-process CPU metrics (openclaw#138804) perf(memory): narrow source reads and stream embedding cache rows (openclaw#138766) fix: allow older source on newer Testbox checkouts (openclaw#138782) fix(agents): preserve recovered task progress and lifecycle ownership (openclaw#138785) perf(codex): reduce rollout tail scan CPU (openclaw#138784) perf(gateway): stop projecting history deltas at the byte budget (openclaw#138655) fix(build): bound native declaration inputs to checkout (openclaw#138742) fix(cli): preserve foreground Gateway argument handling (openclaw#138765) fix(ui): align task toolbar with side-panel tabs (openclaw#138769) fix(logbook): drain accepted work before closing SQLite (openclaw#138754) ... # Conflicts: # src/agents/embedded-agent-runner/compact.queued.ts
Related: #138612.
What Problem This Solves
Fixes an issue where developers testing an older source revision on a newer hydrated Testbox would fail source verification before their command ran. Files added by the newer workflow checkout survived in the execution workspace although they were absent from the selected source.
Why This Change Was Made
The receiver uses the prepared checkout's committed tree solely to prove cleanup ownership. An obsolete, nonignored file is removed only when its bytes, kind and executable mode match that committed entry. The frozen capsule remains the sole authority for the source that executes.
Ancestor ignore rules are retired before their descendants, and Git recomputes eligibility after each removal. This preserves newly protected caches and rejects newly exposed unknown or modified files. Cleanup and final source validation share the existing raw-file verifier.
User Impact
Older revisions can run against newer Testbox hydration while unrelated untracked, ignored and modified extra data remains intact. Unexpected or modified nonignored source still stops the command. No configuration, dependency or protocol change.
Evidence
Configured Blacksmith Testbox run 33937838286, lease
tbx_01m1qmqrsh3dwrkhwb08cbt4aa, Node 24.19.0 / pnpm 12.1.0:578cb8b9to selected source6c63f671plus this repair. Both previously reported obsolete files were removed; hydrated runtime remained present.crabbox-wrapper.test.tsandtestbox-lease-freshness.test.ts.scripts/check-changed.mjs --base 06759eabcbdd33b24ad131627d354e95fbf6cd93gate passed for both changed files, including script/root-test types, lint and source guards. The normal frozen install and module resolution used a private candidatenode_modules.The wrapper and proof controller exited 0. The complete 17,204-byte archive and all nine log hashes were verified locally before stop/status confirmed lease completion. Artifact SHA-256:
3e121327c67450bff827df18d1db333c8ad98a21b41b36c841dc231b39e43821.Limits and retained failures: two local attempts hit existing deadlines on the loaded macOS host. The first Linux run passed staging/owner tests but failed test lint and relative artifact retrieval; both were corrected for the final run. Its immutable manifest retains an outdated descriptive patch checksum, explicitly qualified by the final asserted source-file hashes and selected Git tree. Linux proof is pinned to
06759eab; current-main qualification separately covers the incoming artifact-preservation sibling changes and dependency update, with hosted integration CI still required.Tooling: +32/-8 (net +24); tests: +130/-1. Growth represents the missing prior-source ownership boundary and reuses the existing verifier and Git ignore policy.