You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sorry for the dumb question but why is it useful to open multiple browser instances... is it any different to opening a single browser (with puppeteer.launch()) and using that to open multiple pages (with browser.newPage())? Is there a performance benefit of one way or the other? Wouldn't it be better to have a package for pooling pages instead? Or, since there isn't much overhead with opening and closing pages, unlike opening and closing a browser instance... don't even both with any page pool... just open/close pages as and when required?
The text was updated successfully, but these errors were encountered:
So screenshoting multiple pages of the same browser definitely doesn't happen in parallel? Doesn't the screenshoting of each page start in its own process... why should it have to happen in series?
The internal implementation of the screenshot feature requires the browser to bring the tab being captured to the front / make it active. It then has to draw the page and then capture the image. If you're wanting to take multiple screenshots very quickly, you have to split it out into multiple processes so they can each be rendering a single page and not locking on the active page.
Sorry for the dumb question but why is it useful to open multiple
browser
instances... is it any different to opening a singlebrowser
(withpuppeteer.launch()
) and using that to open multiplepages
(withbrowser.newPage()
)? Is there a performance benefit of one way or the other? Wouldn't it be better to have a package for poolingpages
instead? Or, since there isn't much overhead with opening and closingpages
, unlike opening and closing abrowser
instance... don't even both with anypage
pool... just open/closepages
as and when required?The text was updated successfully, but these errors were encountered: