WIP: feat(launcher): problems in plain words, and crashes found at the next start #48

Draft
TrashPanda wants to merge 1 commit from TrashPanda/LongshotLauncher:feat/friendly-errors into main
First-time contributor

Why

When a build stops, the launcher shows make_game.py's message as it is, and a crash leaves only a log for the player to find. This puts the common problems in plain words with the fix, and says at the next start that the game crashed. Split out of #42 so it can be reviewed and merged without the crash reporting.

What changed

  • Core: Core/Problems.cs maps make_game.py's and the game's messages to a plain headline, what to do and a fix: the antivirus removed the tools, another game version, an incomplete dump, a full drive, the build ran out of memory, a lost GPU, no mesh shaders. A crash also gets a signature (its exception code and module+offset, no folder). A message it doesn't know still shows as "make_game.py stopped", never as a wrong fix.
  • Core: CrashCheck (in Problems.cs) finds a crash in a build's last run, or the run before it, when the launcher starts. Each log is shown once (SeenCrashLogs in settings.json).
  • App: the build's problem screen uses the plain words. A new problem page (ProblemPageViewModel/ProblemPageView) says the game closed unexpectedly, shows what to do and a button to the graphics driver's page for the card's maker, and has Close.
  • Tests: tests/launcher_core/ProblemChecks.cs covers the mapping and the crash found once.

Nothing is sent anywhere: the report and sending are in #42, which builds on this.

Testing

Tested: on Linux (CachyOS, .NET 10.0.115), at c92e73d6:

  • python -I tests/test_launcher_core.py --strict: 688 checks pass.
  • dotnet build LongshotLauncher.slnx --configuration Release -p:RestoreLockedMode=true (CI's command): 0 errors, and 1 warning (TextBox.Watermark in BuildStepView.axaml), which main has too.

Not tested: the pages in the running launcher (not run yet); Windows.

Needs other testers: a Windows run with a crashed build's log in the build folder, expecting the problem page at the next start, once.

Screenshots

To come: the problem page and the build's problem screen.

Reviewer notes

#42 adds Send report on top of this branch, so merge this first; #42's diff then shrinks to the reporting alone.

## Why When a build stops, the launcher shows make_game.py's message as it is, and a crash leaves only a log for the player to find. This puts the common problems in plain words with the fix, and says at the next start that the game crashed. Split out of #42 so it can be reviewed and merged without the crash reporting. ## What changed - Core: `Core/Problems.cs` maps make_game.py's and the game's messages to a plain headline, what to do and a fix: the antivirus removed the tools, another game version, an incomplete dump, a full drive, the build ran out of memory, a lost GPU, no mesh shaders. A crash also gets a signature (its exception code and module+offset, no folder). A message it doesn't know still shows as "make_game.py stopped", never as a wrong fix. - Core: `CrashCheck` (in `Problems.cs`) finds a crash in a build's last run, or the run before it, when the launcher starts. Each log is shown once (`SeenCrashLogs` in `settings.json`). - App: the build's problem screen uses the plain words. A new problem page (`ProblemPageViewModel`/`ProblemPageView`) says the game closed unexpectedly, shows what to do and a button to the graphics driver's page for the card's maker, and has **Close**. - Tests: `tests/launcher_core/ProblemChecks.cs` covers the mapping and the crash found once. Nothing is sent anywhere: the report and sending are in #42, which builds on this. ## Testing **Tested:** on Linux (CachyOS, .NET 10.0.115), at c92e73d6: - `python -I tests/test_launcher_core.py --strict`: 688 checks pass. - `dotnet build LongshotLauncher.slnx --configuration Release -p:RestoreLockedMode=true` (CI's command): 0 errors, and 1 warning (`TextBox.Watermark` in `BuildStepView.axaml`), which `main` has too. **Not tested:** the pages in the running launcher (not run yet); Windows. **Needs other testers:** a Windows run with a crashed build's log in the build folder, expecting the problem page at the next start, once. ## Screenshots To come: the problem page and the build's problem screen. ## Reviewer notes #42 adds Send report on top of this branch, so merge this first; #42's diff then shrinks to the reporting alone.
feat(launcher): problems in plain words, and crashes found at the next start
Some checks are pending
CI / Compile and test (pull_request) Blocked by required conditions
CI / Conventional Commit title (pull_request) Blocked by required conditions
c92e73d664
A build that stops says what went wrong in a player's words (the antivirus
removed the build tools, another game version, an incomplete dump, a full
drive, out of memory), from make_game.py's last message (Core/Problems.cs);
a message it doesn't know still shows as "make_game.py stopped", never as
a wrong fix.

At the next start, the launcher reads each build's last run log
(CrashCheck): a crash, a lost device or no mesh shaders opens a page that
says so, with the graphics driver's download page for the card's maker.
Each crashed log is shown once (SeenCrashLogs in settings.json).

Assisted-by: Claude Opus 5.5
Some checks are pending
CI / Compile and test (pull_request) Blocked by required conditions
CI / Conventional Commit title (pull_request) Blocked by required conditions
This pull request is marked as a work in progress.
Some workflows are waiting to be reviewed.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u 'feat/friendly-errors:TrashPanda-feat/friendly-errors'
git switch 'TrashPanda-feat/friendly-errors'
Sign in to join this conversation.
No reviewers
No milestone
No project
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.

Dependencies

No dependencies set

Reference
MagicBeanDev/LongshotLauncher!48
No description provided.