Repository navigation
Fix VOD playback pausing past the chat's end, and chat dumps ending mid-stream - #9
Merged
Merged
Conversation
Playback past the chat log's length (e.g. a 2h chat log on a longer live capture) was paused again on every tick, and media keys played with the progress bar frozen. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014hw7BtW19ArbvUmkvBU5Hq
Any close of the Twitch IRC websocket (RECONNECT, maintenance, a network blip) finalized the chat dump and the dumper never reconnected, so chat stopped mid-stream while the video kept recording. Reconnect after 5s unless close() was called to stop the dump. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014hw7BtW19ArbvUmkvBU5Hq
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
Two fixes for the same report: a VOD stopped being playable about 2 hours in, and its chat ended 15 minutes before the video.
1. Player paused on every play past the chat's end (twitch-vod-chat submodule)
Updates the
twitch-vod-chatsubmodule to4e8b349. The chat ticker's end check compared against the chat log's length instead of the video's duration, so once playback passed the end of the chat every play was paused again on the next tick. Details are in second2falcon/twitch-vod-chat#2.2. Chat dumper ended the dump on any disconnect (
twitch-chat-dumper)ws.onclosefinalized the dump and never reconnected. Twitch closes IRC connections now and then (RECONNECT, maintenance, network blips), so the chat file was finished mid-stream while the video kept recording. In the reported stream the capture ran 17:35:53–19:53:26, but the chat dump ended at 19:38:08, with no ad breaks involved.The dumper now reconnects after 5 seconds unless
close()was called, which happens when the server stops it (SIGTERM). Messages keep their offsets from the original dump start. Addedtests/reconnect.test.tswith a mocked websocket. Jest passes (6/6) andtsc --noEmitis clean.Merge order
Merge second2falcon/twitch-vod-chat#2 first, with a merge commit, so
4e8b349ends up on its default branch. If it gets squashed, the submodule pointer here needs updating before this is merged.🤖 Generated with Claude Code
https://claude.ai/code/session_014hw7BtW19ArbvUmkvBU5Hq