Skip to content

fix(ci): split slow hourly tests across hosted runners - #157302

Merged
steipete merged 1 commit into
mainfrom
ci-burden/sp2-hosted-tail
Sep 25, 2026
Merged

steipete merged 1 commit into
mainfrom
ci-burden/sp2-hosted-tail

Conversation

@steipete

@steipete steipete commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Hourly main validation still spent 49m10s in one hosted Gateway/storage row and 28m12s in an agent-chat row after #157186 restored the main tier. Both rows were forecast at only 210 seconds. This patch splits the measured heavy work across free hosted rows.

The hourly target is not yet met: the observed wall fell from 56m16s to 40m03s. All eight dedicated chat, Gateway-methods and updater rows passed below 15 minutes; other mixed rows, queue delay and native build time remain on the critical path.

User Impact

No product behavior changes. Every selected test, assertion, config, worker limit and build prerequisite remains covered. The current hosted main plan grows from 61 to 69 compact rows, within its existing 70-row budget. The planner changes no PR, full-release or paid-runner placement policy; the new guard joins the existing relevant-tooling inventory. No runner variables, deadlines, caps or timing samples were changed. Auto-merge is off.

Why This Change Was Made

The existing splitter bounds main-hosted agent-chat groups to 30 files and Gateway-methods groups to 96. Their larger children have dedicated rows so stale estimates cannot pack them together again. Small Gateway tails retain ordinary packing. Storage keeps its 64-file bound, with the measured updater file alone.

With the candidate test inventory held fixed, swapping the planner preserves the complete file multiset, configs, environment and build modes. Hosted PR (76 rows), hybrid main/PR (65/77), and Blacksmith main/PR (57/71) plans are byte-identical under that comparison. The added guard is the only new test inventory. No test changes verification tiers. No inventory is deleted or skipped to achieve the timing result.

Evidence

Baseline: hourly-equivalent 35983526919, source a7aa63b79eab77581eb2b75cb3125bd3cb7af6be. Candidate: hourly-equivalent 36006363817, source bc81c1256fbb3b3f9ea7ed91be315c63d65b469c, rebased on b9da50953aa8 after #157186 merged. The sampled native Node logs confirm four CPUs, about 15.6 GiB RAM, one admitted child at a time, and the intended file selections.

Workload Before Candidate job seconds Retained proof
Agent-chat in the 1,692s reply/chat row 1,506.55s group 448 / 680 / 429 All 90 chat/session files, unchanged worker limits
Gateway methods in the 2,950s mixed row 1,491.78s for its 207-file child 864 / 547 / 603 / 573 for the four large children Complete methods inventory; runtime prerequisite and small tails retained
Updater in that mixed row's storage child 1,120.41s storage group; ~827s updater case time 398 for updater alone Same updater file; remaining storage files still execute
Build artifacts 1,050s 1,065 Unchanged
Main Docker survivor 1,417s 1,370 Unchanged
iOS smoke 1,660s 1,734 Unchanged
Whole hourly workflow 3,376s 2,403s All 68 dispatched compact Node rows passed; native failures below

The slowest dedicated methods row spent 798.67s in its group; the slowest chat group spent 630.40s; the updater group spent 336.59s. These are separate from setup/job wall time. Smaller methods tails and other storage work remain in mixed rows and are included in the remaining-tail table below.

Observed workflow reduction: 973 seconds (16m13s). Initial preflight wait changed from 5s to 64s; excluding only that wait gives 56m11s → 38m59s. Candidate baseline ratchets additionally queued for 325s, and some Node rows waited several minutes after matrix creation. These runs also contain inherited main changes, including updater-test simplification; the entire observed difference is not attributed solely to this patch.

Inventory removed from PR/main: zero tests / zero test-seconds. Eight additional hosted rows cost no paid-runner routing; parallel wall reduction is not a claim of reduced aggregate test work.

Changed file Fate Measured cost / effect Coverage retained
scripts/lib/ci-node-test-plan.mts FAST Dedicated rows 398–864s; hourly 3,376 → 2,403s observed Same files, configs, environment, build prerequisites and budgets
test/scripts/ci-node-test-plan-hosted-tail.test.ts FAST guard New guard: 27.16s Linux file-wall median at 2 workers; 21.96s in native PR CI Rejects the old 90-file envelope; validates complete inventories, worker bounds, dedicated placement and the row cap
docs/ci/scope-and-routing/node-test-lanes.md FAST documentation No runtime cost Documents the main-only placement contract

