Scripts: preserve artifacts for world-entry smoke runs #1853

Closed
gloger2003 wants to merge 1 commit from upstream-pr/1863 into main
gloger2003 commented 2026-11-24 22:06:11 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by gloger2003 on 2026-11-24T22:06:11Z.


Fixes #1855. Part of #505 and #1833. Preserve the evidence for each smoke run before the next invocation rotates the title's files.

What is in it

  • Add -ArtifactsDir and -CacheState to scripts/smoke.ps1. Each invocation creates a separate local directory with the log, any report and a manifest of the build, input schedule and cache settings.
  • Keep the xcl-smoke v1 output and document matched checkpoint runs with fresh and seeded XCL caches.
  • Test repeat runs, missing reports and compatibility with the existing smoke block using a synthetic launcher.

Tested

  • Windows x64, Ryzen 7 5700X, Radeon RX 7800 XT. Both smoke script tests passed in PowerShell 7.6.9 and Windows PowerShell 5.1.26100.9818.

  • cargo build --offline --locked --workspace and cargo test --offline --locked --workspace --no-fail-fast -- --test-threads=4 --show-output. 959 reported passed, 0 failed, 43 ignored. Runtime skips: 7 (gpu, heap_window_out_of_memory_falls_back_to_the_switch_form).

  • Minecraft Preview completed a 30-second run with a fresh XCL DXIL cache and no device removal or crash. Verified that the script preserved all three artifacts. The executable was built from main and the runtime sources are identical on this branch.

  • Rebased onto main 568e7db to reconcile the README. Both smoke-script tests passed on the rebased head in PowerShell 7 and Windows PowerShell 5.1. The workspace and Minecraft Preview results above were collected on the previous revision c68f5b6.

Not tested

The retail title's world-entry checkpoint and reaching a specific in-game scene.

AI use

OpenAI Codex (GPT-6.2 Sol, high reasoning effort, Fast mode) wrote the script changes, regression test and documentation, ran the checks and drafted this description.

