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

Tolerate missing isIncognito method in Puppeteer v23 #587

Closed
wants to merge 1 commit into from

Conversation

jamesgpearce
Copy link

Fixes #586

Summary

Upgrading to Puppeteer v23 breaks tests since the isIncognito method has been removed. See https://github.com/puppeteer/puppeteer/releases/tag/puppeteer-core-v23.0.0
puppeteer/puppeteer#12830

Test plan

Make change in an environment that uses Puppeteer v23. Tests no longer fail.

@alopix
Copy link
Contributor

alopix commented Aug 12, 2024

Would it make sense to include some additional checks to close the browser context for if the isIncognito function does not exist?
This solution seems like it might result in many open contexts leaks 🤔

@jamesgpearce
Copy link
Author

This solution seems like it might result in many open contexts leaks 🤔

I didn't dig too deeply into why the context is only closed here for incognito in the first place! Was trying to fix this without much ... er ... context :)

@gregberge
Copy link
Member

Thanks, closed in favor of #588

@gregberge gregberge closed this Aug 17, 2024
rochejul added a commit to rochejul/web-component-attribute-polyfill that referenced this pull request Aug 18, 2024
@jamesgpearce jamesgpearce deleted the patch-1 branch August 18, 2024 18:20
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.

"TypeError: global.context.isIncognito is not a function" after upgrading to puppeteer 23.0.1
3 participants