Reputation: 811
When I run chromedriver, due to my system preferences it turns off "Location" as shown in this image.
The problem is an individual site still think my location is allowed. As shown in this image:
When I manually set this drop-down to "block" then I achieve the desired behavior. Any way to do this programmatically? Here is what I've tried adding in the capabilities/preferences from various posts around the internet, none have worked:
--disable-geolocation
--enable-strict-powerful-feature-restrictions
profile.default_content_settings.geolocation: 2
geolocation: 1
Upvotes: 1
Views: 2726
Reputation: 19989
--deny-permission-prompts
Prevents permission prompts from appearing by denying instead of showing prompts. ↪
https://peter.sh/experiments/chromium-command-line-switches/
COuld you try adding this as argument example :7
python ;
options.add_argument('--deny-permission-prompts')
Upvotes: 5