WIP: feat(build)!: Longshot Launcher 2: versions built by longshot-builder, profiles and saves, a clean break from make_game.py releases #259

Draft
HumanBean wants to merge 35 commits from HumanBean/LongshotLauncher:feat/longshot-build into main
Owner

Longshot's builder is rewritten in Rust as one program, longshot-builder (Longshot #2286). It is a clean break from make_game.py: other options, JSON events instead of @@ lines, a game that reads its files from the player's .nup in place, and a release that ships only one self-contained file per system. The launcher has to build the releases that ship it, and keep building every older release the way it does now.

It must ship with a Longshot #2286 that has the flags (--cache, --builder-exe, --ngx-sdk): the launcher passes its settings as those flags, which an earlier longshot-builder does not know.

What changed

  • One abstraction, two builders (Core/Builders.cs): IBuilder covers build, check, how its output reads, which upscalers it builds, and whether its game reads the .nup in place.
    • MakeGameBuilder wraps the existing MakeGameCommand, MakeGameProtocol and MakeGameRun, unchanged.
    • LongshotBuilder (Core/LongshotBuilder.cs) runs longshot-builder.
    • The old builder can be deleted in one change: MakeGameBuilder and what only it uses.
  • A release of the new kind, detected by its manifest (Core/LongshotBuildRelease.cs). The release ships, per system:
    • longshot-builder-<version>-<system> (.exe on windows-x64): builder, sources, prebuilt objects, compilers and libraries in one file;
    • zstd deltas of it from the channel's last releases;
    • longshot-builder-<version>-<system>.json, the manifest.
  • What detection uses: a manifest signed in the release's SHA256SUMS makes the release this kind, whatever its version (ReleaseInfo.BuilderManifests). Any other release goes the old way, unchanged.
  • The install (Toolchains.InstallLongshotBuildAsync, from ToolsSource):
    1. Read the manifest. Refused: another format, version, system or channel; a name that is not a plain file name; a malformed SHA-256.
    2. Delta, when possible: the first listed delta whose from version's file this PC keeps, its bytes hashed to from_sha256. It is downloaded and applied by App/ZstdPatcher.cs.
    3. Otherwise, or when the delta fails or makes other bytes: the full file.
    4. The result is checked against the manifest's size and SHA-256 and refused otherwise.
    5. It is installed into toolchains/<tag>/ (staged, then renamed) and made executable on Linux. Its record keeps its SHA-256 (the next delta's base) and the manifest's stamps.
    • A version whose file is gone, emptied or changed (an antivirus's quarantine, for one) is installed again.
  • Deltas (App/ZstdPatcher.cs): applied with ZstdSharp, MIT, Zstandard's own code in C#, so it works on both systems with no native library.
    • Decoded as zstd -d --patch-from does: the base is the frame's prefix (ZSTD_DCtx_refPrefix).
    • The window is capped at LongshotBuildRelease.DeltaWindowLog (30, as #2286's dev release makes them).
    • It is a new package of App only. Core keeps none, and its tests take a stand-in patcher. The lock files are updated.
  • Bases kept (LongshotBuildRelease.Keep, in PruneTools): every installed version's file, plus the 2 newest other longshot-builder files per channel. A version taken off the list still serves as the next update's base; older ones go. They have their own row on the Storage page.
  • Shader caches: keyed by the manifest's stamps (ShaderCaches.Stamp, from the version's record), as #257 did with --stamps for the old builder. A new-kind stamp never equals an old one. The shader caches and the shader store are kept while a build runs, and LONGSHOT_SHADER_STORE is passed to the builder.
  • Performance statistics (Core/PerfReports.cs): a version of the new kind sends with longshot-builder perf-report <folder> --send --json --cache <cache>, started detached as before. Older versions run perf_report.py as before.
  • No tools for the new kind: it carries its compilers and libraries. No tool folders, EMSDK, RX_CPM, LONGSHOT_SYSROOT or --root are given, and LONGSHOT_TOOLS is left out.
  • The new builder's command lines:
    • build --game <.nup> --out <folder> --work <folder> --cache <cache> --builder-exe <launcher> --json [--jobs N] [--language ..] --upscaler dlss,fsr4|none [--accept-licenses ..] [--no-prepare-shaders]
    • update <folder> --work <folder> --cache <cache> --builder-exe <launcher> --json ...
    • check --game <.nup> --cache <cache> --json
    • The cache is <build files folder>/longshot-builder, which joins Disk.WorkParts, so Storage, Keep build files, the cold build and Remove everything cover it.
  • The events (Core/BuildEvents.cs): versioned JSON Lines (v 1), read into the existing BuildProgress and BuildClock, so the bar, the stage rows, the time left and the details work as before.
    • Compiled and retried units count as files compiled.
    • shaders_not_prepared skips the shaders' row and says why.
    • error keeps its code. Another version's event, an unknown type or an unknown field is passed over.
    • The warnings a build said are kept; the Ready page says translation_damaged in the launcher's words.
  • Errors by code (Problems.FromCode): the important codes get the launcher's own translatable texts and fixes; any other code shows the builder's own text.
    • nup_moved/nup_missing/game_not_found: Pick the .nup again.
    • not_a_nup, work_folder_busy, game_folder_busy, game_files_overlap, dump_damaged, the game folder's refusals, tools_incomplete: each has its own entry.
    • unsupported_build, the incomplete-dump codes, disk_full, game_running: the existing problems, game_running, game_not_found and disk_full in longshot-builder's own words.
    • The file check maps its codes too (LongshotBuilder.ReadCheck).
    • The codes the launcher sorts are checked against the Codes table of #2286's docs/dev/reference/build-events.md (tests/fixtures/longshot-builder/codes.md, a copy that tests/test_launcher_core.py compares with a Longshot checkout's).
  • The .nup stays where it is: nothing is copied into the game folder.
    • The build's row keeps the .nup's path and NupInPlace.
    • The Ready page asks the player to keep the .nup where it is.
    • Play reads the folder's longshot_builder.json. When its .nup is gone, Play starts a rebuild of that version, and step 1 says why and asks for the .nup where it is now.
    • A build stopped on nup_moved offers to pick it again.
  • Licences: --accept-licenses names only the vendors whose licence the player accepted, on build and update alike (LongshotBuilder.Licences).
    • nvidia for DLSS's SDK; amd for FSR 4's runtime and intel for XeSS's library, both on Windows only.
    • If the build still stops on license_not_accepted, the problem page offers Read the licence: the prompt for the vendor the error names, and on yes the licence is kept and the build starts again.
    • DLSS, FSR 4 and XeSS are built by longshot-builder, which downloads their files itself.
  • No inherited redirects: longshot-builder and its perf-report start with every LONGSHOT_*, RX_* and A64_* variable of the PC removed, by prefix (LongshotBuilder.Dropped, MakeGameCommand.DroppedPrefixes). The launcher's own are then set again: LONGSHOT_SHADER_STORE, LONGSHOT_MEM_LIMIT_GB, and Intel's RX_VK_ switches. make_game.py's environment is as it was.
  • The program's name in one place: LongshotBuilder.Name is longshot-builder, its release files longshot-builder-<v>-<system> and its manifest likewise. Deltas are longshot-builder-<from>-to-<v>-<system>.zst-patch, named by the manifest. Detection is by a manifest's exact name only, never by a name holding "Builder": the old Windows app was LongshotBuilder.exe.
  • Running game detection: longshot-builder's game (longshot, longshot.exe, any case) is seen running; the builder is not.
  • Translations of the new texts in the 12 full catalogs, and the catalogs' four left-over texts removed. README: the new kind of release and keeping the .nup; ZstdSharp credited.

What the review round changed

  • Settings as flags: build, update and check get --cache and --builder-exe in place of LONGSHOT_CACHE and LONGSHOT_BUILDER_EXE. DLSS uses the builder's own pinned SDK: no --ngx-sdk is passed, so an SDK an older launcher fetched never reaches it.
  • Build memory and the shader store: the Build memory setting is passed as LONGSHOT_MEM_LIMIT_GB; LONGSHOT_SHADER_STORE is kept, so the game's pipelines come from the launcher's store.
  • The moved-.nup check applies only to folders longshot-builder built last, so a stale record no longer stops Play; a .nup on a drive that is not plugged in says "connect it" instead of asking for the .nup again.
  • A work folder per row (--work <build files>/longshot-builder/work/launcher-<row id>), so an update finds the row's lift and objects and stays warm. Each row that exists before this update has one cold update, as its work folder is new.
  • Free space: a build of the new kind needs 3 GB where its build files go and 1 GB where the game goes, checked on both drives (4 GB when they are one drive), not make_game.py's 60 GB.
  • Storage: Free up space keeps the builder's tools; the old builder's files (make_game.py's leftovers, its SDKs) are pruned once nothing uses them; the delta bases have their own row; Remove everything covers every build files folder chosen before and waits for a build.
  • A quarantined builder (a file gone, emptied or changed) is installed again, and tools_incomplete says to restore it from the antivirus's quarantine.
  • Error codes checked against #2286's build-events.md (the copy and its test above); drive_error is the PC's, not the file's; exit 2 has its own line; busy is a build's lock.
  • Pull request builds stop once the newest nightly is longshot-builder's, saying why: there is no source tree to lay the pull request over yet.

How it relates to #257

#257 is superseded by this pull request. #257 had the old builder install its own tools, via builder.json, make_game.py --tools-only, a shared tools store and --stamps for the shader caches.

A release of the new kind carries its tools inside its one file, so there is no tools stage left to move. Older releases keep the launcher's existing flow, unchanged. The one piece of #257 still needed, shader caches keyed by the builder's stamps, is here, from the manifest. #257 is not closed: that is for its author to decide.

Testing

Tested, on Linux (CachyOS), with tests only, on the first version:

  • dotnet build LongshotLauncher.slnx: 0 warnings.
  • The core checks (tests/test_launcher_core.py's build and run): 2802 checks pass.
  • The app-level checks (tests/launcher_app): pass.
  • LongshotBuildReleaseChecks.cs, with a stand-in patcher and fetcher: the manifest read, and refused for each reason; the delta chosen by the bases kept; installs by full file, by delta, and from a delta that made other bytes (falls back to the full file); a base whose file changed; a full file of other bytes (refused, nothing left); a manifest SHA256SUMS does not sign; executable on Linux; the stamps; the bases a prune keeps and deletes; a release with and without a signed manifest.
  • tests/launcher_app: ZstdPatcher over tests/fixtures/longshot-builder/delta, a 2 KB delta made by the zstd CLI (zstd -19 --patch-from=base.bin --long=27), gives the target byte for byte; another base does not.
  • LongshotBuildChecks.cs: events from recorded synthetic lines (one whole build and one stopped on nup_moved); the code mapping; the check's answers; the builder chosen by kind; the command lines and their environment; the .nup record.

The review round adds BuilderStorageChecks.cs (the work folder per row, the disk needs, Storage's rows, the bases, Remove everything, perf-report's cache), the manifest's channel, the codes against build-events.md, the flags, Build memory, the shader store and the unplugged drive in LongshotBuildChecks.cs, and the running-game names in the saves checks. On the head qsytpsmy (after the review round), on Linux: the App builds with no warnings and the whole python -I tests/test_launcher_core.py passes, 2897 checks, the translation check included.

Not tested against a real Longshot release: none ships a manifest yet; that waits on Longshot #2286. The launcher UI was not started with a longshot-builder release.

Still to do

  • The core and app checks on this head (qsytpsmy), by hand.
  • Once a #2286 nightly is out, on Linux and on Windows (NVIDIA and AMD), by hand:
    • a first install (the full file) and a first build;
    • the next nightly, by delta, and an update of an existing row (one cold update, then warm);
    • a run to play;
    • move the .nup and press Play; unplug its drive and press Play ("connect it");
    • a refused folder;
    • an older release, which takes the make_game.py path, unchanged.
  • Pull request builds of the new kind; a button for share.
  • Screenshots of the Ready page note and the step 1 text once it runs.

This is the gate before it leaves WIP.

Risks

  • Ships with #2286's flags: this launcher passes --cache and --builder-exe, which a longshot-builder from before them does not know. Release both together.
  • One cold update per existing row: a row's work folder is new, so its first update after this re-lifts and recompiles (with #2286's new keys, every player does that once anyway).
  • Pull request builds are refused once the newest nightly is longshot-builder's, until the new kind can build a pull request's source.
  • Never run on Windows or against a real release: the install, the deltas, the flags and the Storage changes have run only in checks.

Measurements

The launcher's start does not change. An update of the new kind downloads a delta, a few MB, instead of the builder and its tools (about 500 MB before; 110 to 160 MB for a full file of the new kind). Applying it reads the base into memory, about 150 MB, for a few seconds. The launcher's download grows by ZstdSharp, about 0.5 MB. make_game.py builds take the same path as before.

🤖 Generated with Claude Code

https://claude.ai/code/session_017vw8e2TsN4jgNUFQPfkAq8

Longshot's builder is rewritten in Rust as one program, `longshot-builder` ([Longshot #2286](https://git.magicbean.dev/MagicBeanDev/Longshot/pulls/2286)). It is a clean break from `make_game.py`: other options, JSON events instead of `@@` lines, a game that reads its files from the player's .nup in place, and a release that ships only one self-contained file per system. The launcher has to build the releases that ship it, and keep building every older release the way it does now. **It must ship with a [Longshot #2286](https://git.magicbean.dev/MagicBeanDev/Longshot/pulls/2286) that has the flags** (`--cache`, `--builder-exe`, `--ngx-sdk`): the launcher passes its settings as those flags, which an earlier `longshot-builder` does not know. ## What changed - **One abstraction, two builders** (`Core/Builders.cs`): `IBuilder` covers build, check, how its output reads, which upscalers it builds, and whether its game reads the .nup in place. - `MakeGameBuilder` wraps the existing `MakeGameCommand`, `MakeGameProtocol` and `MakeGameRun`, unchanged. - `LongshotBuilder` (`Core/LongshotBuilder.cs`) runs `longshot-builder`. - The old builder can be deleted in one change: `MakeGameBuilder` and what only it uses. - **A release of the new kind, detected by its manifest** (`Core/LongshotBuildRelease.cs`). The release ships, per system: - `longshot-builder-<version>-<system>` (`.exe` on windows-x64): builder, sources, prebuilt objects, compilers and libraries in one file; - zstd deltas of it from the channel's last releases; - `longshot-builder-<version>-<system>.json`, the manifest. - **What detection uses:** a manifest signed in the release's `SHA256SUMS` makes the release this kind, whatever its version (`ReleaseInfo.BuilderManifests`). Any other release goes the old way, unchanged. - **The install** (`Toolchains.InstallLongshotBuildAsync`, from `ToolsSource`): 1. Read the manifest. Refused: another format, version, system or channel; a name that is not a plain file name; a malformed SHA-256. 2. Delta, when possible: the first listed delta whose `from` version's file this PC keeps, its bytes hashed to `from_sha256`. It is downloaded and applied by `App/ZstdPatcher.cs`. 3. Otherwise, or when the delta fails or makes other bytes: the full file. 4. The result is checked against the manifest's size and SHA-256 and refused otherwise. 5. It is installed into `toolchains/<tag>/` (staged, then renamed) and made executable on Linux. Its record keeps its SHA-256 (the next delta's base) and the manifest's `stamps`. - A version whose file is gone, emptied or changed (an antivirus's quarantine, for one) is installed again. - **Deltas** (`App/ZstdPatcher.cs`): applied with [ZstdSharp](https://github.com/oleg-st/ZstdSharp), MIT, Zstandard's own code in C#, so it works on both systems with no native library. - Decoded as `zstd -d --patch-from` does: the base is the frame's prefix (`ZSTD_DCtx_refPrefix`). - The window is capped at `LongshotBuildRelease.DeltaWindowLog` (30, as #2286's `dev release` makes them). - It is a new package of App only. Core keeps none, and its tests take a stand-in patcher. The lock files are updated. - **Bases kept** (`LongshotBuildRelease.Keep`, in `PruneTools`): every installed version's file, plus the 2 newest other `longshot-builder` files per channel. A version taken off the list still serves as the next update's base; older ones go. They have their own row on the Storage page. - **Shader caches:** keyed by the manifest's `stamps` (`ShaderCaches.Stamp`, from the version's record), as #257 did with `--stamps` for the old builder. A new-kind stamp never equals an old one. The shader caches and the shader store are kept while a build runs, and `LONGSHOT_SHADER_STORE` is passed to the builder. - **Performance statistics** (`Core/PerfReports.cs`): a version of the new kind sends with `longshot-builder perf-report <folder> --send --json --cache <cache>`, started detached as before. Older versions run `perf_report.py` as before. - **No tools for the new kind:** it carries its compilers and libraries. No tool folders, `EMSDK`, `RX_CPM`, `LONGSHOT_SYSROOT` or `--root` are given, and `LONGSHOT_TOOLS` is left out. - **The new builder's command lines:** - `build --game <.nup> --out <folder> --work <folder> --cache <cache> --builder-exe <launcher> --json [--jobs N] [--language ..] --upscaler dlss,fsr4|none [--accept-licenses ..] [--no-prepare-shaders]` - `update <folder> --work <folder> --cache <cache> --builder-exe <launcher> --json ...` - `check --game <.nup> --cache <cache> --json` - The cache is `<build files folder>/longshot-builder`, which joins `Disk.WorkParts`, so Storage, *Keep build files*, the cold build and Remove everything cover it. - **The events** (`Core/BuildEvents.cs`): versioned JSON Lines (`v` 1), read into the existing `BuildProgress` and `BuildClock`, so the bar, the stage rows, the time left and the details work as before. - Compiled and retried units count as files compiled. - `shaders_not_prepared` skips the shaders' row and says why. - `error` keeps its code. Another version's event, an unknown type or an unknown field is passed over. - The warnings a build said are kept; the Ready page says `translation_damaged` in the launcher's words. - **Errors by code** (`Problems.FromCode`): the important codes get the launcher's own translatable texts and fixes; any other code shows the builder's own text. - `nup_moved`/`nup_missing`/`game_not_found`: *Pick the .nup again*. - `not_a_nup`, `work_folder_busy`, `game_folder_busy`, `game_files_overlap`, `dump_damaged`, the game folder's refusals, `tools_incomplete`: each has its own entry. - `unsupported_build`, the incomplete-dump codes, `disk_full`, `game_running`: the existing problems, `game_running`, `game_not_found` and `disk_full` in longshot-builder's own words. - The file check maps its codes too (`LongshotBuilder.ReadCheck`). - The codes the launcher sorts are checked against the Codes table of #2286's `docs/dev/reference/build-events.md` (`tests/fixtures/longshot-builder/codes.md`, a copy that `tests/test_launcher_core.py` compares with a Longshot checkout's). - **The .nup stays where it is:** nothing is copied into the game folder. - The build's row keeps the .nup's path and `NupInPlace`. - The Ready page asks the player to keep the .nup where it is. - Play reads the folder's `longshot_builder.json`. When its .nup is gone, Play starts a rebuild of that version, and step 1 says why and asks for the .nup where it is now. - A build stopped on `nup_moved` offers to pick it again. - **Licences:** `--accept-licenses` names only the vendors whose licence the player accepted, on `build` and `update` alike (`LongshotBuilder.Licences`). - `nvidia` for DLSS's SDK; `amd` for FSR 4's runtime and `intel` for XeSS's library, both on Windows only. - If the build still stops on `license_not_accepted`, the problem page offers *Read the licence*: the prompt for the vendor the error names, and on yes the licence is kept and the build starts again. - DLSS, FSR 4 and XeSS are built by `longshot-builder`, which downloads their files itself. - **No inherited redirects:** `longshot-builder` and its `perf-report` start with every `LONGSHOT_*`, `RX_*` and `A64_*` variable of the PC removed, by prefix (`LongshotBuilder.Dropped`, `MakeGameCommand.DroppedPrefixes`). The launcher's own are then set again: `LONGSHOT_SHADER_STORE`, `LONGSHOT_MEM_LIMIT_GB`, and Intel's `RX_VK_` switches. `make_game.py`'s environment is as it was. - **The program's name in one place:** `LongshotBuilder.Name` is `longshot-builder`, its release files `longshot-builder-<v>-<system>` and its manifest likewise. Deltas are `longshot-builder-<from>-to-<v>-<system>.zst-patch`, named by the manifest. Detection is by a manifest's exact name only, never by a name holding "Builder": the old Windows app was `LongshotBuilder.exe`. - **Running game detection:** longshot-builder's game (`longshot`, `longshot.exe`, any case) is seen running; the builder is not. - Translations of the new texts in the 12 full catalogs, and the catalogs' four left-over texts removed. README: the new kind of release and keeping the .nup; ZstdSharp credited. ### What the review round changed - **Settings as flags:** `build`, `update` and `check` get `--cache` and `--builder-exe` in place of `LONGSHOT_CACHE` and `LONGSHOT_BUILDER_EXE`. DLSS uses the builder's own pinned SDK: no `--ngx-sdk` is passed, so an SDK an older launcher fetched never reaches it. - **Build memory and the shader store:** the *Build memory* setting is passed as `LONGSHOT_MEM_LIMIT_GB`; `LONGSHOT_SHADER_STORE` is kept, so the game's pipelines come from the launcher's store. - **The moved-.nup check** applies only to folders longshot-builder built last, so a stale record no longer stops Play; a .nup on a drive that is not plugged in says "connect it" instead of asking for the .nup again. - **A work folder per row** (`--work <build files>/longshot-builder/work/launcher-<row id>`), so an update finds the row's lift and objects and stays warm. Each row that exists before this update has one cold update, as its work folder is new. - **Free space:** a build of the new kind needs 3 GB where its build files go and 1 GB where the game goes, checked on both drives (4 GB when they are one drive), not make_game.py's 60 GB. - **Storage:** *Free up space* keeps the builder's tools; the old builder's files (make_game.py's leftovers, its SDKs) are pruned once nothing uses them; the delta bases have their own row; Remove everything covers every build files folder chosen before and waits for a build. - **A quarantined builder** (a file gone, emptied or changed) is installed again, and `tools_incomplete` says to restore it from the antivirus's quarantine. - **Error codes** checked against #2286's `build-events.md` (the copy and its test above); `drive_error` is the PC's, not the file's; exit 2 has its own line; `busy` is a build's lock. - **Pull request builds stop** once the newest nightly is longshot-builder's, saying why: there is no source tree to lay the pull request over yet. ## How it relates to [#257](https://git.magicbean.dev/MagicBeanDev/LongshotLauncher/pulls/257) **#257 is superseded by this pull request.** #257 had the old builder install its own tools, via `builder.json`, `make_game.py --tools-only`, a shared tools store and `--stamps` for the shader caches. A release of the new kind carries its tools inside its one file, so there is no tools stage left to move. Older releases keep the launcher's existing flow, unchanged. The one piece of #257 still needed, shader caches keyed by the builder's stamps, is here, from the manifest. #257 is not closed: that is for its author to decide. ## Testing **Tested, on Linux (CachyOS), with tests only, on the first version:** - `dotnet build LongshotLauncher.slnx`: 0 warnings. - The core checks (`tests/test_launcher_core.py`'s build and run): 2802 checks pass. - The app-level checks (`tests/launcher_app`): pass. - `LongshotBuildReleaseChecks.cs`, with a stand-in patcher and fetcher: the manifest read, and refused for each reason; the delta chosen by the bases kept; installs by full file, by delta, and from a delta that made other bytes (falls back to the full file); a base whose file changed; a full file of other bytes (refused, nothing left); a manifest SHA256SUMS does not sign; executable on Linux; the stamps; the bases a prune keeps and deletes; a release with and without a signed manifest. - `tests/launcher_app`: `ZstdPatcher` over `tests/fixtures/longshot-builder/delta`, a 2 KB delta made by the zstd CLI (`zstd -19 --patch-from=base.bin --long=27`), gives the target byte for byte; another base does not. - `LongshotBuildChecks.cs`: events from recorded synthetic lines (one whole build and one stopped on `nup_moved`); the code mapping; the check's answers; the builder chosen by kind; the command lines and their environment; the .nup record. The review round adds `BuilderStorageChecks.cs` (the work folder per row, the disk needs, Storage's rows, the bases, Remove everything, `perf-report`'s cache), the manifest's channel, the codes against `build-events.md`, the flags, Build memory, the shader store and the unplugged drive in `LongshotBuildChecks.cs`, and the running-game names in the saves checks. On the head `qsytpsmy` (after the review round), on Linux: the App builds with no warnings and the whole `python -I tests/test_launcher_core.py` passes, 2897 checks, the translation check included. **Not tested against a real Longshot release:** none ships a manifest yet; that waits on [Longshot #2286](https://git.magicbean.dev/MagicBeanDev/Longshot/pulls/2286). The launcher UI was not started with a longshot-builder release. ## Still to do - The core and app checks on this head (`qsytpsmy`), by hand. - Once a #2286 nightly is out, on Linux and on Windows (NVIDIA and AMD), by hand: - a first install (the full file) and a first build; - the next nightly, by delta, and an update of an existing row (one cold update, then warm); - a run to play; - move the .nup and press Play; unplug its drive and press Play ("connect it"); - a refused folder; - an older release, which takes the `make_game.py` path, unchanged. - Pull request builds of the new kind; a button for `share`. - Screenshots of the Ready page note and the step 1 text once it runs. This is the gate before it leaves WIP. ## Risks - **Ships with #2286's flags:** this launcher passes `--cache` and `--builder-exe`, which a `longshot-builder` from before them does not know. Release both together. - **One cold update per existing row:** a row's work folder is new, so its first update after this re-lifts and recompiles (with #2286's new keys, every player does that once anyway). - **Pull request builds** are refused once the newest nightly is longshot-builder's, until the new kind can build a pull request's source. - **Never run on Windows or against a real release:** the install, the deltas, the flags and the Storage changes have run only in checks. ## Measurements The launcher's start does not change. An update of the new kind downloads a delta, a few MB, instead of the builder and its tools (about 500 MB before; 110 to 160 MB for a full file of the new kind). Applying it reads the base into memory, about 150 MB, for a few seconds. The launcher's download grows by ZstdSharp, about 0.5 MB. `make_game.py` builds take the same path as before. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_017vw8e2TsN4jgNUFQPfkAq8
Member

Possibly related, for context:

  • PR MagicBeanDev/Longshot#2286 WIP: feat(builder): the whole builder in Rust beside the old one (longshot-build): lift, compile, game files, assets; the game reads its RomFS from the .nup — Upstream builder PR this integration depends on.
  • issue #156 Can we not have to link rom to update — Update flow retains .nup; this changes in-place ROM usage.
Possibly related, for context: - PR MagicBeanDev/Longshot#2286 WIP: feat(builder): the whole builder in Rust beside the old one (longshot-build): lift, compile, game files, assets; the game reads its RomFS from the .nup — Upstream builder PR this integration depends on. - issue #156 Can we not have to link rom to update — Update flow retains .nup; this changes in-place ROM usage.
Author
Owner

Pushed rrxtwzkz (bc55011a) and tlmmtnwt (d066db91). #2286 now ships a release as one self-contained longshot-build file per system, plus zstd deltas and a manifest, so the launcher follows:

  • Detection is the release's signed manifest, longshot-build-<v>-<system>.json, not a search inside the builder files.
  • The install uses a delta from a kept base when its SHA-256 matches, else the full file. Either way the result is checked against the manifest's SHA-256, and the file is executable on Linux.
  • Deltas are applied with ZstdSharp: patch-from (the base as the prefix), with a long window capped by one constant, LongshotBuildRelease.DeltaWindowLog.
  • Bases: each installed version's file, plus the 2 newest others per channel.
  • Shader caches are keyed by the manifest's stamps.
  • No tool folders are given to the new kind.

Tests were added for each part. The description also says #257 is superseded.

Pushed `rrxtwzkz` (bc55011a) and `tlmmtnwt` (d066db91). #2286 now ships a release as one self-contained `longshot-build` file per system, plus zstd deltas and a manifest, so the launcher follows: - **Detection** is the release's signed manifest, `longshot-build-<v>-<system>.json`, not a search inside the builder files. - **The install** uses a delta from a kept base when its SHA-256 matches, else the full file. Either way the result is checked against the manifest's SHA-256, and the file is executable on Linux. - **Deltas** are applied with ZstdSharp: patch-from (the base as the prefix), with a long window capped by one constant, `LongshotBuildRelease.DeltaWindowLog`. - **Bases:** each installed version's file, plus the 2 newest others per channel. - **Shader caches** are keyed by the manifest's `stamps`. - **No tool folders** are given to the new kind. Tests were added for each part. The description also says #257 is superseded.
Author
Owner

Pushed a new commit: performance statistics for a version of the new kind. Longshot #2286 deleted perf_report.py, so PerfReports now runs that version's own longshot-build perf-report <folder> --send --json, detached as before. Versions with perf_report.py are unchanged.

  • perf-report --json's one event is parsed into PerfReports.State, and StateCommand asks for the state without sending.
  • The tick stays written by the launcher itself, in the same longshot_perf.ini.
  • Tests read recorded event lines (tests/fixtures/longshot-build/perf-report.jsonl) and check the commands. The core checks pass: 2787.
Pushed a new commit: performance statistics for a version of the new kind. Longshot #2286 deleted `perf_report.py`, so `PerfReports` now runs that version's own `longshot-build perf-report <folder> --send --json`, detached as before. Versions with `perf_report.py` are unchanged. - `perf-report --json`'s one event is parsed into `PerfReports.State`, and `StateCommand` asks for the state without sending. - The tick stays written by the launcher itself, in the same `longshot_perf.ini`. - Tests read recorded event lines (`tests/fixtures/longshot-build/perf-report.jsonl`) and check the commands. The core checks pass: 2787.
feat(perf): a longshot-build version's performance statistics sent by its longshot-build perf-report, not perf_report.py
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 8s
dd2dcdebde
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_017vw8e2TsN4jgNUFQPfkAq8
HumanBean force-pushed feat/longshot-build from b9c5d940ec
Some checks failed
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Has been cancelled
to a78d73f1ae
Some checks failed
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Failing after 44s
2026-11-23 15:38:34 +00:00
Compare
Author
Owner

Pushed tsqkuxnn (a78d73f1). It fixes two problems with how longshot-build is started:

  • Licences: the launcher never passed --accept-licenses, so longshot-build refused with license_not_accepted whenever a vendor's files had to be downloaded.
    • It now names nvidia, amd and intel from the licences the player accepted, on build and update. The existing prompts in the settings step still come first.
    • A license_not_accepted stop offers Read the licence: the prompt for the vendor the error names, and on yes the build starts again.
    • DLSS, FSR 4 and XeSS are now asked for when accepted.
  • Inherited redirects: longshot-build and its perf-report start without any of the PC's LONGSHOT_*, RX_* and A64_* variables, removed by prefix. The launcher's own (LONGSHOT_CACHE, LONGSHOT_BUILDER_EXE, an NGX SDK of its cache, Intel's RX_VK_ switches) are set again after.
    • A test checks that a stray LONGSHOT_ROOT, RX_CPM, A64_* or LONGSHOT_STORE doesn't reach the builder or perf-report, and that make_game.py's environment is unchanged.

Also in this commit:

  • The program's name is one constant, LongshotBuilder.Name (longshot-builder), with FormerName manifests still found. Detection is by a manifest's exact name only, never by a name holding "Builder".
  • Tests: recorded license_not_accepted event lines, the licences per platform, and the new and former manifest names. Core checks: 2801 pass; app-level checks pass.
  • Translations: the new texts are in the 12 full catalogs.
Pushed `tsqkuxnn` (a78d73f1). It fixes two problems with how `longshot-build` is started: - **Licences:** the launcher never passed `--accept-licenses`, so `longshot-build` refused with `license_not_accepted` whenever a vendor's files had to be downloaded. - It now names `nvidia`, `amd` and `intel` from the licences the player accepted, on `build` and `update`. The existing prompts in the settings step still come first. - A `license_not_accepted` stop offers *Read the licence*: the prompt for the vendor the error names, and on yes the build starts again. - DLSS, FSR 4 and XeSS are now asked for when accepted. - **Inherited redirects:** `longshot-build` and its `perf-report` start without any of the PC's `LONGSHOT_*`, `RX_*` and `A64_*` variables, removed by prefix. The launcher's own (`LONGSHOT_CACHE`, `LONGSHOT_BUILDER_EXE`, an NGX SDK of its cache, Intel's `RX_VK_` switches) are set again after. - A test checks that a stray `LONGSHOT_ROOT`, `RX_CPM`, `A64_*` or `LONGSHOT_STORE` doesn't reach the builder or `perf-report`, and that `make_game.py`'s environment is unchanged. Also in this commit: - **The program's name** is one constant, `LongshotBuilder.Name` (`longshot-builder`), with `FormerName` manifests still found. Detection is by a manifest's exact name only, never by a name holding "Builder". - **Tests:** recorded `license_not_accepted` event lines, the licences per platform, and the new and former manifest names. Core checks: 2801 pass; app-level checks pass. - **Translations:** the new texts are in the 12 full catalogs.
Author
Owner

Pushed a new commit: the launcher now uses Longshot #2286's rename everywhere.

  • What is renamed:
    • the program, its installed file and its release files: longshot-builder (.exe on Windows), one constant, LongshotBuilder.Name;
    • the manifest, longshot-builder-<v>-<platform>.json;
    • deltas, longshot-builder-<from>-to-<v>-<platform>.zst-patch, whose names the launcher takes from the manifest;
    • the game folder's record, longshot_builder.json;
    • the launcher's cache for it, <build files folder>/longshot-builder, passed as LONGSHOT_CACHE;
    • the test fixtures' folder.
  • The old name: no release ever shipped the program as longshot-build, so support for that name is removed. A test checks that a manifest under it is not taken.
  • Texts: the English texts saying "longshot-build" now say "longshot-builder". Their catalog keys and values were renamed in place. Only the program's name changed, so nothing needs translating again.
  • Not used by the launcher: the locks and the CI artifact names. Nothing in the launcher looks for the builder's processes by name.
  • Tests: core checks 2802 pass; app-level checks pass.
Pushed a new commit: the launcher now uses Longshot #2286's rename everywhere. - **What is renamed:** - the program, its installed file and its release files: `longshot-builder` (`.exe` on Windows), one constant, `LongshotBuilder.Name`; - the manifest, `longshot-builder-<v>-<platform>.json`; - deltas, `longshot-builder-<from>-to-<v>-<platform>.zst-patch`, whose names the launcher takes from the manifest; - the game folder's record, `longshot_builder.json`; - the launcher's cache for it, `<build files folder>/longshot-builder`, passed as `LONGSHOT_CACHE`; - the test fixtures' folder. - **The old name:** no release ever shipped the program as `longshot-build`, so support for that name is removed. A test checks that a manifest under it is not taken. - **Texts:** the English texts saying "longshot-build" now say "longshot-builder". Their catalog keys and values were renamed in place. Only the program's name changed, so nothing needs translating again. - **Not used by the launcher:** the locks and the CI artifact names. Nothing in the launcher looks for the builder's processes by name. - **Tests:** core checks 2802 pass; app-level checks pass.
refactor(build): the new builder is longshot-builder, as Longshot #2286 renamed it: its files, manifest, record, cache and texts
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 5s
00f01e9e6f
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_017vw8e2TsN4jgNUFQPfkAq8
Author
Owner

Pushed a new commit: the shader caches and the shader store are no longer deleted while a build runs.

What was wrong: Saves.Running already lowercases the process names before mapping them, so Windows' Longshot.exe and Linux's longshot (the game, and the builder's shader preparation driver) were both counted. The real gap was longshot-builder itself, which no check counted.

What changed:

  • ShaderCaches.Busy counts Longshot's game in any case, or the builder. It is used by Clear, ClearStore and the cold build, and so by Storage's Free up space.
  • The builder is detected by Saves.BuilderAmong: longshot-builder, longshot-builder.exe or longshot-builder-<v>-<platform>, in any case. It is not added to Saves.Running, so saves imports never wait for a build.
  • RemoveEverything.Run takes a building check, which the two callers in the window pass, and refuses while a build runs, the shader store included.
  • StoreFiles still counts spirv.pack.*/spirv.idx.*, so the per-user spirv.pack.programs-<stamp> and spirv.idx.programs-<stamp> go with the store. A test now pins that.

Tests: fake process lists are checked: Windows Longshot.exe, longshot-builder.exe, and LongshotLauncher.exe and LongshotBuilder.exe not busy; Linux longshot, longshot-builder, a release file name and an AppImage. Remove everything is refused while a build runs and touches nothing. Core checks 2815 pass.

Pushed a new commit: the shader caches and the shader store are no longer deleted while a build runs. **What was wrong:** `Saves.Running` already lowercases the process names before mapping them, so Windows' `Longshot.exe` and Linux's `longshot` (the game, and the builder's shader preparation driver) were both counted. The real gap was `longshot-builder` itself, which no check counted. **What changed:** - `ShaderCaches.Busy` counts Longshot's game in any case, or the builder. It is used by `Clear`, `ClearStore` and the cold build, and so by Storage's Free up space. - The builder is detected by `Saves.BuilderAmong`: `longshot-builder`, `longshot-builder.exe` or `longshot-builder-<v>-<platform>`, in any case. It is not added to `Saves.Running`, so saves imports never wait for a build. - `RemoveEverything.Run` takes a `building` check, which the two callers in the window pass, and refuses while a build runs, the shader store included. - `StoreFiles` still counts `spirv.pack.*`/`spirv.idx.*`, so the per-user `spirv.pack.programs-<stamp>` and `spirv.idx.programs-<stamp>` go with the store. A test now pins that. **Tests:** fake process lists are checked: Windows `Longshot.exe`, `longshot-builder.exe`, and `LongshotLauncher.exe` and `LongshotBuilder.exe` not busy; Linux `longshot`, `longshot-builder`, a release file name and an AppImage. Remove everything is refused while a build runs and touches nothing. Core checks 2815 pass.
fix(storage): the shader caches and store are kept while longshot-builder runs, and Remove everything waits for a build
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 10s
15311afc35
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_017vw8e2TsN4jgNUFQPfkAq8
translation_damaged (Longshot #2286, from #2305): a unit the compiler refused came out
different when made again from the same translation, so the PC's memory, processor or
drive changed what the build made. The builder compiled it again and went on; the
launcher now keeps the warnings a build said (BuildProgress.Warnings) and the Ready page
says this one in its own words (Problems.FromWarning). The other warnings stay in the
details, as before.

The error codes checked against build-events.md: game_folder_busy (another build
writing the same game folder), game_files_overlap (the game folder and the game files
one inside the other) and dump_damaged get the launcher's words; game_folder_link,
which the builder never says, is dropped.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
The running check (Saves.RunningFrom) already compares the process name case-
insensitively: Windows' image name with .exe taken off, Linux's comm and argv[0]'s file
name, lowercased against the known names. So longshot-builder's game folder, which runs
longshot (Linux) and longshot.exe (Windows), is found as the 2.x Builder's Longshot.exe
was, and longshot-builder never counts as the game. These checks pin that for both
names on both systems.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
Longshot #2286 (xlkopyst, "a launcher's build settings are flags") takes them on every
command, a flag winning over LONGSHOT_CACHE, LONGSHOT_BUILDER_EXE and LONGSHOT_NGX_SDK,
which it reads for one more release. build, update and check now pass --cache (the
build files folder's longshot-builder/) and --builder-exe (the launcher), and a build
with DLSS --ngx-sdk when an earlier build fetched the SDK, in place of the three
variables. The environment scrub stays: every LONGSHOT_, RX_ and A64_ variable of the
PC is dropped, so a stray one of the three never reaches the builder either.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
chore(lang): the catalogs' left-over texts removed
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 15s
727613930b
Twelve catalogs (de, es, fr, it, ja, ko, nl, pl, pt-BR, ru, zh-Hans, zh-Hant) still
held four texts the launcher no longer shows ("Details" and three about the old
folder layout), which scripts/translations.py refuses. Only those entries are taken
out; every other line is as it was.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
On a PC that builds with longshot-builder only, Faster updates' Remove all removed work/ and store/ but toasted
"Some storage targets were missing or could not be removed (1 skipped, 0 failed)": the older builds' code item
names make_game.py's obj-store beside longshot-builder's store, and a part that is not there counted as skipped.
Only the parts there are removed now; with none there (the work went since the measure) it is still said as skipped.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
Every longshot-builder run (build, update, check) is given LONGSHOT_DATA = <launcher home>/builder-data
(LauncherHome.BuilderData; the builder has no --data flag). Its notes of the licences accepted per game
folder (licenses/<id>.json, written for every folder built, even with none accepted) no longer land in the
builder's default data folder ($XDG_DATA_HOME/longshot-builder, %LOCALAPPDATA%\Longshot\Builder-data),
where Remove everything left them and where they mixed with a developer's own runs. Remove everything
now takes them with the launcher's home; a developer's notes in the default folder are never touched.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
fix(ready): an update under a minute says its seconds ("in 5 s"), not "in 1 min"
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 5s
b5174f3e57
The ready page's line moves to Core (Durations.Done), in seconds under a minute and in whole minutes after,
with the three new texts in the twelve catalogs, each in its catalog's own wording for seconds.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
fix(builder): the second review of #259: codes recopied, no hash or prune on the window's thread, 5 GB gate, old work folders let go
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 4s
253f78b41c
- tests/fixtures/longshot-builder/codes.md: build-events.md's Codes table copied again (Longshot 3ca9b9d8): usage,
  nup_path_too_long, nup_damaged, not_the_same_nup, and the warnings upscaler_dropped and romfs_folder_kept.
  FileCodes takes the three new game files' codes; nup_damaged and nup_path_too_long get the launcher's own words
  (pick another copy; move the .nup to a shorter path), in the 12 catalogs.
- Toolchains.IsInstalled and Kinds check the builder's size only (Find(tag, hash: false)): the window's thread asks
  them. ToolsSource.EnsureAsync's Find still hashes it, and the install seeds the hash cache with the manifest's
  SHA-256, so that first Find reads nothing again. PruneTools' file work runs in a Task.Run, under the installs'
  exclusion (ToolsPrefetch.CleanStaging).
- LongshotBuilder.GameLockFile's comment: build (update), image and index take the game lock, not prepare.
- Disk: 4 GB on the work drive (the ~0.6 GB a release's first run unpacks into --cache with it) and 1 GB on the
  game's, build.md's about 5 GB; disk_full's words and translations say so.
- A saved change of the build files folder (Settings, step 2) deletes the launcher's work/launcher-* folders in the
  old one (Disk.LeaveLongshotWork), off the window's thread, skipping one whose longshot-builder.lock is held or that
  the launcher's own build runs in.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
fix(builder): romfs_folder_theirs in the launcher's words: a romfs folder of the player's in the game folder
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 5s
e2f011441e
Longshot #2286 (02386f32) added the builder error code romfs_folder_theirs: a build from a dump refuses a game folder
holding a non-empty romfs folder it did not make. The launcher says it as a folder's problem (FolderRefused): move
that romfs folder out of the game's folder, or build to another folder. Translated in the 12 catalogs; the codes
table recopied from build-events.md at 02386f32.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
feat(builder): stack longshot-builder's deltas when no single one fits
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 6s
66da82766e
When no delta of the new release starts from a file this PC keeps, the
launcher looks for a chain: walking back from the release's manifest
through the releases its deltas start from (the channel's last 10, and
the latest stable for a nightly), each manifest checked through its
release's signed SHA256SUMS. The fewest hops win, then the smallest
download; at most 3 hops, and only when smaller than the full file.
Each file in between is checked against its release's manifest and
deleted once used; any failure downloads the full file, as before.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
When Play finds a longshot-builder game's .nup gone from where it was built from, step 1 asks
for it where it is now. Picked (or found under its name), Next now runs
`longshot-builder index --game <new> --out <game folder> --json` over step 1 (seconds,
cancellable; index takes the game folder's lock itself) and the row and the game-file setting
name the new place. Only not_the_same_nup (another .nup) goes on to the full build.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
feat(builder): stack up to 5 longshot-builder deltas, looking back 20 releases
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 6s
0807dfb330
MaxHops goes from 3 to 5. Each release has deltas from its channel's last 5 (DeltasFrom), so a
five-hop chain's farthest intermediate is 20 releases back: LookBackReleases is now
DeltasFrom * (MaxHops - 1) = 20, and the manifests-read cap (LookBackReleases + 1, with the
latest stable) follows it to 21. Tests: a five-hop chain through four releases, six refused.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
The launcher's side of Longshot #2286's model, with the profile basics of launcher #268 ported:

- profiles/<id>/: profile.json v1 (name, color, game, upscalers, version, start_slot, last_played,
  copy_of; unknown keys kept, a newer format never written over), settings.ini, saves/ (save/,
  save-work/). LauncherProfiles: new, rename, copy, delete into the backups, a save copied or moved
  between profiles; its own DefaultId and DefaultName, no ModsProfiles and no mods.
- versions/<v>/: the release's longshot-builder as Longshot.exe (Longshot.x86_64), hard-linked or
  copied from the installed tools (the delta stacking unchanged), its game in builds/default. A
  build of such a release is `Longshot.exe build --profile <p> --game <nup>`, an update `update
  --profile <p>`, naming the launcher (--launcher longshot-launcher=<it>). Play is `Longshot.exe
  --profile <p> --output json --cache <the launcher's>`; its exits 120, 121 and 122 are said on
  Home.
- Every longshot-builder command takes --output json (#2286 made --json a usage error); its events
  are read as before. The record is longshot_build.json, the older names read too.
- features= in longshot_version.txt: start_slot (HOS_START_SLOT) and save_dir (HOS_SAVE_DIR, its
  exit 3 refusal said as the profile's error) for make_game.py's versions that take them.
- The move, once, originals kept: profiles/default (and any profile an earlier launcher listed)
  made with the --user folder's save/ and save-work/, its longshot_options.ini as settings.ini, the
  game copy and upscalers of the version played last; then each version longshot-builder built in
  a folder of its own copied into versions/<v>/builds/default (not its user/), its row moved there.
- The moved-.nup index flow and the update's work folder (the row's id) keep working.

Ported from launcher #268 (mods/launcher-pr), so #268 can drop these on rebase:
twmtqsot (StartSlot), soykoypx (LauncherProfiles, SaveDir, the profile's saves home; not ModRepo
or the mods), yptmuxux, rsqoqtmz, llrrkzvp (SaveDir's refusal; not the mods' data), kowpxnlp
(ProfileStore, ProfileFile without Mods, BuilderVersions, ProfileMigration's settings and saves
part, ProfileModelChecks).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
- The title bar's profile chip: who is playing, a menu to switch, Manage profiles… and New profile….
- The Profiles page: a card per profile (its saves, its game copy and upscalers), Play as, Rename,
  Colour, Copy, Delete (into the backups, asked first).
- Who's playing?: the first page with two or more profiles.
- Saves: the current profile's; a slot's Copy or move… to another profile, and Start here (the
  profile's start_slot).
- Play of an older version without save_dir, for a profile other than the default, asks first
  (play on the shared saves, update the version, or Cancel).
- The new texts in the twelve full catalogs; the one left over dropped.

Home stays #259's: it already is the versions' page that #268's Versions page took Home's list
into, so no separate Versions page. #268's front page, its Save picker and the Mods page stay there.

Ported from launcher #268 (mods/launcher-pr), so #268 can drop these on rebase: uulmyltk (the chip,
Who's playing?, Profiles, the Saves page's moves; not its Mods counts), ozyrzlpn (the shared saves
question), and the i18n of wvlwxkmo, ulqtlpwn, qpyrlsst and yuroxqxo for these texts.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
docs(saves): profiles, version folders, Play with --profile and the move, once
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 15s
be56f4155b
Ported from launcher #268's wtonqxvk and lnpnywnx (their profiles part; not the mods or mod
repositories), so #268 can drop it on rebase.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
The launcher's non-mod UI work of #268: MagicBean's brand as accents over the cool dark palette (leaf green for Play and
the Go states, gold for focus and kickers, lime, the four stripes at the window's top, Noto Sans Black for a page's big
title), one round title bar style on every platform with Close red under the pointer, the window at 1200x760 fitted to a
smaller screen, a Back arrow left of each page's title that B and Esc press, c:Pad.Scope and c:Pad.First for a
controller's first press, sentence-case labels, Settings in sections with a fixed header, the crash page's Back, the
dropdowns in the launcher's colours, a page's scroll to the window's foot, "versions" not "instances", the NFC page
translated, longshot_fsr4_pipelines.bin a shader cache, and a pull request's tools taking every path its release ships.
A few orange (#E07F3E) alphas #268 left on blue fills are the Brand blue's again.

Ported from launcher #268 (mods/launcher-pr), so #268 can drop these on rebase (their Mods page parts stay there):
tymqntso, rusuorqz, rtnuuluu (the window), zoqsuptp, xpwwktxx, syqssssk, oqvtrntn, younswsv, twwvrlon, psukqxls,
yrwvzwkt, snuoozrk, vusookrr, uzymwmlx, kqvnzlzl, xzmwkqtk, kzwvxtuk, nkplswrx, tyzonqnw, kmtqxurs (the path box),
rummwqrk (c:Pad.Scope), ulsopotx (c:Pad.First), qrmkmosu, wsuvussx, tkplksvn (Toolchains and the doc), uswrmmzn.
Their texts' translations come with the Home commit after this one.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
Gaps of the first port:
- (a) after an update into another version folder, the one it left is kept for going back to it
  (Settings.RollbackVersion) and the older ones nothing uses are deleted: no row plays them, no profile.json names one as
  its version, no game or builder runs, no user data in them (BuilderVersions.Prunable, LauncherService.PruneVersions;
  also at the launcher's start, after the move to version folders, never into a folder being copied).
- (b) deleting a builder's version deletes its whole versions/<v>/ folder, Longshot.exe too, once its game folder is
  gone; never one holding saves, a profile (the builder's own profile/), a profile.json or settings.ini, a link, or another
  row's game folder, and never while a game runs (BuilderVersions.WhyNotDelete, Delete).
- (c) Play's --cache is the builds' (the build files folder's longshot-builder), checked. The move to version folders
  now carries the row's work folder (launcher-<id>) to the work folder the builder takes by itself for the new game folder
  (layout.rs work_of: <name>-<SHA-1 of its path, 10 hex>), so the first Play's update (NoStamp: the copied record has no
  profile stamp, which only the builder can write) starts from the last build's lift and objects and the shared stores;
  and a version folder's build takes no --work, so the launcher's updates and Play's share that one work folder.

And from Longshot #2286: --launcher longshot-launcher=<the launcher> goes on Play (the builder hands it to the game as
LONGSHOT_LAUNCHER); build and update no longer take it.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
feat(home): Home a front page with Version and Save pickers and one button; a Versions tab with Add version
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 5s
cc1f86cd48
Home plays; the Versions tab manages. Home is the band, the Version picker (the versions on this PC, a builder's version
folders among them, then Manage versions… and New version…), the Save slot picker (the current profile's slots,
profiles/<p>/saves/save/<uid>/slot_NN, the newest picked, New game with none, Manage saves…; the pick is profile.json's
start_slot; hidden, with one quiet line, for a version whose stamp's features= lacks start_slot, as Longshot's game folder
does today) and one button: Build, Build it again, Play, and Update beside Play when there is one. One status line under
it only when it must be said (a Play that failed, the shared saves, no version yet). The tabs: Home, Saves, Versions,
Settings (Storage and NFC reached from Settings).

The Versions tab: a card per version (state, size, Set as default, Open folder, Delete), Add a build folder…, Check for
updates, and Add version…, a dialog (new, from the main session's rule): Stable and Nightly, each with its newest and
its older versions in the list; Advanced, closed until opened: Build main (main's newest commit, main-<sha8>) and Build a
pull request (Beanstalk's list, WIP/draft ones listed and buildable, marked WIP). A pull request keeps its warnings,
which now say for every one that its code runs with the player's rights, and that a WIP one may not build; main has a
lighter "untested, not a release" note. Both go through SourceBuilds.EnsureAsync (tags pr-<n>-<sha8>, main-<sha8>):
a pull request as today (PullRequestSource), main refused with a clear "not yet" until longshot-builder's from-source
is wired there.

Screenshots (tools/screenshots): Home's states and pickers on a builder's version, the Versions tab, Add version closed
and open, the profiles' scenes; the Mods scenes and their made-up mods left out. Docs: README, controller, saves. The
new texts in all twelve full catalogs (German complete), and #268's translations of the texts ported.

Ported from launcher #268 (mods/launcher-pr), so #268 can drop these on rebase (their mods parts stay there):
wvtpwnyy, wwvuqvlk, qxpkrkss, kwwukmrx, kxyqzuyl, qnuwprup (not its LastPlayed setting), lruksypk, opptzloq, ywmuxmkl
(not its Mods text), kmtqxurs (Home's part), tlxruxxy, mktvkwkp, smmqxxmr, qstmnowu, smunmmpu, nsqoqouz, uuzssqwk,
yuukzppx, rtnuuluu (its screenshots part), runwyrxs and lzsmlpxp (the profiles' scenes; not mod-repos), ooupwwyr,
qnovyvqs (the non-mod texts), soykoypx (SaveArchive: a .zip imported into the profile's saves), yptmuxux (Problems: a
refused save folder is no crash), and the shared-saves checks of ozyrzlpn and uulmyltk's PadChecks, adapted.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
HumanBean force-pushed feat/longshot-build from cc1f86cd48
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 5s
to 5f48fca885
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 10s
2026-11-24 17:57:20 +00:00
Compare
refactor(profiles): profiles are their folders: the only list is profiles/*/profile.json, read each time
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 5s
873ecb9c7b
The launcher's settings keep only which profile is current. A profile's name, colour,
start slot and last played are its profile.json's, written when they change (rename edits
name; the folder name stays the id; copy copies the folder; delete moves it to the backups).
A folder whose profile.json is missing or unreadable is listed as damaged, not dropped,
and can still be deleted. Two launchers on the same profiles see the same list.

A settings.json that still lists profiles has them moved into each profile.json (what the
file holds stays) and removed from settings.json, the old file kept as
settings.json.before-profile-folders.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
HumanBean changed title from WIP: feat(build): build a release that ships longshot-build with it, the .nup kept in place; older releases as before to WIP: feat(build)!: Longshot Launcher 2: versions built by longshot-builder, profiles and saves, a clean break from make_game.py releases 2026-11-24 18:34:17 +00:00
A clean break with make_game.py, Longshot's old builder. The launcher builds, updates and plays only versions of
longshot-builder; a version built with make_game.py stays listed, its card saying "Not supported by this launcher: use
the stable Longshot Launcher to play it" with Switch to the stable launcher (Settings' Launcher updates). It is not
played, built or updated here, and never deleted unless the player deletes it (OldVersions). A release with no
longshot-builder manifest is refused the same way. The one-time moves stay: saves and settings into profiles, older game
folders into version folders.

Removed: the make_game.py builder (MakeGameBuilder, IBuilder, BuilderKind), its command lines (MakeGameCommand.For,
FsrBuilds, XessBuilds, ForCheck), its @@ line protocol and shader ETA, its game-files check, the old toolchains (the
zip/AppImage install, tools.lock and its parts, ToolsLock.cs, the Python and make_game paths), the pull request source
over a nightly's tools (PullRequestSource.cs; SourceBuilds is the one entry for pull requests and main), the
LONGSHOT_ROMFS_FROM link of game files, the antivirus and long-folder problems, the translator/compiler shader stamps,
the save editor's tools lookup, and the texts, tests and docs only they used.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
feat(launcher): switching nightly to stable offers to replace this launcher with the stable one
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 7s
56672d05c3
Settings' Launcher updates from nightly to stable, and an old version's Switch to the stable launcher, open the offer:
the stable channel's newest launcher downloaded, checked and put in place as an update is (the self-update path,
ReplaceLauncherAsync), then started. Before that it offers to copy the current profile's saves (save, save-work) back to
the --user folder the stable launcher reads, the one the move to profiles copied them from: a copy, the profile keeps
its own, and a newer file there is kept unless the player ticks Replace the newer files too (StableSwitch,
SavesCopyBack). It says versions of the new builder won't run in the stable launcher. Cancel leaves the channel, the
saves and the launcher as they were; a failed replacement puts the channel back.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_016o1k1SkKpc592GgxftLP8o
All checks were successful
CI / Compile and test (pull_request) Has been skipped
CI / Conventional Commit title (pull_request) Successful in 7s
This pull request is marked as a work in progress.
This branch is out-of-date with the base branch
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'feat/longshot-build:HumanBean-feat/longshot-build'
git switch 'HumanBean-feat/longshot-build'
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
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
MagicBeanDev/LongshotLauncher!259
No description provided.