Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix incorrect restart of playback while artificially paused #189

Merged
merged 1 commit into from
Mar 31, 2020

Conversation

eoghanmurray
Copy link
Contributor

@eoghanmurray eoghanmurray commented Mar 30, 2020

Keep track of pause/play state so that player doesn't accidentally 'unpause' a user pause action.

I can reliably recreate the problem on a recording with stylesheets by doing:
player.on('fullsnapshot-rebuilded', player.pause);

The playback sometimes pauses, but depending on the timing of how external stylesheets load, the pause may not work, and play will continue.

(Pausing on the first fullsnapshot-rebuilded is very useful in order to present user with a 'screenshot' of the first screen before starting playback)

I haven't created a test case as none of the existing testcases rely on an external stylesheet (which could introduce a delay to the tests?), let me know if it's okay (and how) to introduce such a test case.

@Yuyz0112
Copy link
Member

Yep, this issue also makes the rrweb-player's auto play config unstable.

The fix is nice and I'm going to merge it. And then I would like to introduce a state machine to describe the replayer's state and makes it easier to test and integrate.

@Yuyz0112 Yuyz0112 merged commit e12d240 into rrweb-io:master Mar 31, 2020
billyvg added a commit to p-mazhnik/rrweb that referenced this pull request May 21, 2024
This brings our fork up to date with the latest upstream changes except
the reverted commits in getsentry#186.

`develop` branch will represent the rrweb changes that we want to use,
`master` tracks upstream master, and `sentry-v2` is contains our forked
changes on top of `develop`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants