From 3a6a4b2f9d3788a5f600b00a0de4ee27774af641 Mon Sep 17 00:00:00 2001 From: igneum-labs <337424239+igneum-labs@users.noreply.github.com> Date: Wed, 7 Oct 2026 16:59:54 +0000 Subject: [PATCH] windows-ci: the smoke run's Start-Process gets one retry (the exited-before-attach flake of release-0.3.21 run 37653903394, 7 October 2026, 17:40 UK) Start-Process -Wait -PassThru on igneum-app.exe --version, which exits in milliseconds, threw "Cannot process request because the process (6792) has exited" before PowerShell attached, and the release branch's Windows build went red on a runner race, not on the build. Run-Capture now tries twice and prints the first failure; the second is the verdict. Checked here by the workflow shell parse and the PowerShell 5.1 drive-reference check; the runner's own parse step runs on the next master push. Co-Authored-By: Claude Fable 5.1 --- .github/workflows/windows.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 82aa2f60c..f4f486d5c 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -216,8 +216,14 @@ jobs: run: | $payload = Resolve-Path 'packaging\windows\igneum-windows-app' function Run-Capture([string]$exe, [string]$flag) { + # Start-Process -Wait on an exe that exits in milliseconds can throw "Cannot process request because the process has + # exited" before it attaches (release-0.3.21 run 37653903394, 7 October 2026, 17:40 UK): one retry before the verdict. $out = Join-Path $env:RUNNER_TEMP ('smoke-' + [IO.Path]::GetRandomFileName() + '.txt') - $p = Start-Process -FilePath $exe -ArgumentList $flag -Wait -NoNewWindow -PassThru -RedirectStandardOutput $out + $p = $null + foreach ($try in 1, 2) { + try { $p = Start-Process -FilePath $exe -ArgumentList $flag -Wait -NoNewWindow -PassThru -RedirectStandardOutput $out; break } + catch { if ($try -eq 2) { throw }; Write-Host ("Start-Process on {0} {1} failed once ({2}); second try" -f (Split-Path -Leaf $exe), $flag, $_.Exception.Message); Start-Sleep -Milliseconds 500 } + } $text = if (Test-Path $out) { (Get-Content $out -Raw) } else { '' } Write-Host ("{0} {1} -> exit {2}: {3}" -f (Split-Path -Leaf $exe), $flag, $p.ExitCode, $text.Trim()) if ($p.ExitCode -ne 0) { throw "$exe $flag exited $($p.ExitCode)" }