求助:robot启动搜狗浏览器,但是如法控制浏览器,求大神们支招,多谢
robot自动化需要使用搜狗浏览器执行自动化用例,当前使用搜狗最新版本11.0.1.34551,内核为Chrome/80.0.3987.87,chromedriver/80.0.3987.16/,执行用例,只能打开搜狗浏览器,但是不能控制搜狗浏览器,用例执行一分钟后失败,报错如下:20220401 09:21:35.513 :INFO : Opening browser 'chrome' to base url 'http://www.baidu.com'.
20220401 09:21:36.405 : DEBUG : POST http://127.0.0.1:2030/session {"capabilities": {"firstMatch": [{}], "alwaysMatch": {"browserName": "chrome", "platformName": "any", "goog:chromeOptions": {"extensions": [], "binary": "C:\\Users\\xiaobing\\AppData\\Local\\SogouExplorer\\SogouExplorer.exe", "args": []}}}, "desiredCapabilities": {"browserName": "chrome", "version": "", "platform": "ANY", "goog:chromeOptions": {"extensions": [], "binary": "C:\\Users\\xiaobing\\AppData\\Local\\SogouExplorer\\SogouExplorer.exe", "args": []}}}
20220401 09:21:36.405 : DEBUG : Starting new HTTP connection (1): 127.0.0.1:2030
20220401 09:22:36.629 : DEBUG : http://127.0.0.1:2030 "POST /session HTTP/1.1" 500 953
20220401 09:22:36.629 : DEBUG : Finished Request
20220401 09:22:38.647 :INFO : Cannot capture screenshot because no browser is open.
20220401 09:22:38.653 :FAIL :
WebDriverException: Message: unknown error: DevToolsActivePort file doesn't exist
chromedriver试替换为高版本81,也报同样的错
用例:
Open Browser http://www.baidu.com chrome options=add_argument("--headless");add_argument("--no-sandbox");add_argument("--disable-gpu");add_argument("--disable-dev-shm-usage"); options=binary_location=r"C:\\Users\\xiaobing\\AppData\\Local\\SogouExplorer\\SogouExplorer.exe"
求大神们支招,多谢
用谷歌浏览器啊,用什么搜狗 DevToolsActivePort file doesn't exist 翻译一下,就是这个文件不存在
页:
[1]