diff --git a/webbot/webbot.py b/webbot/webbot.py index 5e9efa7..97d70e1 100644 --- a/webbot/webbot.py +++ b/webbot/webbot.py @@ -37,10 +37,12 @@ class Browser: - List containing all the errors which might have occurred during performing an action like click ,type etc. """ - def __init__(self, showWindow=True, proxy=None , downloadPath:str=None): + def __init__(self, showWindow=True, proxy=None , downloadPath:str=None, incognito=False): options = webdriver.ChromeOptions() options.add_argument("--disable-dev-shm-usage") options.add_argument("--no-sandbox") + if incognito: + options.add_argument("--incognito") if downloadPath is not None and isinstance(downloadPath,str): absolutePath = os.path.abspath(downloadPath) if(not os.path.isdir(absolutePath)):