Resume the rig watcher from the last complete log line #3589

Open
github-bot wants to merge 1 commit from github-bot/gh-3589 into main AGit
Owner

@⁠Yoshi-233 on GitHub · 2026-11-30 01:24 UTC · original
Yoshi-233:fix/watch-rig-resume-lines → main · +17 −10 · 1 files · 1 commits · open

What it changes

A watch resumed with -StateFile could lose a frame-time sample if the previous process ended mid-line. Its saved offset included every byte read, but the unfinished text lived only in memory. Checkpoint the byte immediately after the last complete newline in the UTF-8 play log. Log-growth detection still follows the file length when the last line is incomplete.

How it was tested

  • Ran the actual watcher in four separate PowerShell 7.7 processes on Linux, sharing one temporary log and JSON state. Stubbed Windows telemetry and advanced the clock for one poll per process.
  • Wrote a complete 20 ms sample and half of a 40 ms sample, restarted, then appended the rest. Main retained only 50 FPS. The patch retained 50 and 25 FPS exactly once.
  • Split a UTF-8 character across the next restart and finished its line with an out-of-memory marker. A final restart with no new input left both the FPS list and the single OOM count unchanged. No game or GPU run.

Windows CI stopped in the first Clippy step on the unchanged crash.rs:804 unused-function diagnostic for unwind_copy. The test step did not run. PR check · Same main commit

Checked for overlap

  • Checked open PRs touching the watcher. #2824 addresses numeric culture and CSV comparison.
**@⁠Yoshi-233** on GitHub · 2026-11-30 01:24 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3589) `Yoshi-233:fix/watch-rig-resume-lines` → `main` · +17 −10 · 1 files · 1 commits · open ## What it changes A watch resumed with `-StateFile` could lose a frame-time sample if the previous process ended mid-line. Its saved offset included every byte read, but the unfinished text lived only in memory. Checkpoint the byte immediately after the last complete newline in the UTF-8 play log. Log-growth detection still follows the file length when the last line is incomplete. ## How it was tested - Ran the actual watcher in four separate PowerShell 7.7 processes on Linux, sharing one temporary log and JSON state. Stubbed Windows telemetry and advanced the clock for one poll per process. - Wrote a complete 20 ms sample and half of a 40 ms sample, restarted, then appended the rest. Main retained only 50 FPS. The patch retained 50 and 25 FPS exactly once. - Split a UTF-8 character across the next restart and finished its line with an out-of-memory marker. A final restart with no new input left both the FPS list and the single OOM count unchanged. No game or GPU run. Windows CI stopped in the first Clippy step on the unchanged `crash.rs:804` unused-function diagnostic for `unwind_copy`. The test step did not run. [PR check](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46334684838/job/141572191718) · [Same main commit](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46320380085) ## Checked for overlap - [x] Checked open PRs touching the watcher. #2824 addresses numeric culture and CSV comparison.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-30 01:26:10 +00:00
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/3589/head:github-bot/gh-3589'
git switch 'github-bot/gh-3589'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-3589'
git switch 'github-bot/gh-3589'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-3589'
git switch 'github-bot/gh-3589'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-3589'
git switch 'main'
git merge --squash 'github-bot/gh-3589'
git switch 'main'
git merge --ff-only 'github-bot/gh-3589'
git switch 'main'
git merge 'github-bot/gh-3589'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
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
github/trustno1-coder--VIctory-NVIDIA!3589
No description provided.