CI: split generator specs into setup-safe subshards#4746
Conversation
WalkthroughGenerator specs are split across three deterministic CI shards. The workflow partitions examples without separating shared setup, while hosted CI safety tests validate matrix membership, stable sharding, coverage, and generator/unit exclusion behavior. ChangesGenerator CI sharding
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant GemWorkflow
participant RSpecManifest
participant GeneratorShard
GemWorkflow->>RSpecManifest: rebuild generator example manifest
RSpecManifest->>GeneratorShard: assign setup-safe examples to generators-1..3
GeneratorShard->>GemWorkflow: write shard-specific manifest
GemWorkflow->>GeneratorShard: run selected generator examples
Possibly related issues
Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Review: CI — split generator specs into setup-safe subshardsOverviewSplits the Strengths
Issues / suggestions (also left as inline comments)
Security / correctnessNo secrets, external network calls, or new permissions are introduced. The script only reads local spec files and writes to Overall: solid, well-reasoned design for a genuinely tricky problem (splitting specs with shared expensive setup while keeping shard assignment deterministic and stateless). The main actionable items are documenting/mitigating the private-API dependency and considering whether the 3x dry-run overhead is worth eliminating before merge. |
Review: split generator specs into setup-safe subshardsOverviewThis PR splits the Code quality
Potential issues / risks
Test coverage
Security
SummarySolid, well-reasoned design for a genuinely hard problem (deterministic, no-cache, per-head sharding while respecting |
Address-review summaryScan scope: full PR history; no previous address-review cutoff. Mattered
Optional
Skipped
No new follow-up issue was created. Issue #4683 already owns hosted timing and post-merge replay evidence. Current-head independent Codex review at Next default scan starts after this comment. Say |
Review: split generator specs into setup-safe subshardsOverviewReplaces the single Strengths
Concerns
Minor
Performance/cost noteThe dry-run (which loads every generator spec file to build the group tree) is now paid 3x - once per subshard job - instead of once. Since these are parallel jobs this doesn't add to wall-clock critical path, but it does add total runner-minutes. The PR body is upfront that actual hosted timing/variance is still UNKNOWN pending a force-full run, which seems like the right way to validate this before leaning on it. SecurityNo user-controlled input reaches the new script (matrix values are static enumerations in the same file); no secrets or cache reuse introduced. No concerns here. |
Address-review cutoff:
|
|
+ci-status |
CI StatusHead SHA: Only the required gate is active unless hosted CI is requested. |
|
+ci-force-full |
Force-Full Hosted CI RequestedTriggered 9 workflow(s) for View progress in the Actions tab. |
Address-review delta cutoff:
|
|
Review: CI split generator specs into setup-safe subshards Overview What looks solid
Issues raised inline
Other notes (not blocking, FYI)
No security concerns (no secrets/permissions touched) and no functional application code is affected, this is CI-only. |
|
+ci-status |
CI StatusHead SHA: Force-full hosted CI is enabled for this PR. |
Independent batch QA — READYExact head: |
Why
Generator specs dominate the gem workflow's full-matrix critical path. Six post-merge full-matrix runs established a 2,427-second median critical path and a 4,660-second paired runner-sum, while unit jobs remained near two minutes.
What
Verification
27d81b4beadad20b74301f17ee53c7f2000ad773.actionlintpassed.yamllintpassed with only the repository's existing line-length warnings.The review sandbox's attempted full shard execution could not write its home/cache and hit npm registry DNS
ENOTFOUND; no full local shard pass is claimed..agents/bin/validate --changedwas intentionally stopped during the long generator surface and is not claimed green.Hosted benchmark
Two exact-head force-full attempts passed all 16 matrix rows with zero flakes:
The repeated evidence supports retaining the three-way split. Full job links and calculations are recorded on #4683.
Workflow change audit
fail-fast: falseremains.Review churn
The first review rejected leaf-example hashing because it would repeat expensive
before(:all)/after(:all)setup across shards. The final design uses setup-safe atomic units and was revalidated after rebasing over the latestmain.The final simplify pass consolidated scoped-ID construction and precomputed unit weights. The portable manifest-read loop was retained deliberately. Those behavior-preserving changes were committed separately and re-reviewed at the exact head above.
Part of #4683. Keep the issue open pending exact-head force-full timing evidence and the required post-merge secondary-event replay.