Scripts: read smoke log and report paths literally #2706

Open
luckyteagirl wants to merge 2 commits from upstream-pr/2716 into main
luckyteagirl commented 2026-11-26 08:15:01 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by luckyteagirl on 2026-11-26T08:15:01Z.


Stacked on #2651

A launcher can report a smoke log path containing square brackets. PowerShell wildcard lookup can then read a different run's log and GPU report. Use literal lookups while preserving the prerequisite's guards for writing artifacts into the source log directory.

What is in it

  • Read the launcher-reported log and adjacent report literally. Apply literal checks to the report and artifact paths.
  • Use a wildcard-matching decoy in the synthetic fixture. Cover separate and in-place artifact destinations, case variants, and removal of a stale destination report. Reviewer findings

Tested

  • On Windows 11 build 26200, the combined fixture failed on prerequisite head 382a161b with unexpected gpu: Decoy Adapter. On prior PR head b46c2665, the in-place case failed because Copy-Item tried to overwrite xcl.log with itself.
  • On c4b3c8ae, scripts/test-smoke-artifacts.tests.ps1 and scripts/smoke-title.tests.ps1 passed with -NoProfile -File on Windows PowerShell 5.1.26100.9711 and PowerShell 7.6.9. git diff --check passed.

Regression run

The fixture uses a synthetic launcher, log, and report. No runtime source changed.

Not tested

The Rust or GPU workspace suite, a retail title run, in-place paths through junction aliases, and directories explicitly configured for case-sensitive lookup.

AI use

OpenAI Codex (GPT-6.2 Sol) reproduced the original wildcard collision, implemented the fix and synthetic fixture, and ran the focused checks. OpenAI Codex (GPT-6.2 Astra) reviewed the original diff and reran both smoke fixtures. RavenCurseBurg used OpenAI Codex (GPT-6) to integrate and verify the two changes. OpenAI Codex (GPT-6, exact variant unavailable) prepared the local stack and independently verified both failures and the repaired fixtures.

