0.9.15: a calmer editor, templates after the first game, clearer buttons, and safety fixes from the reviews #174

Merged
ethan-hann merged 39 commits from integration-0915 into main 2026-10-26 09:06:59 -05:00
Owner

Closes #156, #157, #158, #162, #163, #164, #165 and #166.

A UX review, a security review and a resilience review (han review agents) found the issues this release fixes.

UI: the game editor shows each warning only where it applies and keeps the optional fields under More settings, with explanations behind question buttons (#156). Add a game searches the built-in templates as the player types, offers Pick from the game list, and template notes now come from the catalog; the blanket Steam Cloud sentence left all 249 notes (#157). History says Go back and play / Go back without playing, a profile that is not loaded says Switch and play, Take a snapshot sits by the tabs, and profile notes show (#158).

Core: a game folder is pinned and rechecked right before every step that deletes or replaces files, and held open on Windows, so a folder swapped in between is refused (#162, D57). Git writes are flushed (core.fsync, file by file on every system) and a damaged index is rebuilt beside the real one from the last snapshot by the game-lock holder (#163, D58). A snapshot counts the size it will add before writing, temp packs left by a stopped snapshot no longer block the next, and a launch checks the saves folder before switching the install (#164). Gits are tied to the app with a Windows job object and recorded in a per-user note, so the next start ends leftovers before cleaning locks (#165, D59). An unreadable switch note fails closed with a way out (#166).

Every issue was implemented test-first, reviewed by a separate reviewer and fixed; the reds are in the commit messages. The full Windows gate passed locally (15,918 tests); the WSL Linux gate passed apart from 9p retries and one test that looked for packages in the wrong folder, fixed in b64fd36. Follow-ups are filed as #167 to #173.

Closes #156, #157, #158, #162, #163, #164, #165 and #166. A UX review, a security review and a resilience review (han review agents) found the issues this release fixes. UI: the game editor shows each warning only where it applies and keeps the optional fields under More settings, with explanations behind question buttons (#156). Add a game searches the built-in templates as the player types, offers Pick from the game list, and template notes now come from the catalog; the blanket Steam Cloud sentence left all 249 notes (#157). History says Go back and play / Go back without playing, a profile that is not loaded says Switch and play, Take a snapshot sits by the tabs, and profile notes show (#158). Core: a game folder is pinned and rechecked right before every step that deletes or replaces files, and held open on Windows, so a folder swapped in between is refused (#162, D57). Git writes are flushed (core.fsync, file by file on every system) and a damaged index is rebuilt beside the real one from the last snapshot by the game-lock holder (#163, D58). A snapshot counts the size it will add before writing, temp packs left by a stopped snapshot no longer block the next, and a launch checks the saves folder before switching the install (#164). Gits are tied to the app with a Windows job object and recorded in a per-user note, so the next start ends leftovers before cleaning locks (#165, D59). An unreadable switch note fails closed with a way out (#166). Every issue was implemented test-first, reviewed by a separate reviewer and fixed; the reds are in the commit messages. The full Windows gate passed locally (15,918 tests); the WSL Linux gate passed apart from 9p retries and one test that looked for packages in the wrong folder, fixed in b64fd36. Follow-ups are filed as #167 to #173.
The editor showed every warning and explanation at once. Now:
- The Steam update warning shows only when Through Steam is chosen, so it never sits beside the Linux note that prefers Through Steam.
- Cloud saves On shows a warning callout under the saves folder. Unknown becomes a "Does my store sync saves?" button beside the saves folder that reveals the old text. Off shows nothing.
- The anti-cheat line, the leave-out rule explanations and the stop-detection, mod-folder and Steam app id helpers sit behind question buttons. One line about not matching the saves stays visible.
- A "More settings" toggle holds the leave-out rules, stop detection, mod folders, extra options and the Steam app id. It is closed on Add a game, open for an existing game that uses any of them, and opens by itself when the Steam app id is refused.
- A new game started from a template or a definition file shows its notes as an info line. A saved game's own notes stay hidden.

Observed reds (assertion failures before the change):
- Cloud_saves_unknown_show_the_question_and_no_warning: Assert.False() Failure, Expected False, Actual True (HasCloudSavesNote)
- A_game_that_is_not_saved_yet_shows_the_question_without_asking_the_store: Assert.False() Failure, Expected False, Actual True
- A_failed_check_shows_the_question: Assert.False() Failure
- An_open_cloud_answer_closes_when_the_store_gives_a_real_answer: Assert.False() Failure
- More_settings_is_open_when_the_edited_game_has_rules_and_mod_folders_set and the six single-setting cases: Assert.True() Failure, Expected True, Actual False
- More_settings_opens_by_itself_when_the_Steam_app_id_is_refused: Assert.True() Failure
- A_game_added_from_a_template_shows_the_templates_notes: Assert.True() Failure
- The_Steam_warning_shows_only_when_Through_Steam_is_chosen: Assert.False() Failure, Expected False, Actual True
- On_Linux_the_note_that_prefers_Through_Steam_and_the_Steam_warning_never_show_together: Assert.False() Failure
- The_anti_cheat_line_sits_behind_a_question_button: Assert.False() Failure (line visible before any click)
- The_stop_detection_mod_folder_and_app_id_helpers_sit_behind_When_do_I_need_this: Expected 3, Actual 0
- The_rules_explanations_sit_behind_a_question_button_with_one_line_always_shown, Cloud_saves_on_show_a_warning_callout..., More_settings_is_closed_on_Add_a_game_and_opens_with_its_toggle, More_settings_comes_after_the_core_fields_in_reading_order, Tab_moves_from_the_saves_folder..., A_game_without_template_notes_shows_no_info_line, A_template_game_shows_its_notes_as_an_info_line, More_settings_is_open_when_editing...: Assert.True/NotNull failures
Tests that passed on their first run (Cloud Off shows nothing, More settings closed on Add and for a game with none set, template notes never shown for a saved game) were mutation checked: forcing the section open, dropping the Off case and dropping the creating check each failed the matching tests.

Tests pinned to the old layout were rewritten or removed where the new tests cover them. The Add a game doc screenshot is regenerated.
History: "Go back to this" is now "Go back and play" and "Switch to this snapshot" is
"Go back without playing" (cards, timeline entries and save rows; the save row's
button used to say just "Go back"). The view model already matched: the first begins
a launch, the second calls BeginSwitchAsync, so only the wording changed. Help text
and the tour use the new names.

Games: a "Take a snapshot" header button for the loaded profile, off while a job for
the game runs exactly as the row menu entry is; it drops its words below a wider
header than the other buttons. Profile notes show as a secondary line (two lines at
most, full text in a tip, hidden when blank). Play on a profile that is not loaded
reads "Switch and play"; the action column grew to fit it.

Observed reds (assertion failures):
- GamesScreenViewModelTests.Play_says_it_switches_first_on_a_profile_that_is_not_loaded:
  Expected "Switch and play", Actual "Play"
- GamesScreenViewModelTests.The_running_profile_says_so_and_nothing_can_be_played_meanwhile:
  Expected "Switch and play", Actual "Play"
- GamesScreenViewModelTests.A_profiles_notes_show_trimmed_and_blank_notes_show_nothing:
  Assert.True() Expected True, Actual False
- GamesScreenViewModelTests.The_snapshot_button_drops_its_words_before_the_other_header_buttons
  (760/850 sidebar, 600 library): Expected True, Actual False
- GamesScreenActionsTests.The_header_snapshot_button_captures_the_loaded_profile and
  ..._is_off_while_the_game_has_a_session_as_the_menu_entry_is: Assert.True() Expected True, Actual False
- HistoryScreenViewModelTests: Expected "Go back without playing: Cleared Blackreach",
  Actual "Switch to this snapshot: Cleared Blackreach" (and the Go back and play names)
- HistoryScreenViewTests (6 tests): the buttons labelled "Go back and play" were not found (Expected 7, Actual 0)
Mutation checks: header-hidden test fails when LoadedProfile ignores SnapshotNow; the
notes view test fails without the HasNotes visibility binding.

Doc screenshots regenerated; the seed gives the Modded profile a note.
- The nudge for a game that starts through a link (why SavePoint needs the program name, and the "Use X" button) sits in the launch column under how to start the game, so it shows while More settings is closed. The stop-detection field stays in More settings, and the button still fills it.
- A question button can carry its own accessible name. The three "When do I need this?" buttons now name their section, so a screen reader hears them apart. The visible text is unchanged.

Observed reds (assertion failures before the change):
- The_process_name_nudge_shows_under_how_to_start_while_More_settings_is_closed_and_its_button_fills_the_field: Assert.True() Failure, Expected True, Actual False (row hidden inside the closed section)
- The_three_When_do_I_need_this_buttons_have_different_accessible_names_and_the_same_text: Strings differ, Expected "When do I need this? Knowing when you've stopped p...", Actual "When do I need this?"
- The_When_do_I_need_this_buttons_carry_their_own_automation_names: Expected 3, Actual 1 distinct name

The doc screenshots were regenerated and are byte-identical, so none changed.
Templates could only be picked on the first-run screen. Now:
- The Add a game Name field lists matching templates after 2 typed letters
  (up to 8, shared word matching with the template picker). Picking one names
  the game and fills only the details still empty, adds the template's notes
  when the form has none, and marks its ignore rules as supplied, the same
  draft first run uses. Nothing shows while editing a game or when the form
  was filled from a file or template.
- The header has "Pick from the game list", which opens the first-run
  picker; a template applies the same way and "Open a file" is Import.
- "Add games from your libraries" gets a note about Epic, Game Pass and
  manual installs plus a "Pick from the game list" button that closes the
  checklist and opens the template picker.
- 249 template notes no longer say to turn off Steam Cloud while SavePoint
  manages the game; the editor now checks cloud saves per game. Notes that
  held only that sentence lose the notes property.

Observed reds (assertion failures) before the code:
- ShippedTemplatesTests.Notes_say_nothing_about_cloud_saves: "249 notes
  mention cloud saves, such as: 007-first-light, a-plague-tale-requiem, ..."
- GameEditorTemplateTests: Typing_two_letters_of_a_name_lists_the_templates_that_match
  (Assert.Contains: item not found), The_list_is_short_however_many_templates_match
  (Assert.InRange: actual 0), Picking_a_match_names_the_game_and_fills_the_details_still_empty
  (Assert.Single: no matching item), Escape_closes_the_list_until_the_name_changes_again
  (Assert.True: expected True, actual False), header picker tests
  (Assert.Single: collection was empty, no picker shown).
- LibraryPickerDialogViewModelTests: pointer closes the checklist
  (Assert.True: expected True, actual False), pointer names the stores
  (Assert.Contains: sub-string not found).
- LibraryImportFlowTests and ShellLibraryImportTests: pointer tests timed out
  waiting for the flow or the template picker.
Tests that passed first run (one letter, clearing, editing, opened from a
template, header hidden while editing) were mutation-checked by removing the
creating, filling and length guards: four failed as expected.

Doc screenshot regenerated: docs/images/add-game.png.
A switch, discard or clean approved the folder once and then ran several git
processes before the one that deletes or overwrites files. Another account
that can write to the folder's parent could swap the folder for a junction or
symlink in between, and git would work through it.

- The folder is pinned (path with links followed, plus its file identity where
  the OS reports one) before it is judged. Git is pointed at the pinned real
  path instead of the path as typed.
- Before every git step that writes, and before the file deletes and empty
  folder creation that run outside git, the folder is checked again. A folder
  that now leads elsewhere raises FolderChangedException
  (error.path.changed); a missing marker raises ConsentMarkerException. The
  check runs after the invocation observer, right before git starts.
- On Windows the folder is held open without delete sharing while the
  operation runs, so it cannot be renamed or removed. Git working inside is
  unaffected.
- A switch note that exists but cannot be read or understood now refuses a
  capture with InterruptedSwitchException, as the reclaim check already did.
- The folder read after play logs a warning when it fails, instead of
  swallowing the error.

Observed reds, all assertion failures before the change:
- FolderRecheckTests swapped-for-a-link (Discard, Clean, Switch, ForcedSwitch),
  retargeted link (Discard, Clean, Switch), lost marker (Discard, Clean,
  Switch), different folder at the same path (Discard, Clean; Windows):
  "Assert.Throws() Failure: No exception was thrown".
- FolderRecheckTests resolved work tree: "Assert.Equal() Failure: Strings
  differ" (WorkTree was the link, not the real folder).
- FolderRecheckTests Windows rename (Discard, Clean, Switch): "the folder was
  renamed while a step that deletes files was about to run".
- UnreadableJournalTests (not valid json, no target, held open): "Assert.Throws()
  Failure: No exception was thrown".
- LaunchExitSurvivalTests warning: "Assert.Single() Failure: The collection was
  empty".
Mutation checks: removing the empty-folder recheck failed its test; making
IsStillPinned ignore identity or the real path failed the pin tests.
Conflicts: GameEditorView.axaml (kept both xmlns declarations); add-game.png (kept this side, regenerated in a later commit).
- error.path.changed has its own catalog text, card title and presentation
  row instead of the generic card. The text names the install or saves folder
  and says SavePoint stopped before changing more files.
- A switch refused by the recheck before git starts (folder changed, marker
  gone) puts back its aligned index and removes the note it wrote, as a
  refusal by git does, so a later snapshot is not refused for a switch that
  never wrote anything.
- A switch refuses with InterruptedSwitchException when the switch note exists
  but cannot be read or understood, and leaves the note as it is. A discard
  still clears such a note.

Observed reds, all assertion failures before the change:
- ErrorCardViewModelTests folder-replaced card (Install, External): Expected
  "The folder changed while SavePoint worked", Actual "Something went wrong".
- ErrorCopyTests Every_error_key_in_the_catalog_has_a_sample_error failed once
  the catalog key was added, until the sample errors were added.
- FolderRecheckTests leaves_no_note (Switch and ForcedSwitch, link and marker):
  "a note says a switch is unfinished although nothing was written".
- UnreadableJournalTests switch with a note that is not valid json (normal and
  forced): "Assert.Throws() Failure: No exception was thrown". With the note
  held open (Windows) the switch failed with UnauthorizedAccessException, not
  InterruptedSwitchException.
Mutation check: removing the journal clear from discard failed the new
discard test.
A power cut seconds after a snapshot or switch could leave git's index
file empty or short. With the bundled git 2.56 every command then fails
("index file smaller than expected", "index file corrupt") and nothing in
SavePoint repaired it.

- The managed repo config sets core.fsync=committed,index and
  core.fsyncMethod=batch (config stamp 7), so existing repositories take
  them the next time they are touched.
- GitFailure.IsIndexDamage recognizes the four index messages.
- The engine sets a damaged index aside as index.damaged-<time>, rebuilds
  it with read-tree HEAD (no game file is touched), and runs the failed
  call once more. An unborn branch just starts with an empty index. An
  emptied ref file is not taken for an unborn branch. When the latest
  snapshot cannot be read, the file is put back and
  RepositoryDamagedException (error.gitOperation.recordDamaged) is
  thrown, with plain-words copy and an error card entry. A second
  failure right after a repair throws the same error. Repairs are
  serialized and logged.

Timing (5,000 files x 40 KB = 200 MB, add + commit, managed settings,
bundled git 2.56 on NVMe, F: drive, 3 runs each, ms):
  none      14.7 s mean (13559 / 15223 / 15385; rerun 16502 / 14398 / 14116)
  batch      10.1 s mean (12293 / 9027 / 8950; rerun 10341 / 9062 / 10198)
  fsync      15.6 s mean (14962 / 13923 / 18018)  [fsyncMethod=fsync]
  batch+ref  11.9 s mean (15688 / 9228 / 10876)   [adds "reference"]
Batch is faster than no setting here, so there is no cost to report. No
warning is printed about the method on Windows.

Observed reds (assertion failures, before the change):
- RepoConfigTests.Init_applies_the_setting_and_git_reads_it_back(core.fsync):
  Expected "committed,index", Actual null; same for core.fsyncmethod "batch".
- RepoConfigTests.A_repository_stamped_6_takes_the_flush_settings_the_next_
  time_it_is_touched: Expected "committed,index", Actual null.
- RepoConfigTests.Init_again_reapplies_the_settings_when_the_stamp_differs:
  Expected "7", Actual "6".
- IndexRepairTests.A_snapshot_after_the_index_was_damaged_is_taken_... (empty,
  zero-filled, truncated), The_damaged_index_is_kept_under_a_new_name...,
  A_switch_after_the_index_was_damaged_goes_through, A_first_snapshot_that_
  was_cut_off...: Assert.Null failure, Actual GitOperationException "git
  ls-files -z -t exited with code 128: fatal: ...index: index file smaller
  than expected" (or "bad signature 0x00000000").
- IndexRepairTests unrepairable cases: Assert.IsType failure, Expected
  RepositoryDamagedException, Actual GitOperationException.
- ErrorCopyTests.Every_error_key_in_the_catalog_has_a_sample_error:
  'error.gitOperation.recordDamaged' has no sample error.
Mutation checks on tests that passed first run: IsIndexDamage widened or
with phrases dropped fails IndexDamageClassificationTests; put-back of the
set-aside file disabled fails the two "nothing is changed" tests; unborn
detection flipped fails 5 repair tests.

Tests run one class at a time with --max-threads 2: IndexRepairTests (14),
IndexDamageClassificationTests (14), RepoConfigTests (73), CaptureTests
(56), CheckoutTests (22), InitTests (16), StaleLockTests (10),
DeleteRepoTests (26), MaintenanceTests (11), StorageUnreachableChoicesTests
(22), ErrorTypesTests (63), and in the App tests ErrorCardViewModelTests,
CatalogLintTests, CatalogCopyRuleTests, LocalizationCatalogTests and
ErrorCopyTests. dotnet format and the warnings-as-errors build are clean.
Play on a row whose stats are not known yet (first draw from the list alone, or the
stats call failed) says "Play", not "Switch and play". The Take a snapshot button
moves out of the game header, which it crowded, onto the right end of the tab row
(its own row in the library layout); the header buttons and thresholds are as they
were. It shows its words down to a 480 px row and then an icon with a tooltip. The
actions column is sized to its widest button through a shared size group instead of
a fixed 184 px, and the version, mod files and last played columns are narrower so
profile names keep the room they had at 1040 and 900 px.

The button and the menu entry share one command on the loaded row: both are off
while a snapshot of the game is running, so a second press cannot queue another,
and a profile with no snapshot yet (when it is the only one) asks the same first
snapshot question as the menu. Both read "Take a snapshot". Notes join the row's
spoken name, run together on the row line so the two-line limit ends in an
ellipsis, and stay whole in the tip. History save rows say "Go back and play: X
(saves)" and "Go back without playing: X (saves)" so they differ from the timeline's.

Observed reds (assertion failures):
- Play_says_just_Play_on_every_row_until_the_row_stats_have_arrived and
  ..._when_the_row_stats_could_not_be_read: Expected "Play", Actual "Switch and play"
- Notes_run_together_on_the_row_line_and_stay_whole_in_the_tip_and_the_row_name:
  Expected "Line one line two", Actual "Line one\r\n\r\n  line   two"
- The_snapshot_button_on_the_tab_row_drops_its_words_only_when_the_row_is_narrow
  (480): Expected False, Actual True
- A_snapshot_still_running_for_the_game_turns_off_the_header_button_and_the_menu_entry_until_it_ends:
  Expected False, Actual True
- The_header_snapshot_button_on_a_profile_with_no_snapshot_yet_asks_first_as_the_menu_entry_does:
  Expected True, Actual False
- GamesHeaderTests.The_game_name_keeps_its_room_in_the_sidebar_layout(1040): 153 px, needs 200;
  ..._title_keeps_its_room_in_the_library_layout(640): 230 px, needs 240;
  A_long_profile_name_is_cut_short...(900): 122 px, needs 150 (all with the button in the header
  and a fixed 184 px column)
- The_table_uses_the_expected_columns: version column at 207, expected 253-259
Mutation checks: removing the CanExecuteChanged raise fails
The_header_button_tells_the_screen_when_it_turns_on_or_off, removing the
HasLoadedProfile raise fails The_screen_says_when_a_profile_becomes_loaded_or_stops_being,
and showing "Switch and play" for any not-loaded-or-first row fails the no-snapshot-yet test.

Doc screenshots regenerated.
An unreadable switch note now refuses a switch and a snapshot, but the status
read it as no note at all, so on a clean folder the player saw nothing wrong
and had no way to discard it.

- InterruptedSwitch.ToCommit may be null. SwitchJournal.Read returns such a
  note when the file exists but is damaged or held open, so status, the
  launch preview and the launch refusal all report an unfinished switch.
- The preview gives that folder no finishing target, so the launch dialog
  offers discarding only; the discard clears the note and the next launch
  goes ahead.
- The refusal card names no "Finish the switch" action when the error has no
  target, and puts "Review the changes" first. The error text and the dialog
  body say SavePoint can't tell which switch it was and that discarding puts
  the folder back as its current snapshot has it.

Observed reds, all assertion failures before the change:
- UnreadableJournalTests status (damaged note, note held open): "Assert.IsType()
  Failure: Value is null".
- LaunchRefusalTests unreadable note on a clean folder: "Assert.True() Failure"
  on the preview's UnfinishedSwitch.
- LaunchUnfinishedSwitchFlowTests, no known target: actions were "Finish the
  switch" first instead of "Review the changes"; the dialog body still
  contained "Finish the switch".
InterruptedCheckoutTests.A_note_that_cannot_be_read_is_ignored described the
old behavior and now asserts the unknown-target note.
Template search (from the #157 review):
- Install-only rules follow the actual game-wide list: an untouched list is
  rebuilt as the template's install rules plus the defaults the game-wide list
  does not cover; a changed list keeps what the player removed and only gains
  the template's own install-only rules.
- A pick after a pick replaces what the first one filled, notes included; a
  field the player changed stays. A link template keeps a typed start file's
  method, a player who chose Through Steam keeps that choice, and the Steam
  app id is not filled when a typed link names another id.
- Matches rank by whole-name start, then first-word start, then list order.
  Typed words ignore punctuation ("stalker", "spiderman", "halflife"). Both
  live in TemplateSearch, shared with the picker.
- The header picker opens on the Name text as its search.
- Keyboard and screen reader: Down enters the list, Up and Down move in it,
  Enter in Name takes the top match, Escape closes it (only handled while it
  shows), focus returns to Name after a pick, the list closes when focus
  leaves it, matches are announced and each says it fills the form.
- A game that stays open after a refused picture stops offering templates.
- The pointer in the library checklist comes after the list.
- The Add a game screenshot dismisses the matches.

Tidied editor (from the #156 review):
- Template notes show the catalog's wording of each known sentence and nothing
  for other text (D53.5); notes from a definition file are not shown. The
  Skyrim template's one-off note is gone. A test checks every shipped note is
  made of known sentences.
- The default install rules no longer count as a More settings setting.
- With no program to suggest, the link-start nudge says the field is under
  More settings and offers a button that opens it and focuses the field; using
  a suggestion says what was filled in.
- The More settings toggle reports expanded or collapsed to screen readers.

Observed reds before the code (assertion failures on stubs):
- GameEditorTemplateTests: 16 of 34 failed, e.g. rank order, Escape CanExecute,
  announcement text, accessible name, install-only rules (removed mdmp came
  back), second pick kept the first one's details, link template choice.
- TemplatePickerViewModelTests: "stalker", "spiderman", "halflife" found
  nothing; ranking and initial search failed.
- GameEditorGuidanceTests: 7 failed (catalog wording, unknown sentence shows
  nothing, imported notes shown, default install rules opened More settings,
  imported file opened it, shipped notes with no wording).
Tests that passed on the first run were mutation-checked: five in Templates.cs
(launch options, same-id app id, toast, link choice, More settings) failed as
expected; Enter and Escape bindings, Down arrow, focus return, focus-leave,
the expand state, the nudge button and the library pointer order failed when
removed. The view tests had no separate red run; the mutation run is their
check. Restored afterwards.

Doc screenshot regenerated: docs/images/add-game.png.
- core.fsync is now committed,index,reference (config stamp stays 7), so
  an emptied branch ref after a power loss is much less likely.
  Timing, same 5,000 x 40 KB case, add + commit, 3 runs each:
  none 12858 / 14271 / 14650 ms (mean 13.9 s);
  batch with reference 8619 / 9562 / 9389 ms (mean 9.2 s).
- Only work that holds the game's lock repairs a damaged index.
  BackendServices.RunForGameAsync hands its body a StorageSnapshot whose
  engine is a lock-holder view; every other engine leaves the file alone
  and the read fails with the generic "try again" error. The profile rows
  (ProfileStats) already treat a failed status as an unknown folder, and
  the snapshot preview (GamesApi) already fails softly, so neither shows
  a card. The launch preview would otherwise block the launch for good, so
  it now repairs under the lock and reads again once.
- A failure of read-tree is reported as what it was: a full disk is
  DiskSpaceException, a held lock the generic retryable error, access
  denied StorageWriteFailedException; only a snapshot that cannot be read
  is RepositoryDamagedException. In every case the damaged index is put
  back.
- Each repair keeps the newest 3 index.damaged-* files.

Observed reds (before the change):
- IndexRepairTests.A_read_made_without_the_game_lock_leaves_a_damaged_
  index_alone: Assert.Throws "No exception was thrown", Expected
  GitOperationException.
- IndexRepairTests.Only_the_three_newest_set_aside_indexes_are_kept:
  Expected 3, Actual 6.
- IndexRepairTests.A_failure_to_rebuild_is_reported_as_what_it_was...:
  Expected error.diskSpace.low / error.gitOperation.failed /
  error.storage.writeFailed, Actual error.gitOperation.recordDamaged.
- IndexRepairTests.A_repair_that_met_a_held_lock...: Expected
  GitOperationException, Actual RepositoryDamagedException.
- IndexRepairTests.Repairing_on_request_sets_a_damaged_index_right:
  Assert.Single, the collection was empty.
- IndexDamageInReadsTests: rows and preview reads repaired the index
  (Assert.Empty on the set-aside files failed), the next snapshot found
  nothing to repair (Assert.False failure), the launch preview test failed
  its assertion.
- RepoConfigTests core.fsync: Expected committed,index,reference.
Mutation checks for the tests that passed first run: repairing always on
request fails the "not damaged" test; removing the lock gate fails the
unlocked-read, rows, preview and snapshot tests; disabling the launch
preview retry fails its test.
On Windows every git SavePoint starts is put in one kill-on-close job object that the app process holds for its life, so Task Manager, a crash or a log-off ends git with it. If a process cannot be put in the job (an exited one, or a job it cannot be nested in) the launch goes on and the problem is logged once.

At startup, before the stale-lock cleanup, the check now looks for programs running from the bundled git's folder that this run did not start and that do not descend from it (a registered git, this process, or anything below them). It gives them 10 s to end, stops what is left and waits for it to go. If one cannot be ended, no lock or temporary file is removed that run. The earlier-cleanup notice is shown while it waits. The reclaim wait still comes first, since it waits for a git instead of stopping it.

Linux has no pre-exec hook in Process.Start, and PR_SET_PDEATHSIG fires when the starting thread ends, so it is not set; the startup check covers it, and macOS.

Observed reds (assertion failures, before the code existed):
- GitProcessJobTests.A_git_ends_with_the_program_that_started_it_even_when_that_program_is_killed_outright: "the git is still running after its program was killed"
- GitProcessJobTests.A_process_that_cannot_be_put_in_the_job_is_reported_and_not_thrown_about: Assert.NotNull() Failure: Value is null
- BundledGitLeftoversTests.A_leftover_running_from_the_bundle_is_ended_and_one_running_from_another_folder_is_left_alone: "the leftover from the bundle is still running"
- BundledGitLeftoversTests.A_leftover_that_cannot_be_ended_is_reported_as_still_running: "a process that was not ended was reported as gone"
- BundledGitLeftoversTests.A_leftover_that_ends_by_itself_within_the_wait_is_not_ended_by_force: Assert.False() Failure, Expected: False, Actual: True
- BundledGitLeftoversTests.The_screen_is_told_before_the_wait_begins: Assert.True() Failure, Expected: True, Actual: False
- StartupLeftoverGitTests.A_git_a_stopped_SavePoint_left_running_is_ended_before_its_locks_are_removed: "the leftover git is still running"
- StartupLeftoverGitTests.Locks_stay_while_a_leftover_git_is_still_running: "a lock was removed under a git that is still running"
- StartupLeftoverGitTests.The_screen_is_told_an_earlier_cleanup_is_being_finished_while_a_leftover_is_waited_for: Expected [FinishingEarlierCleanup], Actual []

Tests that passed on their first run were mutation-checked: dropping the separator from the bundle-folder match fails A_folder_that_only_starts_with_the_bundles_name_is_not_the_bundle; ignoring the parent chain fails A_program_this_program_started_from_the_bundle_is_not_a_leftover and A_program_in_the_list_of_running_git_is_not_a_leftover; logging when nothing is left fails Nothing_is_said_and_nobody_waits_when_nothing_is_left; assigning a null handle fails A_running_process_is_put_in_the_job_without_a_problem and the kill test.
The startup check finished a free-up that was cut off between its two folders even when a git left running by a stopped SavePoint could not be ended, so that git and the clear could touch the same repository. The finish now runs only when the leftover check ended everything, like the lock cleanup; otherwise it is logged and tried again at the next start.

Observed red (assertion failure, before the change): StartupLeftoverGitTests.A_clear_that_was_cut_off_is_not_finished_while_a_leftover_git_is_still_running: "a clear was finished under a git that is still running". Passes after the change; FreeUpSpaceInterruptedTests still pass.
Review round for the folder recheck.

- The removal of files a switch displaces looks at the folder again first,
  as the clean retry, the leftover removal and the empty-folder step do.
  Those four steps now delete and make folders in the folder that was
  approved (the real path), so a link pointed elsewhere after the look
  cannot redirect them.
- A test seam names each of these steps and fires before the look and right
  after it.
- Holding the folder opens the folder itself, reads its identity from the
  held handle and refuses when it is not the pinned one. A folder that
  cannot be held or has no identity is logged on Windows (the engine now
  has an optional log).
- A switch refused by the recheck because the marker cannot be read also
  puts back its index and removes its note.
- The switch note is read with the same waits as clearing it. A discard that
  cannot remove the note throws SwitchNoteStuckException, with its own card
  copy, so the player is not sent round again.
- The pin is taken after the spelling is judged; the engine reads the note
  once; the disk-full error names the folder as the player spelled it.
- Copy says "Some files may already be changed". The docs on
  FolderChangedException and the engine methods no longer say it covers a
  lost marker.
- build/expected-skips/linux-ci.txt names the new Windows-only skips.

Observed reds, all assertion failures before the change:
- remove-displaced swapped: Contents of the outside folder differed (its logs
  file was deleted); leftover removal swapped: b-only.txt deleted outside;
  clean retry swapped (Clean, Discard): "No exception was thrown"; empty
  folders swapped: "No exception was thrown".
- Link retargeted after the look: GitOperationException "Checkout could not
  update: late.txt" (the delete followed the link).
- Marker held open at the checkout: "a note says a switch is unfinished
  although nothing was written".
- Note held for a moment: Read returned a note with no target. Discard with
  the note held open: "No exception was thrown" for SwitchNoteStuckException.
- FolderGuardTests: "The collection was empty" (no log line) twice, and "No
  exception was thrown" for a handle that is another folder.
- ErrorCardViewModelTests: the stuck-note card fell back to the generic one;
  the folder card still said "switched".
Mutation checks: with the hold off the link-hold test failed; with Dispose a
no-op the cancellation test failed; with the handle comparison off the
FolderGuardTests case failed. A swap just before the hold is also caught by
the recheck that follows it, so that test passes without the handle check.
Rebuild (GitEngine.IndexRepair.cs)
- The set-aside file is named savepoint-damaged-index-<time>.tmp. Deleting
  a repository accepts *.tmp, so a game, Clear all data and a storage move
  no longer fail after one repair; the stale-file sweep does not know the
  prefix and leaves the kept files.
- The new index is built in a side file (GIT_INDEX_FILE, read-tree HEAD, or
  read-tree --empty for a folder nothing was saved from) and swapped in
  through index.lock with File.Replace, so the real index is never missing.
  The damaged file is renamed in that one step. The put-back path is gone.
- update-index -q --refresh runs on the side index before the swap, so the
  next status does not read every file in full.
- The lock and the swap retry with LockRetryDelays. A file another program
  holds is the held-file error (error.gitOperation.checkoutFailed, path =
  the index); any other failure to write is StorageWriteFailedException.
- IsIndexDamage matches only git's own "fatal:" and "error:" lines, with
  the phrase as the message. A file named "index file corrupt" in a
  refusal list is not damage.
- A switch refuses to repair once it has written the index itself (the
  marks, the alignment, the checkout, the re-syncs): the error ends the
  switch, the note stays, and the next operation repairs.
- core.fsyncMethod is fsync on Linux and batch on Windows and macOS. The
  writer picks by system; one config stamp (7) covers both.
- StorageSnapshot's lock-holder view is set with Interlocked; the
  StorageWriteFailedException doc is reconciled with AppStatusApi.

Noted switch (not changed): a switch git finished but did not verify
finishes after a repair, and discarding the mix works with a damaged index
(both tests added, both passed from the start). A switch stopped part way
through the files needs a discard with an intact index as well, so a repair
does not add a failure there; no code change.

Observed reds (before the change):
- IndexRepairTests, set-aside name: Assert.Single on savepoint-damaged-
  index-*.tmp failed, the collection was empty (also the prune test).
- DeleteRepoTests.A_repository_whose_damaged_index_was_set_aside_can_still_
  be_deleted: the delete threw GitOperationException (the old name is not
  one the removal check accepts).
- The_index_file_is_never_missing_while_the_new_one_is_built: Assert.False
  failed, the index file was gone during read-tree.
- The_rebuilt_index_knows_the_files...: ls-files --debug showed size: 0,
  expected size: 5.
- A_repair_that_cannot_swap_the_index_in...: held-file error expected on
  Windows, got another error.
- A_repair_that_met_a_held_lock...: Expected error.gitOperation.
  checkoutFailed, Actual error.gitOperation.failed.
- Once_a_switch_has_written_the_index_itself... (checkout, verify): Assert.
  IsType<GitOperationException> failed, the damage was repaired or
  reported as RepositoryDamagedException.
- IndexDamageClassificationTests: four lines that only mention the phrase
  (file names in a refusal list, a hint, a pathspec) were taken for damage.
- RepoConfigTests.The_flush_method_is_picked_by_the_system...(isLinux):
  Expected "fsync", Actual "batch".

Timings (5,000 files x 40 KB = 200 MB, add + commit, managed settings, 4
alternating pairs, same data; core.fsync=committed,index,reference with
core.fsyncMethod=batch against none):
  none  13148 / 14492 / 13791 / 14044 ms  median 13.9 s
  batch  8694 /  8160 /  8472 /  8153 ms  median 8.3 s
Measured on the Windows bundle only; I do not claim the setting is faster
in general. git printed no warning about an unknown core.fsync component;
a test pins that.

Correction to the earlier commits: the Windows bundle is MinGit
2.56.0.windows.2 (built on upstream git 2.53), and Linux and macOS run
dugite-native git 2.53. The timings and the probes were made with the
Windows bundle only.

Tests run one class at a time with --max-threads 2: IndexRepairTests (36),
RepoConfigTests (77), IndexDamageClassificationTests (19), DeleteRepoTests
(27), IndexDamageInReadsTests (4), CaptureTests, CheckoutTests,
InterruptedCheckoutTests, StaleLockTests, InitTests, DiscardTests,
IndexAlignmentTests, SwitchSafetyTests, LaunchPreviewTests,
StorageUnreachableChoicesTests, ErrorTypesTests. dotnet format and the
warnings-as-errors build are clean.
The leftover check matched programs by the bundled git's folder. That fails under an AppImage (a new mount path each launch) and macOS translocation, reaches other users' programs on one machine, trusts parent ids that are reused, and ended a process without checking its start time again.

Now the registry keeps a small note in the user's runtime folder of the gits this run started that are still going: the owner's and each git's id and start time. It is written from a timer 500 ms after the set changed and only when it differs from what was written last, so short calls cost no writes (a SavePoint stopped from outside within 500 ms of starting a git leaves no note of it; a git that short is over by the next start). The next start reads the note when the backend is built, ignores a note whose owner still runs, waits a bounded time for the gits it names that still match by id and start time (one clock, Process.StartTime), then ends them after checking the start time again on the process just opened. No path matching and no parent walk remain.

Reclaim gits (D46.1) are left to finish: they are kept out of the Windows job object and out of the note, and the start still waits for them through their own note, before the leftover check and before the lock cleanup. Every other git stays in the job.

A leftover that cannot be ended is kept (carried into the new note) and a check of it is handed to the engine: while it runs no lock or temporary file is removed before a write or at startup, and a reclaim or a clear of removed records is refused. The cut-off free-up finish is skipped and logged only when a free-up note exists. The startup screen says "SavePoint is waiting for a task it started before it closed" while it waits for a leftover (new progress value and catalog line). The job log line is skipped for a process that had already ended.

Observed reds (assertion failures, before the code existed):
- RunningGitNoteTests.What_is_written_is_read_back: Assert.NotNull() Failure: value does not have a value
- GitProcessRegistryNoteTests: A_git_that_keeps_running_is_written_to_the_note_with_this_program_as_its_owner "the note was never written"; The_note_goes_when_the_last_git_ends; A_git_carried_over_from_an_earlier_run_... "a carried git was not written"; Closing_ends_what_runs_and_removes_the_note Assert.True() Failure
- LeftoverGitsTests: A_git_the_note_names_is_ended_... "the leftover is still running"; Ending_a_process_checks_its_start_time_at_that_moment Assert.True() Failure; A_leftover_that_cannot_be_ended_... "a process that was not ended was reported as gone"; The_screen_is_told_before_the_wait_begins; A_leftover_that_ends_by_itself_... Assert.False() Failure
- LeftoverGitGuardTests: all four ("a lock was removed under a git that is still running"; RemoveStaleLocks Expected: 0 Actual: 1; reclaim and ClearExactAsync "No exception was thrown")
- GitProcessJobTests.A_process_that_had_already_ended_is_not_worth_a_line_in_the_log: Assert.Empty() Failure: the access-denied warning was logged
- StartupLeftoverGitTests: A_git_the_note_of_a_stopped_SavePoint_names_is_ended_... "the leftover git is still running"; Locks_and_temporary_files_stay_... "a lock was removed under a git that is still running"; The_screen_is_told_a_task_... Expected [WaitingForEarlierTask] Actual []; A_clear_that_was_cut_off_is_not_finished_... "a clear was finished under a git that is still running"; A_git_the_backend_runs_is_written_to_the_note_... "the running git was never written to the note"
- StartupViewModelTests.While_a_task_started_before_SavePoint_closed_...: Expected (Checking, True, False) Actual (Checking, False, False); StartupViewTests.While_a_task_started_...: Assert.Contains() Failure: item not found

Mutation checks of tests that passed on their first run (each mutation failed the named test and was restored): Clear as a no-op fails Clearing_removes_the_note_...; reading a bad note without catching fails A_missing_or_unreadable_note_...; writing an empty set or ignoring the persist flag fails A_git_that_ends_within_the_delay_is_never_written and A_git_that_is_left_to_finish_is_not_written; dropping the owner check fails A_note_whose_owner_still_runs_...; not filtering stamps by start time fails A_process_that_only_has_the_number_...; logging when nothing is left fails Nothing_is_said_...; putting every git in the job fails A_git_that_is_left_to_finish_is_not_put_in_the_job_...; running the leftover check before the reclaim wait fails The_start_waits_for_a_noted_reclaim_first_...
# Conflicts:
#	build/expected-skips/linux-ci.txt
#	src/Savepoint.Core/Backend/CoreBackend.cs
#	src/Savepoint.Core/Git/GitEngine.cs
#	src/Savepoint.Core/Git/GitEngineOptions.cs
A first snapshot of a big install only checked a 100 MiB floor, so it could fill the drive, and the temporary pack a failed attempt left made every retry fail the space check until restart. A launch switched the install folder and only then learned the saves folder could not switch, leaving the two on different profiles.

Capture:
- When the floor check fails and nothing of this engine is working on the repository, the temporary pack and object files a stopped write left are removed and the volume is judged again. Locks are not touched by this step.
- The files a capture will add are sized (the same pass the progress totals use, so a watched capture pays nothing extra) and the floor plus that size is checked before git stores anything. The refusal is the existing DiskSpaceException with required and free bytes.

Launch:
- New GitEngine.CheckSwitchAsync runs the refusals a switch makes before it writes (space, case clashes, folder links, file/folder clashes, unsaved changes, unfinished switch) and writes nothing. CheckoutAsync now shares the same code.
- The launch asks each folder to switch before it switches the first. No rollback.
- Three existing tests hold the launch at the install folder's free-space question to stop it inside the switch; they now hold the second question, since the first is the check.

Reds observed (assertion failures):
- CaptureSpaceTests.A_snapshot_larger_than_the_free_space_is_refused_before_any_object_is_written (both watched and not): "Assert.Throws() Failure: No exception was thrown".
- CaptureSpaceTests.A_temporary_pack_a_stopped_snapshot_left_does_not_block_the_next_one: DiskSpaceException, 1000 bytes needed, -48990 free (the leftover's size).
- SwitchCheckTests: the space, unsaved changes, no-point and older-point cases each failed with "Assert.Throws() Failure: No exception was thrown" against a no-op CheckSwitchAsync.
- LaunchPreCheckTests.A_saves_folder_that_is_short_of_space_stops_the_launch_before_the_install_folder_is_switched: "Assert.Equal() Failure: Dictionaries differ" on the install folder, which had been switched.
- The three launch tests that hold the free-space question failed with "Assert.NotNull() Failure: Value is null" on InterruptedSwitch once the check came first, until they held the second question.

Passed first time, then mutation-checked:
- fits / only changed files count: with 10 MB added to the estimate both failed with DiskSpaceException.
- still refused after the leftover is cleared: with the second check removed it failed.
- LaunchPreCheckTests.The_launch_goes_ahead_once_the_saves_folder_has_room_again and the new CaseClashTests case (Check) were not mutation-checked.

Timing: sizing 50,000 files of 0.5 to 3.5 KB (100 MB) took about 1.55 s on a 32-thread desktop (git ls-files -o over the same tree: 0.24 s), warm cache. A watched capture, which is how the app saves, already did this pass; only an unwatched capture pays it now.

Tests run: CaptureSpaceTests, SwitchCheckTests, CaseClashTests, CaptureGuardTests, CaptureTests, CheckoutTests, LaunchPreCheckTests and the launch classes that hold or count switches. dotnet format and the warnings-as-errors build are clean.
- A snapshot no longer clears temporary packs while a git an earlier run left going may still be writing them.
- The launch asks only the folders after the first before switching; the first folder's own switch refuses before it writes. The switching state is reported before the asking, so the dialog is not idle on a big folder. The three tests that hold the launch at the install folder's free-space question are back as they were.
- CheckSwitchAsync docs say it uses a throwaway classify index in the git directory, and list GitOperationException and OperationCanceledException.
- SizeOrMissing asks for a link target only of a file marked as a reparse point, so ordinary files do not open a handle.
- An index rebuilt after a failed call that was pointed at the empty no-hooks folder is now stamped against the repository's real folder (GitInvocation.TrackedFolder).

Reds observed (assertion failures):
- LeftoverGitGuardTests.A_temporary_pack_is_not_cleared_to_make_room_while_the_leftover_runs_and_is_once_it_is_gone: "Assert.Throws() Failure: No exception was thrown" (the pack was removed under the running leftover).
- IndexRepairTests.A_repair_started_by_a_question_asked_of_an_empty_folder_still_stamps_the_files_of_the_real_one: "Assert.Contains() Failure: Sub-string not found", entry b.txt shows "ctime: 0:0 mtime: 0:0", not "size: 3". (A first version that used GetStatus or let the save go on passed or failed for the wrong reason; the index is zero-filled with its old time stamp so the classify call is the first to find it, and the save is stopped before git add.)
- SwitchCheckTests unfinished-switch case passed first time; with the note ignored in CheckSwitchAsync it failed with "No exception was thrown", then restored. The index/config byte assertions and the CaptureSpaceTests leftover-removed assertion passed first time (the behavior already held).

Timing, 50,000 files of 0.5 to 3.5 KB, 32 threads, warm cache, three passes each:
- before (LinkTarget asked of every file): 2110, 2120, 2327 ms
- after (attribute first): 903, 898, 913 ms
git ls-files -o over the same tree: 292 ms.

Tests run: LeftoverGitGuardTests, IndexRepairTests, SwitchCheckTests, CaptureSpaceTests, PreviewTests, LinkedFolderTests, CaptureTests, CaptureBytesTests, SwitchStatTests, CaseClashTests, LaunchPreCheckTests, LaunchSwitchFailureTests, LaunchSwitchOnlyTests, LaunchUnfinishedSwitchTests, LaunchSwitchProgressTests. dotnet format and the warnings-as-errors build are clean.
Template notes are now a closed set shown from the catalog, and the one-off Skyrim sentence was dropped from skyrim-se.json. The test still expected it.

Observed red (gate run on the integration branch): GameTemplatesTests.Skyrim_template_matches_the_v1_definition_exactly failed with Assert.Equal() Failure: Values differ, expected Notes = 'Direct-exe launch preferred; ...', actual Notes = empty. Green after the expectation drops Notes.
core.fsyncMethod=batch makes git stage objects in a temporary object directory and move them at the end. On Windows an add that also streams a big file into a pack then fails with 'unable to unlink tmp_objdir-bulk-fsync-*/pack/tmp_pack_*', 'unable to write file ...objects/pack/tmp_pack_*: Permission denied', 'unable to migrate temporary objects' and 'failed to commit ODB transaction' (exit 128). Every system now writes core.fsyncMethod=fsync and the per-system split is gone. The config stamp stays 7.

Cost of core.fsync=committed,index,reference with fsyncMethod=fsync against none (bundled Windows git, add -A plus commit, fresh repo per run, alternating, medians): 5,000 files of 40 KB over 4 pairs 14475 ms vs 13847 ms (-4.3%, noise); one 2 GB streamed file over 4 pairs 11524 ms vs 11379 ms (-1.3%, noise).

Observed reds before the change: RepoConfigTests.Init_applies_the_setting_and_git_reads_it_back(core.fsyncmethod) and Each_setting_is_defined_once_so_git_config_can_still_change_it expected 'fsync' but git read 'batch'; Every_system_flushes_file_by_file (both cases) failed on Assert.Contains of 'fsyncMethod = fsync'; A_repository_stamped_6_takes_the_flush_settings_the_next_time_it_is_touched failed Assert.Null on core.fsyncMethod (actual 'batch'). StreamedPackTests (2 tests) and ReclaimStreamedPackTests (1 test) failed on Windows with the git errors above and pass with fsync.
The test tells the capture's free-space questions from the optimization's by looking for CaptureCoreAsync on the stack. The size check added to the staging step asks a second time from StageAsync, after an await, where CaptureCoreAsync is no longer on the stack, so the capture's own question was taken for the optimization's: it set the optimization's reached event and waited out its 20 second hold, and the job stayed running past the test's ten second wait. Whether the stack still shows the starting method depends on whether the awaits finished synchronously, which is why Linux failed once and passed on retry. The product is right; a capture ends when its points are written. Every engine method of the capture now counts as the capture.

Observed red before the change (Windows): CaptureResultPublishTests.A_capture_ends_as_soon_as_its_points_are_written_even_while_an_optimization_waits_on_the_same_game failed with 'the capture was still running ten seconds after its points were written', every run. Green after.
The exit hook of every backend the process built clears that backend's note of running git. RunningGitNote.Clear retried a failed delete four times with sleeps of 30, 60, 90 and 120 ms, and deleting a file in a folder that no longer exists throws DirectoryNotFoundException, an IOException, so each backend whose temporary runtime folder was already removed cost 300 ms at exit. A test run builds thousands of backends, so the host took far longer than the ten seconds xunit allows after the last test, and xunit reported it as 'Waiting 10 seconds for foreground threads to exit...' and '[FATAL ERROR] Foreground threads were left running, forcing process exit' even though every test had passed. No thread is left running. Clear now returns when there is no note, so only a note that exists is retried.

Observed red before the change: RunningGitNoteTests.Clearing_a_note_in_a_folder_that_is_gone_does_not_wait failed with 'clearing took 319 ms for a note that cannot exist'.

Observed on Linux (WSL) before the change: GamesAddTests, GamesQueryTests and ProfilesStatsTests together (58 tests, all passing) ended with 'Exit code: 1, Waiting 10 seconds for foreground threads to exit..., [FATAL ERROR] Foreground threads were left running, forcing process exit'. After the change the same run passed with exit code 0 and no such message.
Find the NuGet packages where NuGet does: NUGET_PACKAGES first
Some checks failed
Docs / site (pull_request) Successful in 1m39s
Gate / linux (pull_request) Failing after 17m38s
Gate / windows (pull_request) Failing after 34m0s
b64fd36b16
The Linux gate sets NUGET_PACKAGES, so the pin test looked in .tools/nuget-packages and failed with 'microsoft.data.sqlite.nuspec is missing' although the restore had put it in .tools/nuget-linux.
Fix the CI failures of the leftover-git tests and list the Linux skip
All checks were successful
Gate / linux (pull_request) Successful in 18m58s
Release / windows (push) Successful in 3m9s
Gate / windows (pull_request) Successful in 39m35s
Release / checksums (push) Successful in 36s
Docs / site (push) Successful in 1m19s
Docs / site (pull_request) Successful in 1m35s
Release / linux (push) Successful in 2m0s
78b4db61a9
The job tests read child-git-id.txt while the child still had it open for writing (CI: IOException "being used by another process" at GitProcessJobTests.cs:64, both kill tests). The child now writes the file under another name and renames it, the test waits for the final name and retries a shared read for up to 10 s, and a probe skips the two kill tests with the system's reason when the job the runner puts the test program in does not allow a job inside it. The CI log shows no such skip, so none is added to the Windows list.

StartupLeftoverGitTests.The_start_waits_for_a_noted_reclaim_first_... failed on the slower VM (CI: Assert.False() Failure at the last line, the leftover still running after the check). The backend the test replaces keeps its own note of running git in the same folder from a timer after each git starts or ends; on a slow machine that timer fired after the test wrote the stopped SavePoint's note and replaced it, so the check found no leftover. The tests that write a note into the workspace's runtime folder now give the replaced backend an hour before its first write, and the reclaim test waits 600 ms before the restart to give that timer every chance.

Observed red of the second (a short note delay plus the 600 ms wait stand in for the slow machine): StartupLeftoverGitTests.The_start_waits_for_a_noted_reclaim_first_then_ends_the_leftovers_then_removes_the_locks failed twice in two runs at "Assert.False(FakeGameProcess.IsRunning(leftover.Id))" with the earlier note delay of 100 ms; passes 5 of 5 runs with the fix. GitProcessJobTests passes 5 of 5 runs.

IndexRepairTests.A_repair_that_cannot_swap_the_index_in_because_another_program_holds_it_says_so_and_changes_nothing skips on Linux and was not in build/expected-skips/linux-ci.txt (CI skip check); it is now. The other new test files named for the scan (FinishSwitch, FolderRecheck, UnreadableJournal, StartupLeftover, RunningGitNote, CaptureSpace, SwitchCheck, LaunchPreCheck, ChoiceListSemantics, HowItWorks) have no Windows-only skip that the list lacks.
Sign in to join this conversation.
No reviewers
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.

Dependencies

No dependencies set

Reference
ethan-hann/SavePoint!174
No description provided.