diff --git a/undetected_chromedriver/__init__.py b/undetected_chromedriver/__init__.py index 2d78589..d6723f3 100644 --- a/undetected_chromedriver/__init__.py +++ b/undetected_chromedriver/__init__.py @@ -124,6 +124,7 @@ class Chrome(selenium.webdriver.chrome.webdriver.WebDriver): use_subprocess=True, debug=False, no_sandbox=True, + extra_chrome_arguments=[], user_multi_procs: bool = False, **kw, ): @@ -421,6 +422,10 @@ class Chrome(selenium.webdriver.chrome.webdriver.WebDriver): if hasattr(options, "handle_prefs"): options.handle_prefs(user_data_dir) + if extra_chrome_arguments: + for arg in extra_chrome_arguments: + options.add_argument(arg) + # fix exit_type flag to prevent tab-restore nag try: with open(