Skip to content

Commit 8358ef9

Browse files
committed
Add a workaround for a patch on Chrome 133+
1 parent 124e61e commit 8358ef9

1 file changed

Lines changed: 12 additions & 2 deletions

File tree

seleniumbase/core/browser_launcher.py

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6011,8 +6011,18 @@ def get_local_driver(
60116011
time.sleep(0.003)
60126012
driver.switch_to.window(driver.window_handles[0])
60136013
time.sleep(0.003)
6014-
driver.connect()
6015-
time.sleep(0.003)
6014+
# seleniumbase/SeleniumBase/discussions/4190
6015+
if getattr(sb_config, "skip_133_patch", None):
6016+
# To skip the connect() patch for Chrome 133+:
6017+
# from seleniumbase import config as sb_config
6018+
# sb_config.skip_133_patch = True
6019+
# (Do the above before launching the browser.)
6020+
pass
6021+
else:
6022+
# This fixes an issue on Chrome 133+
6023+
# (Some people might not need it though.)
6024+
driver.connect()
6025+
time.sleep(0.003)
60166026
if mobile_emulator:
60176027
uc_metrics = {}
60186028
if (

0 commit comments

Comments
 (0)