Skip to content

fix(ci): alpha promotion fails because older candidates don't accept -StepTimeoutMinutes - #2154

Merged
bkudiess merged 1 commit into
openclaw:mainfrom
bkudiess:bkudiess-ci-budget-env-compat
Nov 13, 2026
Merged

bkudiess merged 1 commit into
openclaw:mainfrom
bkudiess:bkudiess-ci-budget-env-compat

Conversation

@bkudiess

@bkudiess bkudiess commented Nov 13, 2026 •

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Fixes: alpha promotion fails with a parameter-binding error when it tests an older candidate, because the current workflow passes -StepTimeoutMinutes (added in #2141 (improve(ci): new flaky test patterns and slow CI steps go unnoticed until they fail)) to the candidate's older runner scripts, which do not declare it.

User Impact

No user-visible change. Maintainers can promote alpha builds again, starting with v2026.11.3-alpha.11. CI step budgets still print and warn at 80%.

Why This Change Was Made

promote-alpha-release.yml runs the current ci.yml but checks out the candidate commit and runs that commit's own scripts\*.ps1. A new runner parameter therefore breaks every older candidate.

  • The step budget is report-only, so it now travels in the step environment as OPENCLAW_CI_STEP_TIMEOUT_MINUTES. Older runners ignore it. The current runners read it when -StepTimeoutMinutes is not passed, so local runs can still pass the parameter.
  • test-ci-workflow-contract.ps1 now:
    • forbids -StepTimeoutMinutes in ci.yml;
    • requires each budgeted step's environment value to equal its timeout-minutes, with exactly one value per budgeted step and none elsewhere;
    • adds a promotion-binding check. It parses each of the 20 test-runner calls in ci.yml and checks that every named parameter exists, and every mandatory parameter is supplied, in both the current runners and the runners at the pinned candidate v2026.11.3-alpha.11. It fails closed on calls it cannot recognize (any other path spelling), argument splatting, --%, and parse errors.
  • docs/TEST_COVERAGE.md records the rule: a new option must be safe to ignore and passed through the environment, or must wait until the pin moves.

Alphas before alpha.11 already fail for other reasons: runner options added on Nov 9–10, such as -Configuration and -ExpectedTestCount. This change cannot restore them. A follow-up proposal covers a pipeline-owned harness that removes this class of break.

Evidence

  • The promotion-binding check passes on the current workflow for all 20 runner calls against alpha.11 and the current runners.
  • Mutation controls each fail at the intended check, and the clean tree passes:
    • runner fallback removed
    • budget drift (env 24 vs timeout-minutes 25)
    • -UiShard All on the multi-command stable-profile step
    • -NewKnob on a folded step
    • @extra splat
    • .\scripts\ backslash call
    • ${{ github.workspace }}\x value followed by -NewKnob
    • --%

Change Type

  • Bug fix
  • Feature
  • Refactor
  • Docs or instructions
  • Tests or validation
  • Security hardening
  • Chore or infrastructure

Scope

  • Tray or WinUI UX
  • Windows node capability
  • Local MCP or winnode
  • Gateway, connection, or pairing
  • Setup or onboarding
  • Permissions, privacy, or security
  • Tests, CI, or docs

Required proof pools

  • none: CI workflow and runner scripts only. No product behavior or capacity-dependent Windows proof is affected.

Validation

Local, base main 85c8ffa (rebased onto c7b75de and rechecked: contract, promotion, gate, timing guard, docs, git diff --check, build.ps1), PowerShell 7, isolated OPENCLAW_TRAY_* profile:

Command Result
scripts\test-ci-workflow-contract.ps1 ✅ pass (clean tree); each mutation under Evidence fails at its intended check
scripts\test-ci-gate-results.ps1, test-alpha-promotion.ps1, test-ci-change-classifier.ps1, test-ci-test-host-exit.ps1, test-ci-native-failure-metadata.ps1, test-native-animation-preference.ps1 ✅ pass
validate-docs.ps1, validate-agent-skills.ps1, test-agent-skills-validator.ps1, git diff --check ✅ pass
./build.ps1 ✅ pass
dotnet test ./tests/OpenClaw.Shared.Tests/OpenClaw.Shared.Tests.csproj 5848 passed, 29 skipped, 1 failed: CleanUninstallScriptTests.StandaloneCleanup_PassesIsolatedSafetyRegressions hit its literal 2-minute limit under load. It passes alone (1 m 43 s) and is unrelated to this change. An earlier run on the same change passed 5849/29.
dotnet test ./tests/OpenClaw.Tray.Tests/OpenClaw.Tray.Tests.csproj 6409 passed, 1 failed: TestDeterminismGuardTests (the main-only ratchet failure fixed by #2153)
scripts\validate-test-timing-patterns.ps1 ✅ pass after rebasing onto #2153 (c7b75de)

Hanselman dual review (Claude Opus 5.5 and GPT-6 Astra, high effort) found no blocking issues.

  • Fixed:
    • splatting bypass
    • other path spellings bypass
    • unreplaced ${{ }} values and ignored parse errors
    • docs rule widened to every script that candidate-checkout jobs call
    • test-selection wording now requires the timeout to cover the full run
  • Deferred to the pipeline-harness follow-up:
    • value-level binding (ValidateSet and range)
    • probing non-runner scripts
    • early fail for candidates older than the pin

Real Behavior Proof

  • Environment tested: local Windows 11 dev host, PowerShell 7, isolated OPENCLAW_TRAY_* profile.
  • PR head or commit tested: cb203ab (base main c7b75de)
  • Exact steps or command run: pwsh -NoProfile -File .\scripts\test-ci-workflow-contract.ps1 on the clean tree and on each mutation listed under Evidence.
  • Evidence after fix: the clean tree passes. Examples of the failure messages:
    • Every CI runner invocation must be checked for promotion compatibility: found 20 runner reference(s) but recognized 19.
    • CI step 'Run latest stable profile compatibility' does not bind to the candidate test-gateway-fixture runner: unknown -NewKnob
    • CI step 'Run latest stable profile compatibility' stops runner argument parsing with --%
  • Observed result: as expected.
  • Screenshot or artifact links verified? N/A
  • Not verified or blocked:
    • A real promote-alpha-release.yml run needs maintainer dispatch after merge.
    • The check compares parameter names only. A value that an older runner rejects (a new ValidateSet value or a wider range) still needs review.
    • Scripts other than the three test runners are not probed. The docs rule covers them.

Security Impact

  • New permissions or capabilities? No
  • Secrets or tokens handling changed? No
  • New or changed network calls? No
  • Command or tool execution surface changed? No
  • Data access scope changed? No
  • If any answer is Yes, explain the risk and mitigation: N/A

Compatibility and Migration

  • Backward compatible? Yes. -StepTimeoutMinutes still works locally and wins over the environment value.
  • Config or environment changes? Yes. Adds the CI-only OPENCLAW_CI_STEP_TIMEOUT_MINUTES step variable.
  • Migration needed? No
  • If yes, list the exact upgrade steps: N/A

Review Conversations

  • I replied to or resolved every bot review conversation addressed by this PR.
  • I left unresolved only conversations that still need maintainer judgment.

@clawsweeper

clawsweeper Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

🦞👀
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.

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. P2 Normal priority bug or improvement with limited blast radius. 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. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. labels Nov 13, 2026
@clawsweeper

clawsweeper Bot commented Nov 13, 2026

Copy link
Copy Markdown

Codex review: needs maintainer review before merge.

What this changes

This PR passes CI step budgets through an environment variable and checks runner arguments against an older alpha candidate.

Example: Promote v2026.11.3-alpha.11 using the current Shared Tests workflow step.

  • Before: The workflow passes -StepTimeoutMinutes 15, which the candidate runner does not declare.
  • After: The workflow sets OPENCLAW_CI_STEP_TIMEOUT_MINUTES='15' and omits the unsupported argument; current runners still report budget usage.

Review scores

Measure Result What it means
Overall readiness 🦐 gold shrimp (3/6) Useful, focused repair with supporting contract evidence; unresolved hosted test failures limit validation confidence without establishing a patch defect.
Proof confidence 🦐 gold shrimp (3/6) CI-only orchestration and reporting need no shipped-product proof; the body supplies Windows contract and mutation results and explicitly leaves live promotion dispatch unverified.
Patch quality 🦐 gold shrimp (3/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Release managers cannot promote an older alpha because its test runners reject a newer workflow argument.
Reason: The incompatible call is verified in current source, and collaborator authorship establishes direction for the CI-only environment setting.

Regression provenance

Regression provenance — suspected predecessor, not a causality claim: source commit 3a71e5f98eef by Scott Hanselman; no PR verified.

Possible regression — suspected (reviewed change). No predecessor PR is attributed.

Merge readiness

✅ Ready for maintainer review

Keep open: this collaborator-authored PR repairs a promotion regression still present on main, with no concrete introduced correctness or security defect found.

Priority: P2
Reviewed head: 2c2243810a5b412808d0a0050ff08a178b7422ab

Before merge

None.

Findings

None.

Agent review details

How this fits together

Alpha promotion uses the current CI workflow with candidate-source build and test checkouts; runner arguments and environment enter those scripts, which execute tests and emit results and diagnostics.

flowchart LR
  A[Promotion dispatch] --> B[Current CI workflow]
  B --> C[Candidate checkout]
  C --> D[Candidate test runners]
  B --> D
  D --> E[Test results]
  D --> F[Optional budget diagnostics]
Loading

Technical review

Best possible solution:

Keep the report-only budget in the step environment, retain explicit local overrides, and protect candidate argument compatibility in the existing workflow contract.

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

The current workflow supplies a named parameter absent from the pinned alpha.11 runner declarations, establishing the failure path without executing a promotion.

Is this the best way to solve the issue?

This is a focused repair using existing workflow and reporting owners; the compatibility checks cover the reported parameter-name failure without replacing the release harness.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against c7b75dedb52d.

Provenance checked

  • Workflow budget transport and runner resolution changes intended behavior with a stated reason (ee8edbc: Expose elapsed step-budget usage and warn before passing suites reach their workflow timeout.)
  • Workflow budget contracts and E2E reporting harness keeps the original intent (ee8edbc: Reject budget drift and preserve budget reporting on successful and failed test runs; the patch adapts those checks to environment transport.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Barbara Kudiess: Raw commit ee8edbc adds scripts/CiStepBudget.ps1:20 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: ee8edbc0bea4; files: scripts/CiStepBudget.ps1)
  • Karen: Raw commit 94006b3 adds .github/workflows/promote-alpha-release.yml:95 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 94006b3672a0; files: .github/workflows/promote-alpha-release.yml)
  • Dallin Romney: Raw commit 6647e54 adds scripts/Invoke-CiE2e.ps1:26 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 6647e5497dd0; files: scripts/Invoke-CiE2e.ps1)

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Labels

Label changes:

  • add P2: A source-confirmed compatibility regression blocks older-alpha promotion, with impact limited to the maintainer release workflow.
  • add rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦐 gold shrimp.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Label justifications:

  • P2: A source-confirmed compatibility regression blocks older-alpha promotion, with impact limited to the maintainer release workflow.
  • rating: 🦐 gold shrimp: Overall readiness is 🦐 gold shrimp; proof is 🦐 gold shrimp and patch quality is 🦐 gold shrimp.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

Reviewed November 13, 2026, 2:07 AM ET / 07:07 UTC.

…-StepTimeoutMinutes

Alpha promotion runs the current ci.yml against an older candidate's runner
scripts. Pass the report-only step budget through the step environment
(OPENCLAW_CI_STEP_TIMEOUT_MINUTES) instead of a runner parameter, and bind every
test-runner invocation's parameter names to the runners pinned at
v2026.11.3-alpha.11 in the workflow contract.

Co-authored-by: Copilot App <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal priority bug or improvement with limited blast radius. 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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant