Keep logging preload when native commands write to stderr #4853

Open
github-bot wants to merge 1 commit from github-bot/gh-4852 into main AGit
Owner

@⁠andrewpozdnakov7-jpg on GitHub · 2026-12-01 11:39 UTC · original
andrewpozdnakov7-jpg:codex2/fix/launcher-native-stderr → main · +11 −3 · 1 files · 1 commits · open

What it changes

play-nvidia.ps1 captures the output of clear-shaders, warm, and preload in the same log. Windows PowerShell 5.1 can treat the native command's redirected stderr as a terminating error when the caller sets $ErrorActionPreference = 'Stop'. That can interrupt a successful preload and leave the game unstarted.

Scope the error handling to those three native steps so the log receives their output and the launcher can use the actual process exit code. Other launcher operations still use the caller's preference.

How it was tested

  • Ran the actual Windows PowerShell 5.1 launcher from a caller with $ErrorActionPreference = 'Stop'. A synthetic executable wrote to stdout and stderr. Main 5fabb46e and release v2026.11.30.03 stopped with NativeCommandError even though it returned 0.
  • With 265603477bd56bc4494b977b27ef064d9bd5aee9, -WarmUsed returned 0 or 7 as supplied by the stub and logged both streams. The clear and preload sequence logged both streams, reached the stubbed run step, and exited 0.
  • cargo xtask policy --staged passed for the launcher file. This fixture covers output and exit-code handling.
  • Main's CI check has five existing Clippy errors tracked in #4708.

Checked for overlap

  • Searched for launcher use of ErrorActionPreference and NativeCommandError during preload. #4813 changes which counts the preload UI shows, and #4832 changes its log filename.

Please retain the Git author on cherry-pick or rebase, or add Co-authored-by: andrewpozdnakov7-jpg <[email protected]> if folding the change into another commit.

AI-assisted with OpenAI Codex.

**@⁠andrewpozdnakov7-jpg** on GitHub · 2026-12-01 11:39 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4852) `andrewpozdnakov7-jpg:codex2/fix/launcher-native-stderr` → `main` · +11 −3 · 1 files · 1 commits · open ## What it changes `play-nvidia.ps1` captures the output of `clear-shaders`, `warm`, and `preload` in the same log. Windows PowerShell 5.1 can treat the native command's redirected stderr as a terminating error when the caller sets `$ErrorActionPreference = 'Stop'`. That can interrupt a successful preload and leave the game unstarted. Scope the error handling to those three native steps so the log receives their output and the launcher can use the actual process exit code. Other launcher operations still use the caller's preference. ## How it was tested - Ran the actual Windows PowerShell 5.1 launcher from a caller with `$ErrorActionPreference = 'Stop'`. A synthetic executable wrote to stdout and stderr. Main `5fabb46e` and release `v2026.11.30.03` stopped with `NativeCommandError` even though it returned 0. - With `265603477bd56bc4494b977b27ef064d9bd5aee9`, `-WarmUsed` returned 0 or 7 as supplied by the stub and logged both streams. The clear and preload sequence logged both streams, reached the stubbed run step, and exited 0. - `cargo xtask policy --staged` passed for the launcher file. This fixture covers output and exit-code handling. - Main's [CI check](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46563306780/job/142355972539) has five existing Clippy errors tracked in #4708. ## Checked for overlap - [x] Searched for launcher use of `ErrorActionPreference` and `NativeCommandError` during preload. #4813 changes which counts the preload UI shows, and #4832 changes its log filename. Please retain the Git author on cherry-pick or rebase, or add `Co-authored-by: andrewpozdnakov7-jpg <[email protected]>` if folding the change into another commit. AI-assisted with OpenAI Codex.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-01 11:42:50 +00:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/4853/head:github-bot/gh-4852'
git switch 'github-bot/gh-4852'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-4852'
git switch 'github-bot/gh-4852'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-4852'
git switch 'github-bot/gh-4852'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-4852'
git switch 'main'
git merge --squash 'github-bot/gh-4852'
git switch 'main'
git merge --ff-only 'github-bot/gh-4852'
git switch 'main'
git merge 'github-bot/gh-4852'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA!4853
No description provided.