The guard passed 10/10 Linux candidate runs. Its first three walls were 27.98/27.16/25.37s. Three runs against the original planner all failed on the intended 90-file envelope (25.17s median, expected failures); no guard-runtime speedup is claimed. The complete core-tooling-14 owner shard passed 80 files / 4,076 tests in 690.49s. The four required sibling files passed another 2,405 tests in 395.20s (400.30s wrapper wall). The Blacksmith lease stopped cleanly. The proof checkout omitted only an unrelated tracked .artifacts PR-body report rejected by the unchanged privacy policy; executable candidate files were checksum-verified.

P2 autoreview is scoped-clean. Changed-file checks, type checks, type-aware lint with a failing floating-Promise canary, formatting, docs MDX/link sanity and diff checks passed. The rebased guard passed once at one worker in 10.87s. The rebase preserves the reviewed patch.

Remaining tail and CI failures

Remaining mixed workload Observed job wall Dominant group spans
Storage + agents/commands 1,451s Storage 688.51s plus nine other groups
Storage + small methods/commands 1,423s Storage 1,055.60s
Auth + config + Doctor 1,388s Config 797.50s; auth 470.79s
Unit-fast + storage + reply 1,238s Storage 795.46s; reply 196.46s; unit-fast 166.81s
Gateway core + agent/channel commands 1,192s Gateway core 848.41s; commands 281.97s

S2 currently has no supported interface for promoting only these hourly hosted envelopes. Its pending routing work rebuilds the hybrid plan, excludes ordinary hourly dispatch and changes outer worker capacity. The complete measured group signatures were handed to S2 for an admission/placement extension that preserves the hosted remainder, full-family scope, effective worker limits and row budget. No competing routing path was added here. The 28m54s iOS smoke plus workflow prefix also leaves little room for a 30-minute wall target.

Exact-head PR CI 36006570169 passed the new guard and 110 jobs, but failed four cases in full-release-artifact-contract.test.ts. Release sealing introduced by #156812 requires qualified npm/preflight evidence that those fixtures omit; a secretless single-case replay reproduced the token prerequisite failure in 3.89s. A bounded, discarded fixture-only investigation preserved every assertion and exposed a second inconsistency: production hard-codes stable performance as advisory while the retained stable assertion requires blocking. No assertion or publication policy was weakened to clear CI. This remains with the release owner.

The hourly run failed two unchanged native surfaces: the Mac packaging fixture matches the codesign | grep -q/pipefail defect addressed by open PR #157116; the Windows installer /healthy probe repeats MV1's documented outer PowerShell timeout at 10.132s, before stalled-download assertions. Prior focused/ordered Windows diagnostics passed without establishing a repair. Both logs were handed to MV1; no retries, deadline increases or duplicate patches were made.

@clawsweeper

clawsweeper Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation scripts Repository scripts size: S labels Sep 24, 2026
@steipete
steipete marked this pull request as ready for review September 24, 2026 13:34
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 24, 2026
@clawsweeper

clawsweeper Bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed September 24, 2026, 11:49 AM ET / 15:49 UTC (Revision 4).

ClawSweeper review

What this changes

The branch splits slow hourly hosted Node test groups into separate CI jobs, adds an inventory and row-budget guard, and documents the routing.

Merge readiness

✅ Ready for maintainer review

This PR remains useful: current main lacks the hourly hosted split, and a hosted workflow run shows faster validation with the selected Node tests completing. The reviewed patch has no identified blocking defect.

Priority: P2
Reviewed head: 1c04aa595a5a797adb51fc8f9c23fbb8e89f92d1

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused planner change has strong hosted-workflow evidence and a coverage guard, with no identified patch defect.
Proof confidence 🦞 diamond lobster (5/6) ✨ media proof bonus Sufficient (linked_artifact): The changed Node planner was exercised by a GitHub-hosted hourly-equivalent dispatch at bc81c12: 68 Node jobs succeeded and workflow wall fell from 56m16s to 40m03s against the earlier baseline. The reviewed rebase leaves the planner and guard unchanged; the full reduction is not isolated to this patch. No stored-data contract changes.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (linked_artifact): The changed Node planner was exercised by a GitHub-hosted hourly-equivalent dispatch at bc81c12: 68 Node jobs succeeded and workflow wall fell from 56m16s to 40m03s against the earlier baseline. The reviewed rebase leaves the planner and guard unchanged; the full reduction is not isolated to this patch. No stored-data contract changes.
Evidence reviewed 9 items Introduced planner change: The pinned main-to-head diff adds main-hosted file bounds, isolates the updater test, and prevents measured heavy children from being packed with other groups. Current main does not contain these additions.
Workflow boundary: The canonical workflow selects compact push planning for main validation and enforces a 70-row Node matrix limit.
Coverage guard: The added test checks the three affected owners' complete file inventories, worker bounds, dedicated placement, updater isolation, and the 70-row cap.
Findings None None.
Security None None.

