seleniumbase / SeleniumBase

📊 Python's all-in-one framework for web crawling, scraping, testing, and reporting. Supports pytest. UC Mode provides stealth. Includes many tools.
https://seleniumbase.io
MIT License
5.17k stars 960 forks source link

unsupported command-line flag: --disable-setuid-sandbox #3102

Closed ScottCov closed 4 weeks ago

ScottCov commented 4 weeks ago
from seleniumbase import Driver
driver=Driver(uc=True,headed=True)
driver.get('https://www.google.com/')

Giving me the following message on Chrome browser (Version 128.0.6613.119 (Official Build) (64-bit)): Debian 12 Python 3.10.8 seleniumbase 4.30.3

image

Is this normal/expected?

Scott

mdmintz commented 4 weeks ago

Duplicate of https://github.com/seleniumbase/SeleniumBase/issues/2270#issuecomment-1808289456


--disable-setuid-sandbox is an option used for UC Mode on Linux. The warning message itself is harmless. There's a command-line option that removes such warnings, but using it would lead to detection, so having the warning message is better than the alternative.

You can see how commonly it was used with the original undetected-chromedriver:

https://github.com/search?q=repo%3Aultrafunkamsterdam%2Fundetected-chromedriver+disable-setuid-sandbox&type=issues

There's more info on that option in the Chromium documentation:

https://chromium.googlesource.com/chromium/src/+/main/docs/linux/suid_sandbox_development.md

Using that option prevented some issues on Linux, so it's there. I don't know all the specifics about it.