<!-- greyfinch-sync:ivall/xcl:issue:5481119271 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863). Originally posted by [gloger2003](https://github.com/gloger2003) on 2026-11-24T22:06:11Z. --- Fixes #1855. Part of #505 and #1833. Preserve the evidence for each smoke run before the next invocation rotates the title's files. **What is in it** - Add `-ArtifactsDir` and `-CacheState` to `scripts/smoke.ps1`. Each invocation creates a separate local directory with the log, any report and a manifest of the build, input schedule and cache settings. - Keep the `xcl-smoke v1` output and document matched checkpoint runs with fresh and seeded XCL caches. - Test repeat runs, missing reports and compatibility with the existing smoke block using a synthetic launcher. **Tested** - Windows x64, Ryzen 7 5700X, Radeon RX 7800 XT. Both smoke script tests passed in PowerShell 7.6.9 and Windows PowerShell 5.1.26100.9818. - `cargo build --offline --locked --workspace` and `cargo test --offline --locked --workspace --no-fail-fast -- --test-threads=4 --show-output`. 959 reported passed, 0 failed, 43 ignored. Runtime skips: 7 (gpu, heap_window_out_of_memory_falls_back_to_the_switch_form). - Minecraft Preview completed a 30-second run with a fresh XCL DXIL cache and no device removal or crash. Verified that the script preserved all three artifacts. The executable was built from main and the runtime sources are identical on this branch. - Rebased onto main `568e7db` to reconcile the README. Both smoke-script tests passed on the rebased head in PowerShell 7 and Windows PowerShell 5.1. The workspace and Minecraft Preview results above were collected on the previous revision `c68f5b6`. **Not tested** The retail title's world-entry checkpoint and reaching a specific in-game scene. **AI use** OpenAI Codex (GPT-6.2 Sol, high reasoning effort, Fast mode) wrote the script changes, regression test and documentation, ran the checks and drafted this description.
JJAutoCompare commented 2026-11-25 01:10:41 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by JJAutoCompare on 2026-11-25T00:26:23Z.


I reviewed and tested head c68f5b65f54518e975c10f5003976101d9200f28 for #1855.

The no-report case still loses the log. When report.json is absent, the launcher prints No report – see the log: <path>. The smoke script only parses lines starting with Log: and throws before writing any artifacts. I reproduced this with a synthetic launcher and an existing xcl.log. The bundled fixture still emits Log: after removing the report. Please make the fixture emit the launcher's real no-report message and verify that the script preserves the existing log.

The comparison recipe needs a caveat for older baselines. This PR's base script lacks -ArtifactsDir and -CacheState. Running the new script with -Xcl pointing at the baseline binary saves artifacts but records the script checkout's SHA as the build commit. The README recipe works when both checkouts have the new flags. For comparisons against earlier builds, the docs should explain how to record the baseline build SHA. External binary attribution is related to #1591.

Tested

  • Windows build 26200.9974, Windows PowerShell 5.1.26100.9818, Ryzen 7 3800X, Intel Arc A770 (driver 32.0.101.9175).
  • Ran powershell.exe -NoProfile -ExecutionPolicy Bypass -File scripts/smoke-artifacts.tests.ps1 and the same command for scripts/smoke-title.tests.ps1. Two passed, 0 failed, 0 skipped.
  • Additional synthetic cases confirmed that both the launcher-style no-report output and a stderr-only startup failure leave no artifact directory.
  • PR checks passed. Windows CI was awaiting maintainer approval at review time. The scripts-and-docs diff does not require paired runtime smoke blocks. The author reports a full Cargo run and a short fresh-cache Minecraft Preview smoke. The report leaves out the GPU driver and Rust version requested by CONTRIBUTING.md.

Not tested

I did not independently rerun Cargo, PowerShell 7, or a retail title. The PR report does not cover the matched fresh and seeded checkpoint runs or a visually confirmed world-entry milestone.

AI use

Codex (gpt-6.2-sol, T3 Code) reviewed the diff, ran the synthetic checks, and wrote this report.

<!-- greyfinch-sync:ivall/xcl:comment:7148510952 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7148510952). Originally posted by [JJAutoCompare](https://github.com/JJAutoCompare) on 2026-11-25T00:26:23Z. --- I reviewed and tested head `c68f5b65f54518e975c10f5003976101d9200f28` for #1855. **The no-report case still loses the log.** When `report.json` is absent, the launcher prints [`No report – see the log: <path>`](https://github.com/xcl-dev/xcl/blob/c68f5b65f54518e975c10f5003976101d9200f28/crates/xcl/src/launcher.rs#L492-L495). [The smoke script](https://github.com/xcl-dev/xcl/blob/c68f5b65f54518e975c10f5003976101d9200f28/scripts/smoke.ps1#L76-L80) only parses lines starting with `Log:` and throws before writing any artifacts. I reproduced this with a synthetic launcher and an existing `xcl.log`. The bundled fixture still emits `Log:` after removing the report. Please make the fixture emit the launcher's real no-report message and verify that the script preserves the existing log. **The comparison recipe needs a caveat for older baselines.** This PR's base script lacks `-ArtifactsDir` and `-CacheState`. Running the new script with `-Xcl` pointing at the baseline binary saves artifacts but records the script checkout's SHA as the build commit. The README recipe works when both checkouts have the new flags. For comparisons against earlier builds, the docs should explain how to record the baseline build SHA. External binary attribution is related to #1591. **Tested** - Windows build 26200.9974, Windows PowerShell 5.1.26100.9818, Ryzen 7 3800X, Intel Arc A770 (driver 32.0.101.9175). - Ran `powershell.exe -NoProfile -ExecutionPolicy Bypass -File scripts/smoke-artifacts.tests.ps1` and the same command for `scripts/smoke-title.tests.ps1`. Two passed, 0 failed, 0 skipped. - Additional synthetic cases confirmed that both the launcher-style no-report output and a stderr-only startup failure leave no artifact directory. - [PR checks passed](https://github.com/xcl-dev/xcl/actions/runs/45497673057). [Windows CI was awaiting maintainer approval](https://github.com/xcl-dev/xcl/actions/runs/45497673307) at review time. The scripts-and-docs diff does not require paired runtime smoke blocks. The author reports a full Cargo run and a short fresh-cache Minecraft Preview smoke. The report leaves out the GPU driver and Rust version requested by CONTRIBUTING.md. **Not tested** I did not independently rerun Cargo, PowerShell 7, or a retail title. The PR report does not cover the matched fresh and seeded checkpoint runs or a visually confirmed world-entry milestone. **AI use** Codex (`gpt-6.2-sol`, T3 Code) reviewed the diff, ran the synthetic checks, and wrote this report.
JJAutoCompare commented 2026-11-25 01:10:43 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by JJAutoCompare on 2026-11-25T00:30:51Z.


One additional diagnostic case at c68f5b6: the wrapper reads stderr but discards it before constructing the missing-log error. A synthetic launcher that reports its failure only on stderr leaves the exception without the launcher’s explanation. Including captured stderr when no log path can be parsed would preserve that evidence. The reproducible missing-report case and fixture commands are in the preceding review.

<!-- greyfinch-sync:ivall/xcl:comment:7148586058 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7148586058). Originally posted by [JJAutoCompare](https://github.com/JJAutoCompare) on 2026-11-25T00:30:51Z. --- One additional diagnostic case at `c68f5b6`: the wrapper reads stderr but discards it before constructing the missing-log error. A synthetic launcher that reports its failure only on stderr leaves the exception without the launcher’s explanation. Including captured stderr when no log path can be parsed would preserve that evidence. The reproducible missing-report case and fixture commands are in [the preceding review](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7148510952).
DavidM1911 commented 2026-11-25 02:08:53 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-25T01:38:29Z.


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!

<!-- greyfinch-sync:ivall/xcl:comment:7149784378 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7149784378). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-25T01:38:29Z. --- 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 commented 2026-11-25 15:07:54 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by RavenCurseBurg on 2026-11-25T14:35:41Z.


