javascript - 'No frame for given id found' in puppetter - Stack Overflow

i am using puppetter for web scrapping ;matchesLinks is an array that contains urls of some games.my

i am using puppetter for web scrapping ; matchesLinks is an array that contains urls of some games. my code looks like :

for (let i = 0; i < matchesLinks.length; i++) {
   await page.goto(matchesLinks[i]);
   await page.goto(matchesLinks[i]);
   await new Promise((r) => setTimeout(r, 6000));
 }

after going to 1 or 2 URL i get error: originalMessage: 'No frame for given id found' anyone can help my why i am getting this error

i am using puppetter for web scrapping ; matchesLinks is an array that contains urls of some games. my code looks like :

for (let i = 0; i < matchesLinks.length; i++) {
   await page.goto(matchesLinks[i]);
   await page.goto(matchesLinks[i]);
   await new Promise((r) => setTimeout(r, 6000));
 }

after going to 1 or 2 URL i get error: originalMessage: 'No frame for given id found' anyone can help my why i am getting this error

Share Improve this question edited Jan 15, 2022 at 10:10 Sahil Soni asked Jan 14, 2022 at 8:02 Sahil SoniSahil Soni 711 silver badge4 bronze badges 4
  • 1 Are there more details in the error? Like filename and line number? – Matt Ellen Commented Jan 14, 2022 at 9:02
  • 1 Three lines of code with missing variables isn't enough to reproduce the problem. Which sites are you navigating to? Please share a minimal reproducible example. Thanks. – ggorlen Commented Jan 14, 2022 at 15:36
  • no there is not any other information . but when i make headless as true it works fine – Sahil Soni Commented Jan 15, 2022 at 10:07
  • Please provide enough code so others can better understand or reproduce the problem. – Community Bot Commented Jan 23, 2022 at 6:02
Add a ment  | 

2 Answers 2

Reset to default 6

I have been trying to solve the issue since 3 days now.. no luck at all.. Though the issue disappears pletely if you set "headless: true" at browser's launch options.. So this issue is only associated with "headless: false" setting.

For those who try to help. The issue happens when using "page.goto" to access a website that have iframes, and redirect requests (Trying to abort those requests, or waituntil domcontentloaded won't solve the issue if you were wondering). E.g. it happens every time when trying to access "https://www.whatismyip./"

You might be facing the issue described here: https://github./puppeteer/puppeteer/pull/7848

You may try to downgrade puppeteer version to 11.0.0 as a workaround

EDIT: The fix has most likely been released. Consider upgrading the puppeteer.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744039398a4548033.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信