Repository navigation
fix(ci): parallelize auto-reply files within worker budget - #154306
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: needs maintainer review before merge. Reviewed September 21, 2026, 9:27 AM ET / 13:27 UTC (Revision 4). ClawSweeper reviewWhat this changesThe PR enables parallel auto-reply test files within existing CI worker budgets, updates scheduling estimates and guards, and replaces polling in an abort test with explicit synchronization. Merge readiness✅ Ready for maintainer review The optimization remains useful: current main and the latest release still serialize this cohort. The introduced changes preserve worker limits and timing provenance, and no actionable correctness or security finding remains. Priority: P2 Review scores
Verification
How this fits togetherOpenClaw’s CI planner groups test files using historical timings and worker limits. The shard runner executes those groups and records results that inform subsequent scheduling. flowchart LR
A[Test file inventory] --> C[CI scheduling planner]
B[Historical timings] --> C
C --> D[Worker and job budgets]
D --> E[Parallel test execution]
E --> F[Test results and timings]
F --> B
Before mergeNone. Agent review detailsSecurityNone. PR surfaceTests +163, Docs +2, Other +71. Total +236 across 6 files. View PR surface stats
Review metrics
Technical reviewBest possible solution: Retain the existing scheduling owner, bounded file parallelism, and separate timing identities so later measurements can replace estimates without double-discounting costs. Do we have a high-confidence way to reproduce the issue? Not applicable as a product bug reproduction: source confirms the serial override, and the supplied controlled shard runs quantify its scheduling cost. Is this the best way to solve the issue? Yes. The patch extends the existing planner and shared test configuration while preserving coverage, budget enforcement, and historical timing distinctions. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 904b41e9e99f. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (3 earlier review cycles) |
05c3948 to
d682ff6
Compare
…154306) * test(auto-reply): synchronize ACP abort with runtime startup * fix(ci): parallelize auto-reply files within worker budget
What Problem This Solves
Auto-reply reply tests serialize 249 files even when their CI groups have multiple workers available, adding avoidable time to Node validation.
User Impact
No product behavior or configuration changes. CI can run independent reply test files concurrently within the existing worker and matrix budgets.
Why This Change Was Made
Remove the historical config-wide serial override and use two workers per compact group. Parallel groups get separate timing identities so serial observations are normalized only as fallback estimates, while measured parallel walls, matching complete legacy generations, and singleton costs retain their meaning.
Eight-worker qualification also exposed a test that polled for ACP runtime startup with a fixed deadline before it ever sent the abort signal. Its fixture now signals startup and proves that dispatch settles while runtime cleanup is still held open, preserving abort propagation, owner lifetime, and delivery-suppression assertions.
No new serial exceptions were needed. Existing database-worker exclusions remain intact. The audit identified 123 files using mocked runtime graphs, 102 with session/goal references (59 with real store calls), and 30 using fake timers; these categories overlap. No direct or helper-mediated listen/chdir use was found in the resolved inventory.
Evidence
Rebased onto main
1ccccb02788a6bbc8eb9448faa96f4842720ebe6; the rebased head isd682ff60156a2f1883432f5d589d2c79da881436. Conflict resolution preserves the landed agents-core worker sizing and exact-sample precedence, infra/Codex policies, B1 appended-row reservation, and Gateway mixed native-serial/parallel pricing alongside auto-reply’s two-worker policy. Both CI documentation additions and both sets of planner regressions are retained; the ACP fixture is unchanged.Rebase validation passed on Linux (Blacksmith Testbox run): the full changed-file gate, both planner files, workflow/project/config guards, the repaired release-check file, and 10/10 standalone ACP fixture runs at worker cap eight. Case and no-output retries were disabled. The matrix replay, formatting, diff check, type-aware lint canary, and fresh P2 Codex review passed. The rebase Testbox command exited zero; all ten ACP reports were validated and hashed before the lease was stopped. A portal-sync deadline was reported after command success. Per the requested rebase scope, the full-cohort results below are retained as prior-head evidence rather than presented as new-head repetitions.
Prior full-cohort qualification is bound to head
05c3948cd7bc97995015dbc497111e66e672a32b, integrating main894fb140a22246bc1574d5b29fe61e10f77036de. Linux proof uses the repository Crabbox wrapper with Blacksmith Testbox, Node 24.19.0, four available CPUs, and 15.42 GiB RAM. Runtime qualification was refreshed after the integration because main changed shared SQLite teardown. Earlier qualification remains historical.The serial control passed in 828.15 s. Three complete two-worker rounds passed in 521.43 / 521.14 / 477.70 s (521.14 s median, 37.1% lower). Three complete eight-worker rounds passed in 528.87 / 537.85 / 503.03 s (528.87 s median). Every round covers exactly 249 files with 6,044 passed tests and 1 unchanged skip. These are summed group walls through
node --import tsx scripts/ci-run-node-test-shard.mts, with Vitest case retries disabled (--retry=0); no watchdog retry occurred. These are separate from end-to-end CI latency. The serial control and two-worker rounds use the same lease and repaired fixture; the control forces serial files with the previous group plan.The repaired ACP file passed 20/20 standalone runs at eight workers. Both changed tooling test files passed 10/10 standalone runs at eight workers. The changed-plan, workflow, and test-project guards passed. The full changed-file gate, type-aware lint with its failing canary, formatting, docs sanity, and diff checks passed. One-worker samples through the repository test wrapper were 66.18 s for the planner, 16.48 s for scoped configuration, and 15.28 s for ACP abort. The five new bounded planner cases used 23 ms of test-case execution in that sample.
Both prior-qualification Testbox command exits were zero. Downloaded reports were validated and hashed before both leases were stopped: 96 JSON files, including two receipt manifests. Lease records: control/two-worker and eight-worker. Both wrappers reported a portal-sync deadline after their successful commands; the downloaded result sets independently verify completion. Earlier qualification exposed the ACP startup poll failure; proof transport size and expired-lease interruptions were diagnosed before fresh qualification. No timeout increase, rerun-to-green, or serial exception was used.
For that prior head, local and committed-branch P2 Codex reviews were both scoped-clean with no actionable findings. The prior integrated planner passed all 119 tests, preserving both auto-reply and Gateway timing contracts.
Measured group walls
The overall median is computed from each complete round’s summed group walls.
Current replay of the #153435 changed set and broad fallback, using B1’s appended-plugin reservation, produces identical rows for both changed sets:
All profiles fit the 90 compact / 130 PR / 70 push caps.
Previous CI failure
The previous CI run 35557278746 failed on the sparse release-check fixture after all three changed test files passed. That history remains evidence for the previous head, not a result for this rebase.
This rebase includes #154567, which inspects the prepared tarball and guards against invoking
npm packfor its inventory. The full release-check test file passed in the rebase validation. The new push receives normal GitHub CI; no CI rerun or manual merge was requested by this rebase work.