<!-- greyfinch-sync:ivall/xcl:issue:5506396139 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2716). Originally posted by [luckyteagirl](https://github.com/luckyteagirl) on 2026-11-26T08:15:01Z. --- Stacked on #2651 A launcher can report a smoke log path containing square brackets. PowerShell wildcard lookup can then read a different run's log and GPU report. Use literal lookups while preserving the prerequisite's guards for writing artifacts into the source log directory. **What is in it** - Read the launcher-reported log and adjacent report literally. Apply literal checks to the report and artifact paths. - Use a wildcard-matching decoy in the synthetic fixture. Cover separate and in-place artifact destinations, case variants, and removal of a stale destination report. [Reviewer findings](https://github.com/xcl-dev/xcl/pull/2716#issuecomment-7186915675) **Tested** - On Windows 11 build 26200, the combined fixture failed on prerequisite head `382a161b` with `unexpected gpu: Decoy Adapter`. On prior PR head `b46c2665`, the in-place case failed because `Copy-Item` tried to overwrite `xcl.log` with itself. - On `c4b3c8ae`, `scripts/test-smoke-artifacts.tests.ps1` and `scripts/smoke-title.tests.ps1` passed with `-NoProfile -File` on Windows PowerShell 5.1.26100.9711 and PowerShell 7.6.9. `git diff --check` passed. **Regression run** The fixture uses a synthetic launcher, log, and report. No runtime source changed. **Not tested** The Rust or GPU workspace suite, a retail title run, in-place paths through junction aliases, and directories explicitly configured for case-sensitive lookup. **AI use** OpenAI Codex (GPT-6.2 Sol) reproduced the original wildcard collision, implemented the fix and synthetic fixture, and ran the focused checks. OpenAI Codex (GPT-6.2 Astra) reviewed the original diff and reran both smoke fixtures. RavenCurseBurg used OpenAI Codex (GPT-6) to integrate and verify the two changes. OpenAI Codex (GPT-6, exact variant unavailable) prepared the local stack and independently verified both failures and the repaired fixtures.
RavenCurseBurg commented 2026-11-26 08:42:13 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by RavenCurseBurg on 2026-11-26T08:42:13Z.


I combined this head b46c2665b273 with #2651 382a161b3eb1. Both scripts/smoke.ps1 and its artifact fixture conflict. The combined candidate preserves the literal lookups, the guard against copying a file onto itself, and the decoy in the regression test.

I ran a launcher that reported log [xy]/xcl.log. The intended report had a different adapter and frame count from its wildcard-matching sibling log x. On this PR alone the separate destination worked, but using the source directory as the destination failed. On #2651 alone the manifest reported the decoy adapter and frame count. When I removed the intended report, its previous destination copy remained in both shells.

On the combination, all three cases passed in both shells. The separate and in-place destinations recorded the intended adapter and counts and retained the exact source bytes. After I removed the source report, the previous destination report was removed while the sibling stayed intact. Both test-smoke-artifacts.tests.ps1 and smoke-title.tests.ps1 passed on the combined tree. I supplied a synthetic adapter name to the fallback lookup.

Windows PowerShell 5.1 and PowerShell 7.6.9 on Windows 11. OpenAI Codex (GPT-6) prepared and ran the fixtures. Synthetic logs, reports and immediately exiting launchers only; no game, GPU workload or workspace build.

Retest on c4b3c8aeaa08cfded659a6831344d2ef7e6080e2

I reran the three bracketed-path CLI cases on Windows PowerShell 5.1 and PowerShell 7 after this PR was stacked on #2651. All six passed. Separate and in-place destinations retained the intended log and report bytes. Removing the source report cleared the stale output and left the decoy intact. Both scripts/test-smoke-artifacts.tests.ps1 and scripts/smoke-title.tests.ps1 passed in both shells. The independent CLI check used an immediately exiting native stand-in and a synthetic fallback adapter.

OpenAI Codex (GPT-6) ran the synthetic fixtures on Windows 11. No retail title, GPU workload or Rust workspace build was used.

<!-- greyfinch-sync:ivall/xcl:comment:7186915675 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2716#issuecomment-7186915675). Originally posted by [RavenCurseBurg](https://github.com/RavenCurseBurg) on 2026-11-26T08:42:13Z. --- I combined this head `b46c2665b273` with #2651 `382a161b3eb1`. Both `scripts/smoke.ps1` and its artifact fixture conflict. The [combined candidate](https://github.com/RavenCurseBurg/xcl/commit/55ca7a0c39e34cfd07033593305c4bd9fedac69d) preserves the literal lookups, the guard against copying a file onto itself, and the decoy in the regression test. I ran a launcher that reported `log [xy]/xcl.log`. The intended report had a different adapter and frame count from its wildcard-matching sibling `log x`. On this PR alone the separate destination worked, but using the source directory as the destination failed. On #2651 alone the manifest reported the decoy adapter and frame count. When I removed the intended report, its previous destination copy remained in both shells. On the combination, all three cases passed in both shells. The separate and in-place destinations recorded the intended adapter and counts and retained the exact source bytes. After I removed the source report, the previous destination report was removed while the sibling stayed intact. Both `test-smoke-artifacts.tests.ps1` and `smoke-title.tests.ps1` passed on the combined tree. I supplied a synthetic adapter name to the fallback lookup. Windows PowerShell 5.1 and PowerShell 7.6.9 on Windows 11. OpenAI Codex (GPT-6) prepared and ran the fixtures. Synthetic logs, reports and immediately exiting launchers only; no game, GPU workload or workspace build. **Retest on `c4b3c8aeaa08cfded659a6831344d2ef7e6080e2`** I reran the three bracketed-path CLI cases on Windows PowerShell 5.1 and PowerShell 7 after this PR was stacked on #2651. All six passed. Separate and in-place destinations retained the intended log and report bytes. Removing the source report cleared the stale output and left the decoy intact. Both `scripts/test-smoke-artifacts.tests.ps1` and `scripts/smoke-title.tests.ps1` passed in both shells. The independent CLI check used an immediately exiting native stand-in and a synthetic fallback adapter. OpenAI Codex (GPT-6) ran the synthetic fixtures on Windows 11. No retail title, GPU workload or Rust workspace build was used.
Foniass commented 2026-12-01 08:48:01 +00:00 (Migrated from github.com)

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


Triage (#1607) – head c4b3c8a

Stacked on #2651: the first commit (382a161) is #2651's same-file artifact copy, and only c4b3c8a belongs here. That is not a duplicate.
The top commit makes the $log and report.json reads in scripts/smoke.ps1 literal, which #583 also does. #583 also fixes the -Xcl Test-Path. This PR also fixes the -OutDir / $destReport paths, which did not exist when #583 was written. Neither covers all of it, and main still uses wildcard Test-Path/Get-Content there. No problems found in the diff.
Recommendation: keep open.

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:7305800834 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2716#issuecomment-7305800834). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T08:48:01Z. --- **Triage (#1607)** – head c4b3c8a Stacked on #2651: the first commit (`382a161`) is #2651's same-file artifact copy, and only `c4b3c8a` belongs here. That is not a duplicate. The top commit makes the `$log` and `report.json` reads in `scripts/smoke.ps1` literal, which #583 also does. #583 also fixes the `-Xcl` `Test-Path`. This PR also fixes the `-OutDir` / `$destReport` paths, which did not exist when #583 was written. Neither covers all of it, and main still uses wildcard `Test-Path`/`Get-Content` there. No problems found in the diff. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/2716:upstream-pr/2716'
git switch 'upstream-pr/2716'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/2716'
git switch 'upstream-pr/2716'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/2716'
git switch 'upstream-pr/2716'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/2716'
git switch 'main'
git merge --squash 'upstream-pr/2716'
git switch 'main'
git merge --ff-only 'upstream-pr/2716'
git switch 'main'
git merge 'upstream-pr/2716'
git push origin 'main'
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!2706
No description provided.