Skip to content

Commit 2dedf26

Browse files
committed
Prevent memory leaks for Windows users
1 parent feca61a commit 2dedf26

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

seleniumbase/core/browser_launcher.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1688,7 +1688,10 @@ def _set_chrome_options(
16881688
chrome_options.add_argument("--ignore-certificate-errors")
16891689
if not enable_ws:
16901690
chrome_options.add_argument("--disable-web-security")
1691-
if IS_LINUX or not is_using_uc(undetectable, browser_name):
1691+
if (
1692+
IS_LINUX
1693+
or (IS_MAC and not is_using_uc(undetectable, browser_name))
1694+
):
16921695
chrome_options.add_argument("--no-sandbox")
16931696
if remote_debug:
16941697
# To access the Debugger, go to: chrome://inspect/#devices
@@ -3405,7 +3408,10 @@ def get_local_driver(
34053408
edge_options.add_argument("--allow-running-insecure-content")
34063409
if user_agent:
34073410
edge_options.add_argument("--user-agent=%s" % user_agent)
3408-
if IS_LINUX or not is_using_uc(undetectable, browser_name):
3411+
if (
3412+
IS_LINUX
3413+
or (IS_MAC and not is_using_uc(undetectable, browser_name))
3414+
):
34093415
edge_options.add_argument("--no-sandbox")
34103416
if remote_debug:
34113417
# To access the Debugger, go to: edge://inspect/#devices

0 commit comments

Comments
 (0)