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

Node not found warnings #620

Merged
merged 3 commits into from
Jul 19, 2021

Conversation

eoghanmurray
Copy link
Contributor

Add a try/catch around all mutations and show a warning rather than stopping playback because of the exception

Change how 'node not found' warnings are reported:

  • ignore ones where the node in question has been removed in the same mutation
  • different message for when a node was removed in a prior mutation vs. trying to alter a node that didn't exist in the last fullsnapshot

@eoghanmurray eoghanmurray force-pushed the node-not-found-warnings branch 2 times, most recently from df6be4f to 25b1df9 Compare July 7, 2021 16:30
@Juice10
Copy link
Contributor

Juice10 commented Jul 7, 2021

I love this, this is going to save many breaking replays in the case of minor hiccups.

It would be nice to see some tests around this though. I'm happy to help you out with them.

…rong, e.g. node removal parent belongs to a different FullSnapshot and has e.g. a text nodeType
… - or the parent node for a removed node has been already removed
Copy link
Contributor

@Juice10 Juice10 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Yuyz0112 Yuyz0112 merged commit c45fd2b into rrweb-io:master Jul 19, 2021
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.

3 participants