diff --git a/webbot/webbot.py b/webbot/webbot.py index 31f5b63..99c6f5b 100644 --- a/webbot/webbot.py +++ b/webbot/webbot.py @@ -48,7 +48,10 @@ def __init__(self, showWindow=True, proxy=None , downloadPath:str=None, argument if(not os.path.isdir(absolutePath)): raise FileNotFoundError(errno.ENOENT, os.strerror(errno.ENOENT), absolutePath) - options.add_experimental_option('prefs', {'download.default_directory' : absolutePath}) + options.add_experimental_option('prefs', { + "download.default_directory" : absolutePath, + "download.prompt_for_download": False, + "plugins.always_open_pdf_externally": True}) if proxy is not None and isinstance(proxy, str): # Check if '--proxy-server' has not yet been set