From da68cf771dbc5ff21168afaa027ab206c6cdb7f1 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Sat, 17 Nov 2018 11:53:52 +0100 Subject: devtools: Update browser flags Add a few more that seem reasonable. --- crocoite/devtools.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/crocoite/devtools.py b/crocoite/devtools.py index 9ce4333..0bf2255 100644 --- a/crocoite/devtools.py +++ b/crocoite/devtools.py @@ -269,6 +269,7 @@ class Process: async def __aenter__ (self): assert self.p is None self.userDataDir = mkdtemp () + # see https://github.com/GoogleChrome/chrome-launcher/blob/master/docs/chrome-flags-for-tools.md args = [self.binary, '--window-size={},{}'.format (*self.windowSize), '--user-data-dir={}'.format (self.userDataDir), # use temporory user dir @@ -278,6 +279,17 @@ class Process: '--disable-extensions', '--disable-infobars', '--disable-notifications', # no libnotify + '--disable-background-networking', # disable background services (updating, safe browsing, …) + '--safebrowsing-disable-auto-update', + '--disable-sync', # no google account syncing + '--metrics-recording-only', # do not submit metrics + '--disable-default-apps', + '--disable-background-timer-throttling', + '--disable-client-side-phishing-detection', + '--disable-popup-blocking', + '--disable-prompt-on-repost', + '--enable-automation', # enable various automation-related things + '--password-store=basic', '--headless', '--disable-gpu', '--hide-scrollbars', # hide scrollbars on screenshots -- cgit v1.2.3