Skip to content

CI: fix workflow startup_failure (matrix context in shell:)#1

Merged
fcreme merged 1 commit into
mainfrom
fix/ci-startup-shell-matrix
Jun 8, 2026
Merged

CI: fix workflow startup_failure (matrix context in shell:)#1
fcreme merged 1 commit into
mainfrom
fix/ci-startup-shell-matrix

Conversation

@fcreme

@fcreme fcreme commented Jun 8, 2026

Copy link
Copy Markdown
Owner

Problem

CI has failed on every push since b1758f4d ("add Windows PowerShell 5.1 test leg"). Every run was a startup_failure: zero jobs, zero logs, both matrix legs red — and runs even fired on non-main branches, because GitHub couldn't parse the workflow far enough to apply the branch filter.

Root cause

- name: Run Pester tests
  shell: ${{ matrix.shell }}   # <-- invalid

The matrix context is not available in a step's shell: key, so GitHub rejects the workflow at parse time — killing the entire run before any job starts. (actionlint flags exactly this line.) The tests themselves were never broken; they pass on both pwsh 7 and WinPS 5.1.

Fix

Select the shell with two if-guarded run steps (matrix is allowed in if:).

Verification

  • actionlint clean (exit 0) on the fixed file.
  • Full Pester suite passes locally on both pwsh 7 and Windows PowerShell 5.1.

🤖 Generated with Claude Code

`shell: ${{ matrix.shell }}` is invalid -- the matrix context is not available in a step's shell: key, so GitHub rejects the workflow at parse time. That's a startup_failure: the whole run dies before any job starts, so BOTH matrix legs showed red with zero jobs and zero logs (runs even fired on non-main branches, since the branch filter never got evaluated). Broken since b1758f4 added the WinPS 5.1 leg.

Select the shell with two if-guarded run steps instead; matrix IS allowed in if:. Verified with actionlint (clean) and by running the full Pester suite on both pwsh 7 and Windows PowerShell 5.1 locally.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@fcreme fcreme merged commit a649490 into main Jun 8, 2026
2 checks passed
@fcreme fcreme deleted the fix/ci-startup-shell-matrix branch June 8, 2026 07:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant