Scripts: run smoke.ps1 on Windows PowerShell 5.1 #318

Closed
github-bot wants to merge 2 commits from gh-pr/318/head into gh-pr/318/base
Owner

@⁠SandimL on GitHub · 2026-11-23 23:12 UTC · original
SandimL:smoke-ps51-followup → main · +29 −8 · 1 files · 2 commits · closed without merging

Stacked on #281; only commit f52ae3d belongs here.

Windows PowerShell 5.1 does not provide New-TemporaryFile, and its Start-Process fails when the process environment contains both Path and PATH. That made scripts/smoke.ps1 abort before it could run a title on some Windows machines, including the contributor machine used here.

What is in it

  • scripts/smoke.ps1: use System.Diagnostics.ProcessStartInfo with asynchronous stdout/stderr reads instead of New-TemporaryFile plus Start-Process. This works with Windows PowerShell 5.1 and avoids the duplicate-case environment failure.

Tested

  • Windows PowerShell 5.1.26100.9818 on Windows 11 build 26300.
  • On the #281 head, before this commit the script failed immediately with New-TemporaryFile is not recognized.
  • With this commit, scripts/smoke.ps1 -Game -Seconds 20 completed and emitted an xcl-smoke block; the adapter line came from #281's report path as AMD Radeon RX 6750 XT even though the WMI query is denied on this machine.

Not tested

  • PowerShell 7 on this machine (the pwsh.exe app alias is present but inaccessible).
  • A retail title; the repository test title was used only to exercise the process and report path.

AI use

  • Codex; the exact model name was not exposed in this session. It diagnosed the local failure, wrote the script change, and ran the validation.
**@⁠SandimL** on GitHub · 2026-11-23 23:12 UTC · [original](https://github.com/xcl-dev/xcl/pull/318) `SandimL:smoke-ps51-followup` → `main` · +29 −8 · 1 files · 2 commits · closed without merging Stacked on #281; only commit f52ae3d belongs here. Windows PowerShell 5.1 does not provide New-TemporaryFile, and its Start-Process fails when the process environment contains both Path and PATH. That made scripts/smoke.ps1 abort before it could run a title on some Windows machines, including the contributor machine used here. **What is in it** - scripts/smoke.ps1: use System.Diagnostics.ProcessStartInfo with asynchronous stdout/stderr reads instead of New-TemporaryFile plus Start-Process. This works with Windows PowerShell 5.1 and avoids the duplicate-case environment failure. **Tested** - Windows PowerShell 5.1.26100.9818 on Windows 11 build 26300. - On the #281 head, before this commit the script failed immediately with New-TemporaryFile is not recognized. - With this commit, scripts/smoke.ps1 -Game <test title> -Seconds 20 completed and emitted an xcl-smoke block; the adapter line came from #281's report path as AMD Radeon RX 6750 XT even though the WMI query is denied on this machine. **Not tested** - PowerShell 7 on this machine (the pwsh.exe app alias is present but inaccessible). - A retail title; the repository test title was used only to exercise the process and report path. **AI use** - Codex; the exact model name was not exposed in this session. It diagnosed the local failure, wrote the script change, and ran the validation.
The gpu line took the first Win32_VideoController that is not the basic
display adapter. On a machine with an iGPU and a discrete GPU that is often
the iGPU: on an RTX 3080 + AMD RDNA2 iGPU machine the block said
"AMD Radeon(TM) Graphics" while XCL ran on the RTX 3080.

The line now comes from d3d12.adapter in the run's report.json (next to the
log; XCL removes the previous run's report at start), without the VRAM
suffix. The Win32 query stays as the fallback when the report or the field
is missing.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 04:19:55 +00:00
github-bot closed this pull request 2026-11-26 04:19:55 +00:00
Author
Owner

@⁠ivall on GitHub · 2026-11-24 00:03 UTC · original

Merged by cherry-picking both commits (yours and #281's, which it is stacked on) into a6f5f7a. Checked on an RX 9070 (RDNA4) on main a6f5f7a, together with #335, #322, #331, #330, #338, #318 and #332: cargo test --workspace -- --test-threads=4 - 636 unit tests passed, 0 failed; the retail game reaches its menu and draws it (frame dump) and goes on past it.

**@⁠ivall** on GitHub · 2026-11-24 00:03 UTC · [original](https://github.com/xcl-dev/xcl/pull/318#issuecomment-7117663957) Merged by cherry-picking both commits (yours and #281's, which it is stacked on) into a6f5f7a. Checked on an RX 9070 (RDNA4) on main a6f5f7a, together with #335, #322, #331, #330, #338, #318 and #332: `cargo test --workspace -- --test-threads=4` - 636 unit tests passed, 0 failed; the retail game reaches its menu and draws it (frame dump) and goes on past it.

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No description provided.