I have just tried using the library on an older machine and Chrome was a bit outdated, which caused the library to raise:
The ChromeDriver was unable to initiate/spawn a new
WebBrowser. You will not be able to scrape new data.
Message: unknown error: cannot connect to chrome at 127.0.0.1:57261
from session not created: This version of ChromeDriver only supports Chrome version 109
Current browser version is 108.0.5359.124
This can easily be fixed, by allowing to add version_main to the undetected_chromedriver.ChromeDriver.
For me I had to change the line 412 in _common.py to:
return uc.Chrome(options=chrome_options, version_main=108) # 108, because that's the main version of the installed chrome browser
But it would be great to have the user set this when initializing the WhoScored object or any other object that needs a Chrome-driver (but I think this is only relevant for WhoScored?)
I got the same issue. My Chrome version is 116.
I did change _common.py to return uc.Chrome(options=chrome_options, version_main=116), but it's not working.
I have just tried using the library on an older machine and Chrome was a bit outdated, which caused the library to raise:
This can easily be fixed, by allowing to add
version_main
to theundetected_chromedriver.ChromeDriver
. For me I had to change the line 412 in_common.py
to:But it would be great to have the user set this when initializing the
WhoScored
object or any other object that needs a Chrome-driver (but I think this is only relevant for WhoScored?)