命令行運輸robot腳本時一直報錯,瀏覽器關閉后才沒有報錯信息了
[1021/161731.893:ERROR:gl_surface_egl.cc(699)] EGL Driver message (Error) eglQueryDeviceAttribEXT: Bad attribute.
解決辦法:
chrome版本較高,禁用GPU加速
chrome_opt = webdriver.ChromeOptions() chrome_opt.add_argument('--disable-gpu') path = r"D:/tools/chromedriver/chromedriver.exe" driver = webdriver.Chrome(executable_path=path,chrome_options=chrome_opt)