I've been trying to run selenium webdriver on raspberry OS.
Basically what I did:
pip3 install selenium
sudo apk-get install chromium-chromedriver
And run this script:
from selenium import webdriver
driver = webdriver.Chrome('/usr/bin/chromedriver')
driver.get('https://google.com')
With these variations:
driver = webdriver.Chrome(service=Service('/usr/bin/chromedriver'))
driver = webdriver.Chrome(service=Service('/usr/lib/chromium-browser/chromedriver'))
Also tried setting binary location:
options.BinaryLocation = "/usr/bin/chromium-browser/chromium-browser"
All of it boils down to an error which is:
Message: Service /usr/bin/chromedriver unexpectedly exited. Status code was: -4
I've tried reinstalling selenium, reinstalling chromium, updating everything. It always fails with status code -4 which is not very informative and hard to debug.
It seems like I'm getting illegal operation
message whenever I try to get chromedriver/chromium --version
which might be the clue why something is off.