Reproduced the no-report case previously reported by @JJAutoCompare on the current head 9b70aade648de4c290fc967348b9974b019145ee. The checked-in artifact test passed in both shells, but its child prints Log: even after the report is removed. A native fixture printing the exact UTF-8 launcher message No report – see the log: <path> made scripts/smoke.ps1 -Seconds 1 -Game Fixture -Xcl <stub> -ArtifactsDir <outside-checkout> -CacheState seeded stop with XCL printed no log path before saving the existing log.

Fix and updated regression fixture, based directly on this PR head. The revised checked-in fixture failed on the original script in both shells. With the fix, scripts/smoke-artifacts.tests.ps1 and scripts/smoke-title.tests.ps1 passed in Windows PowerShell 5.1.26100.9711 and PowerShell 7.6.9. In a separate native-child run, the copied log had the same SHA-256 as the input under a path with spaces and square brackets. The manifest reported a null report and a seeded cache, and the smoke output retained the seven fixture frames.

Windows 11 26100.9711, i7-13700, RTX 4060. Script-only tests on the PR head, with no retail run, GPU workload or merge onto main. OpenAI Codex (GPT-6) ran the fixtures, prepared the patch and wrote this report.

<!-- greyfinch-sync:ivall/xcl:comment:7165517542 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7165517542). Originally posted by [RavenCurseBurg](https://github.com/RavenCurseBurg) on 2026-11-25T14:35:41Z. --- Reproduced the no-report case previously reported by @JJAutoCompare on the current head `9b70aade648de4c290fc967348b9974b019145ee`. The checked-in artifact test passed in both shells, but its child prints `Log:` even after the report is removed. A native fixture printing the exact UTF-8 launcher message `No report – see the log: <path>` made `scripts/smoke.ps1 -Seconds 1 -Game Fixture -Xcl <stub> -ArtifactsDir <outside-checkout> -CacheState seeded` stop with `XCL printed no log path` before saving the existing log. [Fix and updated regression fixture](https://github.com/RavenCurseBurg/xcl/commit/291201b3560d4345d8a49d79453fe511f32185ed), based directly on this PR head. The revised checked-in fixture failed on the original script in both shells. With the fix, `scripts/smoke-artifacts.tests.ps1` and `scripts/smoke-title.tests.ps1` passed in Windows PowerShell 5.1.26100.9711 and PowerShell 7.6.9. In a separate native-child run, the copied log had the same SHA-256 as the input under a path with spaces and square brackets. The manifest reported a null report and a seeded cache, and the smoke output retained the seven fixture frames. Windows 11 26100.9711, i7-13700, RTX 4060. Script-only tests on the PR head, with no retail run, GPU workload or merge onto main. OpenAI Codex (GPT-6) ran the fixtures, prepared the patch and wrote this report.
DavidM1911 commented 2026-11-26 07:03:38 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-26T06:41:26Z.


Re-verification on RTX 3060 Ti (Windows 11): still a merge conflict with current main on the new head — needs another rebase before it can be tested.

<!-- greyfinch-sync:ivall/xcl:comment:7184683679 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7184683679). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-26T06:41:26Z. --- Re-verification on RTX 3060 Ti (Windows 11): still a **merge conflict with current `main`** on the new head — needs another rebase before it can be tested.
Foniass commented 2026-12-01 07:02:01 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T07:02:01Z.


