fix: resolve a relative dump path against the working directory #12

Manually merged
github merged 1 commit from gh-pr/12/head into gh-pr/12/base 2026-11-26 19:55:41 +00:00
Owner

@⁠AutoComput on GitHub · 2026-11-21 10:38 UTC · original
AutoComput:fix/relative-dump-path → main · +9 −4 · 2 files · 1 commits · merged 2026-11-22 09:58 UTC

TL;DR

  • Problem: Asking for a screenshot dump with a plain file name saves it inside the game's folder, not where you ran the command.
  • Fix: The file now goes where you ran the command.

A relative --rt-dump or --raster-dump path is passed to the guest unchanged. A child-process guest runs in the package directory, so scarlettx boot pkg --rt-dump rt_frame.ppm (the README example) writes the dump into the package, not where you ran the command. --in-process resolves it against the real working directory, so the two modes disagree.

Both paths are now made absolute before the guest starts.

test_scarlett_arena_e2e now passes a relative path for its child-process boot and expects the file in its own working directory; it fails without the fix. --raster-dump checked by hand only. Same function as #1, #3 and #6, different lines.

**@⁠AutoComput** on GitHub · 2026-11-21 10:38 UTC · [original](https://github.com/Freminet/ScarlettX/pull/12) `AutoComput:fix/relative-dump-path` → `main` · +9 −4 · 2 files · 1 commits · merged 2026-11-22 09:58 UTC **TL;DR** - **Problem:** Asking for a screenshot dump with a plain file name saves it inside the game's folder, not where you ran the command. - **Fix:** The file now goes where you ran the command. A relative `--rt-dump` or `--raster-dump` path is passed to the guest unchanged. A child-process guest runs in the package directory, so `scarlettx boot pkg --rt-dump rt_frame.ppm` (the README example) writes the dump into the package, not where you ran the command. `--in-process` resolves it against the real working directory, so the two modes disagree. Both paths are now made absolute before the guest starts. `test_scarlett_arena_e2e` now passes a relative path for its child-process boot and expects the file in its own working directory; it fails without the fix. `--raster-dump` checked by hand only. Same function as #1, #3 and #6, different lines.
A relative --rt-dump or --raster-dump path was handed to the guest as is. A
child-process guest runs in the package directory, so the dump was written
there instead of where scarlettx was started. Both paths are now made
absolute before the guest starts.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 19:55:40 +00:00
github manually merged commit 9d3d90bb5f into gh-pr/12/base 2026-11-26 19:55:41 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.