File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -3845,6 +3845,12 @@ def get_local_driver(
3845
3845
edge_options .add_argument ("--guest" )
3846
3846
if dark_mode :
3847
3847
edge_options .add_argument ("--enable-features=WebContentsForceDark" )
3848
+ if headless1 :
3849
+ # developer.chrome.com/blog/removing-headless-old-from-chrome
3850
+ with suppress (Exception ):
3851
+ if int (str (use_version ).split ("." )[0 ]) >= 132 :
3852
+ headless1 = False
3853
+ headless2 = True
3848
3854
if headless2 :
3849
3855
try :
3850
3856
if use_version == "latest" or int (use_version ) >= 109 :
@@ -4386,6 +4392,12 @@ def get_local_driver(
4386
4392
use_version = find_chromedriver_version_to_use (
4387
4393
use_version , driver_version
4388
4394
)
4395
+ if headless1 :
4396
+ # developer.chrome.com/blog/removing-headless-old-from-chrome
4397
+ with suppress (Exception ):
4398
+ if int (str (use_version ).split ("." )[0 ]) >= 132 :
4399
+ headless1 = False
4400
+ headless2 = True
4389
4401
if headless2 :
4390
4402
try :
4391
4403
if (
You can’t perform that action at this time.
0 commit comments