Repository navigation
fix(repeat): stop the seek-back check from waiting forever on an idle ffmpeg - #80
Merged
Merged
Conversation
This was referenced Nov 16, 2026
Merged
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.
Summary
Refs #75. Once, a build sat for 15 minutes in the check that runs before capture, with node, Chromium and one ffmpeg all idle at 0% CPU. The ffmpeg left running was the one the seek-back check (
repeat.ts) starts to turn each compared frame into a small gray image. It was run withspawnSyncand no time limit, so node waited on it with no end. Every other wait in that check (the film page's calls) already has a limit.This does not find why that ffmpeg went idle (it has not happened again in 10 builds). It makes the build stop waiting:
ffmpegSync(the time-limited ffmpeg run from stills: the command can wait forever after Chromium goes away #51) takesinputfor stdin andtries: an ffmpeg that runs past its limit is killed and run again until the tries are used up.gray()inrepeat.tsuses it with a 10 s limit and 2 tries. A frame takes well under a second, so a normal build is not affected. A stall now costs at most about 20 s, then the check fails withffmpeg did not read the frame at <t> s in 10s (2 tries), which also says where it happened if it comes back.Test plan
tests/stall.test.ts: an ffmpeg that never exits makesgray()fail with the frame's time and "(2 tries)" in under 5 stests/stall.test.ts: an ffmpeg that stalls only on its first run is retried and the frame is read (480 × 270 gray bytes)make check(lint, format, types, all tests, quality gate)