LearnNewsExamplesConnect
Frontmatter
assigneesneo-opus-ada
createdAtNov 17, 2026, 2:09 PM
updatedAtNov 17, 2026, 11:02 PM
githubUrlhttps://github.com/neomjs/neo/issues/21259
authorneo-opus-ada
commentsCount4
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[x] 21257 The Portal''s Medium tab lists the part 3 story of the memory series
closedAtNov 17, 2026, 3:04 PM

A stale e2e duration table lets engine shards drift to the ceiling

Closed v14.0.0/archive-v14-0-0-chunk-3 bugcontributor-experienceaitestingbuild
neo-opus-ada
neo-opus-ada commented on Nov 17, 2026, 2:09 PM

Context

Two engine e2e shards hit the five-minute step ceiling today on pull requests whose tests all passed:

  • neo #21239 @ 098b335ee4, e2e-engine (13/14): "75 passed (5.1m)", then "The action 'Run e2e (engine tier)' has timed out after 5 minutes" (run 44040385390, defect note 73f2ec59).
  • outside PR #21240 @ 280f5f6, e2e-engine (4/14): "63 passed (5.0m)", then the same timeout (run 44082682665). None of that PR's specs run in that shard. The contributor cannot re-run jobs and had to ask on the PR (https://github.com/neomjs/neo/pull/21240#issuecomment-6948763797).

Each occurrence costs a maintainer re-run. An outside contributor who cannot re-run waits on a red check their change did not cause.

The Problem

balancedShard() splits the tier by measured seconds per spec file. The table it reads has fallen behind the tier:

  • buildScripts/util/e2eEngineDurations.json lists 194 files. The tier (enginePaths()) has 223. The 29 missing files are mostly specs added since the last full rebuild (board, gantt, timeline, core/ContentSecurityPolicy, grid/CountriesExample, …), and each counts as the table's median.
  • On dev's latest full run (44081473449 @ d49f1dd494, all green), the 14 shards' test steps took 195–236 s. Re-measured with that run's per-file times, the current split spreads from 189 to 230 s, while the table predicts at most 216 s.
  • Over the last 45 completed pull-request runs (379 shard steps): p50 216 s, p90 256 s, p99 293 s, max 301 s. 19 steps took 270 s or more. The tail sits on top of the imbalance, so the heaviest shard is the one that times out.

The Architectural Reality

  • .github/workflows/test-e2e.yml header: "the ceiling is five minutes of test time per shard … A shard nearing it gets a sibling, never a higher ceiling". The step's timeout-minutes is 5 on pull_request and push.
  • buildScripts/util/e2eCiSelection.mjs: FULL_SHARDS = {engine: 14}, and ENGINE_DURATIONS is read from e2eEngineDurations.json. balancedShard({paths, shard, durations}) assigns files by those seconds, and --engine-durations rebuilds the table from a full dev run's log (gh run view <id> --log).
  • #20521 replaced count-based splitting with this table. Its Avoided Traps rule out "another shard" as a fix for an unbalanced split.

The Fix

Regenerate e2eEngineDurations.json with the existing CLI from dev's latest full run: gh run view 44081473449 --log | node buildScripts/util/e2eCiSelection.mjs --engine-durations. A full, green dev run is the only valid input. Measured before filing, with that run's log: the rebuilt table covers all 223 files, and the 14 shards predict 209–210 s each, against 189–230 s for the current split. The heaviest shard drops by about 20 s, roughly what a fifteenth shard would buy, without the extra runner. FULL_SHARDS and the ceiling stay.

Decision Record impact: none.

Acceptance Criteria

  • e2eEngineDurations.json holds a time for every enginePaths() file, rebuilt from a named full green dev run.
  • The PR states each shard's predicted seconds with the old table and the new one. The new spread is at most 5 s.
  • test/playwright/unit/buildScripts/util/E2eCiSelection.spec.mjs passes.
  • Post-merge: the next 20 pull-request runs show no engine shard step at the 300 s ceiling with all tests passed. A miss reopens the choice between a fifteenth shard and a refresh that runs by itself.

Out of Scope

  • Refreshing the table automatically in CI, as in #20521. 29 files went missing in about 8 days, so this ticket's post-merge AC measures whether a manual refresh is enough.
  • The ceiling and FULL_SHARDS.engine.
  • The e2e-brain tier's table.

Avoided Traps

  • A fifteenth shard first. It buys the same 20 s for one more runner on every pull request, and the split stays as unbalanced as the table is stale (#20521).
  • Raising the ceiling. The header rules it out: the ceiling is the wait every pull request pays.
  • Re-running as the fix. It makes the contributor wait on a maintainer, every time.

Related

#20521 (time-balanced split), #19843, #19078, #18895 (earlier shard additions); #21239, #21240 (today's specimens).

Live latest-open + closed sweep: latest 20 open plus open and closed searches ("e2e shard ceiling timeout", "e2e engine shards five-minute ceiling", "e2e duration table stale shards") at 2026-11-17T13:10Z. The Out of Scope and Avoided Traps of #20521 and #19843 were read; no open equivalent. A2A in-flight sweep: no lane claim on the e2e tier in the last 30 messages. Memory Core: prior shard additions (09-21, 10-17, 11-07), no table refresh in flight. Own open assignments: none on this surface. Backlog: 82 open (red). No owning ticket or epic exists, so this files one.

Origin Session ID: d084cffc-f47b-49ae-946a-07326b960da9 Retrieval Hint: "engine e2e shard five-minute ceiling stale duration table balancedShard"

tobiu referenced in commit 8430274 - "fix(test): engine e2e shards balance on a fresh duration table (#21259) (#21260) on Nov 17, 2026, 3:04 PM
tobiu closed this issue on Nov 17, 2026, 3:04 PM