UC keeps crashing on linux with FastAPI #2069
Labels
duplicate
The answer/solution already exists somewhere
external
Outside SeleniumBase's scope. / Ask somewhere else.
UC Mode / CDP Mode
Undetected Chromedriver Mode / CDP Mode
It runs fine on my Windows dev machine - when I run the program it automatically downloads the latest UC driver and works straight away. Now I'm trying to get it onto a prod environment with DigitalOcean apps and Docker. When I first run the script, it returns:
However, it hangs for a while and eventually responds with:
[2023-09-07 08:30:46] selenium.common.exceptions.WebDriverException: Message: unknown error: cannot connect to chrome at 127.0.0.1:9222
and(The process started from chrome location /root/.cache/selenium/chrome/linux64/116.0.5845.96/chrome is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
Here's my dockerfile:
Here's how the driver is being configured:
driver = Driver(uc=True, proxy=proxy, protocol="https", headless=True, no_sandbox=True, disable_gpu=True)
I can't tell if it's FastAPI, undetected chromedriver or the server itself responsible. Any help would be appreciated! thanks.
The text was updated successfully, but these errors were encountered: