When I try to create a Selenium Firefox Webdriver on my Orange Pi with Armbian Buster like
import selenium
from selenium import webdriver
from selenium.webdriver.firefox.options import Options
options = Options()
options.headless = True
driver = webdriver.Firefox(options=options, executable_path='/usr/local/bin/geckodriver')
the exception
selenium.common.exceptions.WebDriverException: Message: 'geckodriver' executable needs to be in PATH.
is thrown. This happens when I use the last geckodriver build for ARMv7 from github and when I build the geckodriver according to here.
The geckodriver binary lies in /usr/local/bin/ and is executable, but when I try to
geckodriver --version
I get
-bash: /usr/local/bin/geckodriver: No such file or directory
which leads my to the assumption that there is something fundamentally wrong with my approach. So how do I install geckodriver correctly on the Orange Pi with Armbian Buster?
I solved the problem by downloading the latest Ubuntu ARM64 package for
firefox-geckodriver, extracting thegeckodriverbinary and placing it in/usr/local/bin. This is also way faster than compiling thegeckodrivermyself and provides the most recentgeckodriverrelease.