Scripts: preserve the calling shell environment after smoke runs #521
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!521
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-521"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@wileyGray on GitHub · 2026-11-24 01:14 UTC · original
wileyGray:codex/smoke-child-environment→main· +55 −5 · 2 files · 1 commits · openRunning
scripts/smoke.ps1left networking disabled for later XCL runs in the same PowerShell session and erased the caller's time limit and activity setting. The child now inherits the smoke settings and the calling shell gets its original values back as soon as the child starts, including when launch fails.What is in it
scripts/smoke.ps1restores the threeXCL_*values infinallyaroundProcess.Start.scripts/smoke-environment.tests.ps1checks the child environment, set and absent parent variables, and a failed launch.Tested
.cmdstand-in.powershell.exe -NoProfile -NonInteractive -File scripts/smoke-environment.tests.ps1and the same command withpwsh.exe. All three cases passed on Windows PowerShell 5.1.26100.9818 and PowerShell 7.6.9. The same test on base7ebf1b8failed on both becauseXCL_NETWORKwas overwritten.scripts/test-native-stderr.tests.ps1also passed under both shells.9bb6aa2with Rust 1.93.0 MSVC and DXC 1.9.2609.5.cargo build --locked --workspace --offlinepassed.cargo test --workspace -- --test-threads=4reported 677 passed, 0 failed, 41 ignored. Two GPU tests reported SKIPPED (no wave64):gpu_geometry_wave32_prefix_count_over_a_maskandgpu_wave32_program_in_wave64_hardware.Not tested
XCL_SAMPLE_*unset), and the D3D12 debug layer (unavailable).AI use
@futurepro62 on GitHub · 2026-11-24 02:32 UTC · original
Tested exact head
9bb6aa2.Tested
powershell -NoProfile -File scripts/smoke-environment.tests.ps1on9bb6aa2: passed (exit 0).scripts/smoke.ps1of the parent commit7ebf1b8: fails (exit 1) withThe smoke run changed XCL_NETWORK in the calling shell.. So the test catches what the PR fixes.scripts/test-native-stderr.tests.ps1on9bb6aa2: passed.Not tested
pwsh), a realscripts/smoke.ps1run on a title (no title on this machine), the Rust suite (the PR changes no Rust).AI use
@2968412091-ui on GitHub · 2026-11-24 03:35 UTC · original
Independent PowerShell 7 check on Windows x64 build 26200. I ran
scripts/smoke-environment.tests.ps1from9bb6aa2eusing-NoProfile -File.91f9a5e9The smoke run changed XCL_NETWORK in the calling shell.9bb6aa2e9bb6aa2eThe synthetic fixture checked the child environment and restoration of the parent environment, including a failed launch. No GPU, retail title, or Rust workspace tests were run for this report.
AI use: Codex (GPT-6.2-astra) ran the tests and prepared this report.
@Alpha325 on GitHub · 2026-11-25 02:51 UTC · original
I tested
9bb6aa2efcfcb80b58187da5dc9f39a8df3a9a74against its parent7ebf1b8on Windows PowerShell 5.1.26100.9818 and PowerShell 7.6.9.A synthetic child recorded
XCL_NETWORK,XCL_RUN_SECONDS, andXCL_ACTIVITY, then waited for a release file. While it was still waiting, the child had the smoke settings (0 2 1) and the parent had its original settings (17 23 29). On the parent commit, the calling shell still exposed0 2 1at that same point. Both shells reproduced the difference.I also temporarily deferred restoration until the child exited on the PR. On PowerShell 7.6.9, the bundled fixture still passed, while the new fixture failed as expected. I restored
smoke.ps1after that control.AI use — OpenAI Codex (GPT-6) wrote and ran the synthetic fixture and drafted this report.
@DavidM1911 on GitHub · 2026-11-25 13:53 UTC · original
Verification on RTX 3060 Ti (Windows 11), branch merged with current
main:cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)Thanks!
@RavenCurseBurg on GitHub · 2026-11-25 20:36 UTC · original · edited 2026-11-25 20:46 UTC
Tested on
9bb6aa2efcfcb80b58187da5dc9f39a8df3a9a74, Windows 11 build 26100.9711, Core i7-13700. A native fixture initialized a Windows environment variable to the empty string withSetEnvironmentVariableW. I rotated the empty, absent and non-ASCII values throughXCL_NETWORK,XCL_RUN_SECONDSandXCL_ACTIVITY. For each rotation I ranscripts/smoke.ps1 -Seconds 2once with a working fixture executable and once with a directory as-Xclto makeProcess.Startfail. I compared the Windows environment block before and after.Every successful child saw
0 / 2 / 1. Invoking the script in a separate PowerShell process preserved all three values in the outer caller for every case on both editions. I added that verified invocation to the script help. Both shells also passed-NoProfile -ExecutionPolicy Bypass -File scripts/smoke-environment.tests.ps1.Not tested — A retail launch, GPU execution, or the Rust workspace. OpenAI Codex (GPT-6) prepared and ran the fixtures, wrote the help text, and prepared this report.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.