diff --git a/py/selenium/webdriver/common/selenium_manager.py b/py/selenium/webdriver/common/selenium_manager.py index fa26f73b9f9c0..d12a1d35b14f7 100644 --- a/py/selenium/webdriver/common/selenium_manager.py +++ b/py/selenium/webdriver/common/selenium_manager.py @@ -57,7 +57,7 @@ def get_binary() -> Path: path = Path(__file__).parent.joinpath(directory, file) - if not path.is_file() and os.environ["CONDA_PREFIX"]: + if not path.is_file() and "CONDA_PREFIX" in os.environ: # conda has a separate package selenium-manager, installs in bin path = Path(os.path.join(os.environ["CONDA_PREFIX"], "bin", file)) logger.debug("Conda environment detected, using `%s`", path)