Triage (#1607) – head 9b70aad

The artifact capture this PR adds for #1855 is on main from #2023 (commit 9c8c0485): scripts/smoke.ps1 -OutDir copies xcl.log, report.json when present, and writes manifest.json with commit, dirty flag, GPU, seconds, exit, counts, XCL_PRESS_AT and XCL_DATA_ROOT. This PR's -ArtifactsDir does the same under another name and now conflicts with it.
What main lacks is small: a new subdirectory per invocation (#2980 adds this as -Repeat), the -CacheState label and DXIL cache roots in the manifest, refusing a directory inside the checkout, and the README section. These would fit as a follow-up on -OutDir.
Recommendation: close (superseded by main commit 9c8c048 / #2023).

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7303566273 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7303566273). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T07:02:01Z. --- **Triage (#1607)** – head 9b70aad The artifact capture this PR adds for #1855 is on main from #2023 (commit 9c8c0485): `scripts/smoke.ps1 -OutDir` copies `xcl.log`, `report.json` when present, and writes `manifest.json` with commit, dirty flag, GPU, seconds, exit, counts, `XCL_PRESS_AT` and `XCL_DATA_ROOT`. This PR's `-ArtifactsDir` does the same under another name and now conflicts with it. What main lacks is small: a new subdirectory per invocation (#2980 adds this as `-Repeat`), the `-CacheState` label and DXIL cache roots in the manifest, refusing a directory inside the checkout, and the README section. These would fit as a follow-up on `-OutDir`. Recommendation: close (superseded by main commit 9c8c048 / #2023). AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
throny commented 2026-12-01 12:49:35 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-12-01T12:49:35Z.


Closing as superseded: this change is already on main (9c8c0485). 9c8c0485 adds smoke.ps1 -OutDir (xcl.log, report.json, manifest.json) and a manifest test (#1855); not carried: PR's README reproduce section and a -CacheState label only (docs/minor)

Two independent checks found this: Foniass's close list on #1607 and ours against current main. If something here is still missing on main, say so and reopen it, or ask and I will.

AI use: Claude Code (Claude Opus 5.5); the per-PR comparison was done by Claude Sonnet 5.5 sub-agents.

<!-- greyfinch-sync:ivall/xcl:comment:7311702097 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1863#issuecomment-7311702097). Originally posted by [throny](https://github.com/throny) on 2026-12-01T12:49:35Z. --- Closing as superseded: this change is already on `main` (9c8c0485). 9c8c0485 adds smoke.ps1 -OutDir (xcl.log, report.json, manifest.json) and a manifest test (#1855); not carried: PR's README reproduce section and a -CacheState label only (docs/minor) Two independent checks found this: Foniass's close list on #1607 and ours against current `main`. If something here is still missing on `main`, say so and reopen it, or ask and I will. AI use: Claude Code (Claude Opus 5.5); the per-PR comparison was done by Claude Sonnet 5.5 sub-agents.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
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.

Reference
xcl-dev/xcl!1853
No description provided.