fix: Explicitly set executable_path for Selenium (#7715)

* fix: Explicitly set `executable_path` for Selenium

So it finds `geckodriver` again.

* Minimize diff

* fix: use existing executable_name

Co-authored-by: Lars Eggert <lars@eggert.org>

---------

Co-authored-by: Robert Sparks <rjsparks@nostrum.com>
This commit is contained in:
Lars Eggert 2024-07-21 03:14:40 +03:00 committed by GitHub
parent c5ca0ea405
commit 363c01e711
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -30,7 +30,7 @@ if skip_selenium:
print(" "+skip_message)
def start_web_driver():
service = Service(log_output=f"{executable_name}.log", service_args=['--log-no-truncate'])
service = Service(executable_path=f"/usr/bin/{executable_name}", log_output=f"{executable_name}.log", service_args=['--log-no-truncate'])
options = Options()
options.add_argument("--headless")
os.environ["MOZ_REMOTE_SETTINGS_DEVTOOLS"] = "1"