【发布时间】:2021-11-14 01:22:59
【问题描述】:
当尝试通过webdriver.Chrome()打开chrome浏览器时,它返回errors:
DevTools listening on ws://127.0.0.1:49645/devtools/browser/3c3d566d-8283-456e-9cae-4de285cd025e
PS C:\Users\Stellantt\Desktop\Selenium> [7896:6536:1114/074848.328:ERROR:chrome_browser_main_extra_parts_metrics.cc(230)] crbug.com/1216328: Checking Bluetooth availability started. Please report if there is no report that this ends.
[7896:6536:1114/074848.328:ERROR:chrome_browser_main_extra_parts_metrics.cc(233)] crbug.com/1216328: Checking Bluetooth availability ended.
[7896:6536:1114/074848.328:ERROR:chrome_browser_main_extra_parts_metrics.cc(236)] crbug.com/1216328: Checking default browser status started. Please report if there is no
report that this ends.
[7896:6208:1114/074848.334:ERROR:device_event_log_impl.cc(214)] [07:48:48.334] USB: usb_device_handle_win.cc:1048 Failed to read descriptor from node connection: A device
attached to the system is not functioning. (0x1F)
[7896:6536:1114/074848.342:ERROR:chrome_browser_main_extra_parts_metrics.cc(240)] crbug.com/1216328: Checking default browser status ended.
[4920:3584:1114/075045.724:ERROR:gpu_init.cc(453)] Passthrough is not supported, GL is disabled, ANGLE is
当我使用选项来修复它时:
options = webdriver.ChromeOptions()
options.add_experimental_option('excludeSwitches', ['enable-logging'])
driver = webdriver.Chrome(options=options)
它什么也没返回并终止了我的进程。
我该如何解决这个错误?
【问题讨论】:
标签: python selenium google-chrome selenium-webdriver selenium-chromedriver