Repository navigation
Setups load fast and stay current; every page shows its layout while loading - #307
Merged
Merged
Conversation
In a dash version, an inherited widget the version removed shows as an opaque dashed placeholder with "Bring back". Putting another widget where it sat left the new widget hidden behind that placeholder. The placeholder now only shows while its cells are free; the removal still counts in the scope strip and Reset still undoes it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every page drew a flat grey block while its data arrived, and the Setups page could sit on it for a long time. Each page now draws its own layout in static placeholder shapes (tool row, cards, rows, tiles, charts as an empty plot with gridlines), so it reads as loading and doesn't jump when the data lands. No shimmer or pulse: the shapes never repaint. The shapes live in shell/Skeleton.tsx so new pages build theirs from the same parts. The preview gains loading=1, which keeps every page on its loader for screenshots. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Setups page could load for a long time: after every app start, Sprint parsed every setup file in the game folder and every stored version (930 JSON files, 19 MB in the dev data) before the list appeared. A small index file (setup-index.json) now remembers each setup's path, timestamp, current version and car, plus the versions without their values. A restart reads only the setups the game changed, and a version's values only when it is opened. The index is a cache: missing or unreadable, it is rebuilt from the stored versions. The page also only reloaded when opened, so a setup saved in the game while Sprint ran for hours never showed. A watcher on the game's setup folder now looks at it when the game writes, and a revision in the app state makes the list, an open setup and a comparison fetch again. The first look runs in the background at start, so the list is ready early. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
From review. A setup version whose snapshot failed to save (disk full, a locked file) was still indexed, so the setup would not open and never recovered after a restart. A failed save now leaves the file unindexed so the next look retries, and a version whose stored values are gone is read from the game's file again when opened. Also: an index that parses but lacks fields is rebuilt instead of breaking the page; a folder watcher that errs is replaced on the next visit; loading tiles no longer react to hover; the unused .skeleton rule is gone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Main's export keeps each version's original file in its snapshot and fills it in for versions captured before. The index now records whether a version has its original, so that backfill still happens without loading every snapshot, and export loads only the version it writes out. The Setups page keeps main's notices and export alongside the live refresh and its loader; the preview's loading=1 also holds capture mode. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CI failed on Rgb565Tests.FusedCompositionIsAllocationFree, which asserts that composing frames allocates nothing on its thread. Locally it failed in about 1 of 10 runs, and only alongside the new watcher test, which polled with await Task.Delay on xUnit's shared worker threads. Waiting with SpinWait.SpinUntil on the test's own thread instead: 0 of 20 runs failed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Setups page could sit on a grey block for a long time, and never showed a setup saved in the game while Sprint was running.
Setups load from an index
After every start, Sprint parsed every setup file in the game folder and every stored version (930 JSON files, 19 MB in the dev data) before the list appeared. A small cache,
setup-index.json, now remembers each setup's path, timestamp, current version and car, plus the versions without their values. A restart reads only the setups the game changed; a version's values are read only when it is opened. Missing, unreadable or half-written, the index is rebuilt from the stored versions. A version whose stored values are gone is read from the game's file again.Setups stay current
A watcher on the game's setup folder looks at it when the game writes a setup. A
setupsRevisionin/api/statethen makes the list, an open setup and a comparison fetch again. The first look runs in the background at start, so the list is ready before the page is opened.Loaders shaped like the page
Every page drew one grey block while loading. Each now draws its own layout in static placeholder shapes (
shell/Skeleton.tsx): tool row, cards, rows, tiles, and charts as an empty plot with gridlines. No shimmer or pulse. The preview gainsloading=1to screenshot them.Dash designer fix
In a dash version, the placeholder for a removed widget is opaque and hid any widget put in its spot. It now only shows while its cells are free.
Checks
dotnet build app/Sprint.Desktop.slnx -warnaserror: clean.sprint_dash.dllis built for the wrong architecture for the x86 test process. Unrelated to this change.🤖 Generated with Claude Code