Skip to content

Commit

Permalink
I imagine the intention in rrweb-io#1509 was to also retry when the `…
Browse files Browse the repository at this point in the history
…describeNode` error was encountered. I assume the description `resolveNode` got changed to `describeNode` at some point in puppeteer history; in any case this solves the following error on my laptop:

ProtocolError: Protocol error (DOM.describeNode): Cannot find context with specified id

with test cross-origin-iframes.test.ts - should replace the existing DOM nodes on iframe navigation with `isAttachIframe`
  • Loading branch information
eoghanmurray committed Jan 17, 2025
1 parent dc20cd4 commit 6bf6a8d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/rrweb/test/record/cross-origin-iframes.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ async function injectRecordScript(
// we get this error: `Protocol error (DOM.resolveNode): Node with given id does not belong to the document`
// then the page wasn't loaded yet and we try again
if (
!e.message.includes('DOM.resolveNode') ||
!e.message.includes('DOM.resolveNode') &&
!e.message.includes('DOM.describeNode')
)
throw e;
Expand Down

0 comments on commit 6bf6a8d

Please sign in to comment.