question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Bug]: FrameManager crashes with assertion failing, Missing frame isMainFrame=false

See original GitHub issue

Bug description

Loading 9gag and accepting cookies is enough to get the error 80% of the time

This minimal example of code is enough tou trigger the bug in less than 20 s

  
  import puppeteer from "puppeteer";
  
  (async () => {
  
      
  let launchArgs = {
      headless: false, defaultViewport: null,
      args: [
          
      ],
  }
    const browser = await puppeteer.launch(launchArgs);
    const page = await browser.newPage();
    await page.goto('https://9gag.com');
    page.waitForSelector("[role='dialog'] button:last-child").then(z=>page.click("[role='dialog'] button:last-child"))
  
  })();

Puppeteer version

17.1.3

Node.js version

v16.15.0

npm version

8.5.5

What operating system are you seeing the problem on?

Windows

Relevant log output

PS C:\Users\admin\Desktop\Work\Project1> node .\test.js
file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/util/assert.js:25
        throw new Error(message);
              ^

Error: Missing frame isMainFrame=false, frameId=B31FE7351CFD830EC50A059DDD411382
    at assert (file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/util/assert.js:25:15)
    at complete (file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/common/FrameManager.js:274:9)
    at FrameManager._FrameManager_onFrameNavigated (file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/common/FrameManager.js:307:9)
    at file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/common/FrameManager.js:100:104
    at file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/vendor/mitt/src/index.js:49:68
    at Array.map (<anonymous>)
    at Object.emit (file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/vendor/mitt/src/index.js:49:43)
    at CDPSession.emit (file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/common/EventEmitter.js:66:22)
    at CDPSession._onMessage (file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/common/Connection.js:315:18)
    at Connection.onMessage (file:///C:/Users/admin/Desktop/Work/Project1/node_modules/puppeteer/lib/esm/puppeteer/common/Connection.js:153:25)

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:13

github_iconTop GitHub Comments

1reaction
OrKoNcommented, Oct 4, 2022

The assertion is no longer part of the code base since v18.0.0 https://github.com/puppeteer/puppeteer/pull/8952 I believe this issue should be considered fixed now.

1reaction
ThomazPomcommented, Sep 28, 2022

You can launch puppeter 8 with the executablePath arg set @ the path of your real chromium use the latest chrome version && no crash https://stackoverflow.com/a/62209380/4693790

Read more comments on GitHub >

github_iconTop Results From Across the Web

How can I catch Puppeteer error Missing frame isMainFrame ...
Starting from puppeteer 18 the assertion is no longer there according to the developers, an update fixes the issue.
Read more >
Bug #1782984 “Assertion `!xcb_xlib_threads_sequence_lost ...
01 LTS 64bit Desktop). PcManFM crashes quite often when accessing folders or files, it seems like a timing problem. There is no any...
Read more >
Q100432: Nuke crashing with 'Assertion Failed' error message
The crash occurs during normal use of Nuke without any deliberate actions from the user. This issue has been reproduced internally on both ......
Read more >
69274: MySQL 5.6 crashes during startup with assertion ...
Description: I am trying to migrate from Percona 5.5.30 to Percona 5.6.10. However, whenever I try to start the 5.6 server, it crashes...
Read more >
Issue 33612: Assertion failure in PyThreadState_Clear
Fatal Python error: Aborted Current thread 0x00007fdd3e07e700 (most recent call first): File "/home/serhiy/py/cpython/Lib/multiprocessing/ ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found