Closed vanillechai closed 1 year ago
you need to install chrome on the default paths, works for me
you need to install chrome on the default paths, works for me
How can you do that on a headless machine? How would Chrome run from Docker or docker-compose?
FYI, got around this by adding --headless
as per above, but also had to add an option for --no-sandbox
, making sure the --no-sandbox
is the first option, as per https://stackoverflow.com/questions/53073411/selenium-webdriverexceptionchrome-failed-to-start-crashed-as-google-chrome-is
This seemed to do the trick.
You can refer to my single docker image dockerfile. It come with redis server and redisearch module.
https://github.com/tuapuikia/Auto-GPT/blob/master/Dockerfile-s6
RUN apt update && apt -y install vim redis-server chromium-driver chromium && \
I had it working using:
selenium.version '4.8.3'
chrome-driver and google-chrome-stable 109
web.py
options.binary_location=r'/usr/bin/google-chrome-stable'
driver = webdriver.Chrome(
executable_path='/home/gabriel/Auto-GPT/chromedriver', options=options
)
I managed to fix it by modifying web.py
and adding the following under user agent option... Be sure to download chromedriver here:. https://chromedriver.chromium.org/downloads.
options.add_argument("--headless=new")
options.add_argument("--no-sandbox")
options.add_argument("--ignore-ssl-errors=true")
options.add_argument("--ignore-certificate-errors")
options.binary_location="C:/Program Files/Google/Chrome Beta/Application/chrome.exe"
driver = webdriver.Chrome('C:/PATH_TO/chromedriver_win32/chromedriver.exe',options=options)
I still get SSL handshake errors on occasion, not sure which argument needs to be added to ignore those.
install chromium-chromedriver on a headless machine, note you should have systemd to use snap. For wsl user, try this https://stackoverflow.com/questions/62588767/running-google-chrome-on-wsl-ubuntu-as-headless-no-sandbox-gives-multiple
The following worked for me on Windows 10 in Ubuntu WSL. Edit web_selenium.py here:
options.binary_location="/mnt/c/Program Files/Google/Chrome/Application/chrome.exe"
driver = webdriver.Chrome(
executable_path="/mnt/c/Users/your_user_name/Auto-GPT/chromedriver", options=options
)
chrome.exe
by right-clicking the Chrome icon on your desktop, select Properties, copy the path to the executable from Target.executable_path
above.It would be great if the file path to chromedriver.exe and chrome.exe could be configurable in the .env
file.
I managed to fix it by modifying
web.py
and adding the following under user agent option... Be sure to download chromedriver here:. https://chromedriver.chromium.org/downloads.options.add_argument("--headless=new") options.add_argument("--no-sandbox") options.add_argument("--ignore-ssl-errors=true") options.add_argument("--ignore-certificate-errors") options.binary_location="C:/Program Files/Google/Chrome Beta/Application/chrome.exe" driver = webdriver.Chrome('C:/PATH_TO/chromedriver_win32/chromedriver.exe',options=options)
I still get SSL handshake errors on occasion, not sure which argument needs to be added to ignore those.
Does it work on Mac? I mean if download chrome driver for ma and reference the path
Please check if this is resolved with #1473. If this issue still exists in master
for you, feel free to reopen.
Duplicates
Steps to reproduce 🕹
This happens with any AI settings: As soon as the first
browse_website
command is executed, Auto-GPT fails with this error.Branch: master commit-hash: e986af5de0f1bd933f6c936c3674301c80f6c91f
also happens on: Branch: stable commit-hash: 60b2b61b52c263dba25a6c33623561273e890229
Current behavior 😯
After this, Auto-GPT reasons
I will try to find an alternative to Chrome and use the \'google\' command to find other open source software that meets the requirements.
, re-encounter the error and goes into a loop.Expected behavior 🤔
git pull
ed this morning.Your prompt 📝
This error is independent of the prompt.