How this fits together

OpenClaw's CI planner turns the selected test inventory and timing estimates into runner jobs. The hourly main workflow dispatches those jobs and collects their results.

flowchart LR
  A[Hourly main CI] --> B[Node test planner]
  C[Test inventory and timings] --> B
  B --> D{Hosted main group?}
  D -->|yes| E[Bounded dedicated rows]
  D -->|no| F[Ordinary packed rows]
  E --> G[Hosted test jobs]
  F --> G
Loading

Before merge

None.

Agent review details

Security

None.

PR surface

Tests +68, Docs +1, Other +36. Total +105 across 3 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 1 68 0 +68
Docs 1 1 0 +1
Config 0 0 0 0
Generated 0 0 0 0
Other 1 53 17 +36
Total 3 122 17 +105

Review metrics

Metric Value Why it matters
Observed hourly wall 56m16s → 40m03s The measured workflow improved by 16m13s, although inherited main changes prevent assigning all of that gain to this patch.
Hosted Node row budget 69 of 70 planned rows The demonstrated plan fits the enforced cap with one row of headroom.

Technical review

Best possible solution:

Keep the focused hosted-main split in the existing planner, preserving the full test inventory and hard row cap; address the remaining mixed-row delays through their routing owner.

Do we have a high-confidence way to reproduce the issue?

Not applicable as a product bug. The slow hourly CI path has a recorded hosted baseline and an after-change workflow run.

Is this the best way to solve the issue?

Yes. The existing Node planner owns this placement, and the branch confines the split to hosted main planning while preserving the selected tests.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 02ad6b76b1a2.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: This is a measured CI speed improvement with no product runtime change.
  • merge-risk: 🚨 automation: The patch changes hourly CI job placement, a workflow path that ordinary PR checks do not execute, while the hosted dispatch and inventory guard provide direct coverage.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (linked_artifact): The changed Node planner was exercised by a GitHub-hosted hourly-equivalent dispatch at bc81c12: 68 Node jobs succeeded and workflow wall fell from 56m16s to 40m03s against the earlier baseline. The reviewed rebase leaves the planner and guard unchanged; the full reduction is not isolated to this patch. No stored-data contract changes.
  • proof: sufficient: Contributor real behavior proof is sufficient. The changed Node planner was exercised by a GitHub-hosted hourly-equivalent dispatch at bc81c12: 68 Node jobs succeeded and workflow wall fell from 56m16s to 40m03s against the earlier baseline. The reviewed rebase leaves the planner and guard unchanged; the full reduction is not isolated to this patch. No stored-data contract changes.

Evidence

What I checked:

  • Introduced planner change: The pinned main-to-head diff adds main-hosted file bounds, isolates the updater test, and prevents measured heavy children from being packed with other groups. Current main does not contain these additions. (scripts/lib/ci-node-test-plan.mts:393, 1c04aa595a5a)
  • Workflow boundary: The canonical workflow selects compact push planning for main validation and enforces a 70-row Node matrix limit. (.github/workflows/ci.yml:1824, 02ad6b76b1a2)
  • Coverage guard: The added test checks the three affected owners' complete file inventories, worker bounds, dedicated placement, updater isolation, and the 70-row cap. (test/scripts/ci-node-test-plan-hosted-tail.test.ts:19, 1c04aa595a5a)
  • Hosted behavior proof: The candidate hourly-equivalent dispatch completed in 40m03s at planner commit bc81c12; its first jobs page contains 22 successful Node jobs and two failing native jobs outside this diff. (bc81c1256fbb)
  • Remaining hosted Node jobs: The second candidate jobs page contains another 46 successful Node jobs, for 68 successful Node jobs across the run. (bc81c1256fbb)
  • Baseline timing: The earlier hourly-equivalent dispatch ran from 09:48:57Z to 10:45:13Z, or 56m16s. The PR correctly notes that inherited main changes prevent attributing the full observed difference solely to this patch. (a7aa63b79eab)

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • Vincent Koc: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (3 earlier review cycles)
  • reviewed 2026-09-24T13:41:49.797Z sha bc81c12 :: blocked before merge. :: none
  • reviewed 2026-09-24T14:36:59.443Z sha bc81c12 :: needs maintainer review before merge. :: none
  • reviewed 2026-09-24T14:44:41.075Z sha bc81c12 :: needs maintainer review before merge. :: none

@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Sep 24, 2026
@steipete
steipete enabled auto-merge (squash) September 24, 2026 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to documentation merge-risk: 🚨 automation 🚨 May affect CI, automerge, proof capture, label sync, or maintainer automation. P2 Normal backlog priority with limited blast radius. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. scripts Repository scripts size: S status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant