zfcsoftware / puppeteer-real-browser

This package is designed to bypass puppeteer's bot-detecting captchas such as Cloudflare. It acts like a real browser and can be managed with puppeteer.
https://www.npmjs.com/package/puppeteer-real-browser
MIT License
622 stars 84 forks source link

Isssue when closing page or browser #177

Closed RubberArchind closed 1 week ago

RubberArchind commented 1 week ago

Describe the bug Can't close page or browser when using a proxy, it always throw error even with minimal code

To Reproduce import { connect } from "puppeteer-real-browser";

const { page, browser } = await connect({ args: ['--no-sandbox', "--start-maximized"], connectOption: { defaultViewport: null, }, proxy: { host: "gw.dataimpulse.com", port: 823, username: "myusername", password: "mypassword" } })

await page.goto('http://google.com/'); browser.close()

Expected behavior successfully close the page and browser without error

Screenshots image

Desktop (please complete the following information):

Additional context this just happened in linux, i try this in windows and it run perfectly

zfcsoftware commented 1 week ago

Can you check with the latest version?

RubberArchind commented 1 week ago

Of course, I will try it after this and give you the result here.

RubberArchind commented 1 week ago

Ok, the last commit seems to fix the problem, it works fine now. Thanks a lot @zfcsoftware