diff --git a/chrome_tixcraft.py b/chrome_tixcraft.py index 0a0ae38..179a361 100644 --- a/chrome_tixcraft.py +++ b/chrome_tixcraft.py @@ -414,6 +414,9 @@ def load_chromdriver_normal(config_dict, driver_type): webdriver_path = os.path.join(Root_Dir, "webdriver") chromedriver_path = get_chromedriver_path(webdriver_path) + if not os.path.exists(webdriver_path): + os.mkdir(webdriver_path) + if not os.path.exists(chromedriver_path): print("WebDriver not exist, try to download...") chromedriver_autoinstaller.install(path="webdriver", make_version_dir=False) @@ -521,6 +524,9 @@ def load_chromdriver_uc(config_dict): webdriver_path = os.path.join(Root_Dir, "webdriver") chromedriver_path = get_chromedriver_path(webdriver_path) + if not os.path.exists(webdriver_path): + os.mkdir(webdriver_path) + if not os.path.exists(chromedriver_path): print("WebDriver not exist, try to download...") chromedriver_autoinstaller.install(path="webdriver", make_version_dir=False)