fix: Allows configuration of Selenium Webdriver binary (#33103)

This commit is contained in:
Michael S. Molina
2025-04-14 08:11:02 -03:00
committed by GitHub
parent 3c1fc0b722
commit e1f5c49df7
2 changed files with 5 additions and 1 deletions

View File

@@ -275,6 +275,10 @@ class WebDriverSelenium(WebDriverProxy):
# Add additional configured webdriver options
webdriver_conf = dict(current_app.config["WEBDRIVER_CONFIGURATION"])
# Set the binary location if provided
# We need to pop it from the dict due to selenium_version < 4.10.0
options.binary_location = webdriver_conf.pop("binary_location", "")
if version.parse(selenium_version) < version.parse("4.10.0"):
kwargs |= webdriver_conf
else: