平时工作中用web 自动化做点事情,结果之前写好的脚本运行一直正常的,某一天莫名其妙不行了,一直报下面这个错。
unknown error: call function result missing 'value'
后来发现是chrome自动更新版本后和原来的webdriver 的版本不匹配了。重新下一个匹配的webdriver 就可以了。
可以从以下网站下载到 chrom webdriver 网站。
http://chromedriver.storage.googleapis.com/
http://npm.taobao.org/mirrors/chromedriver/
在每个版本中都有一个notes.txt, 文件里会写明webdriver 和chrome 对应的版本。
----------ChromeDriver v2.37 (2018-03-16)---------- Supports Chrome v64-66 Resolved issue 2304: Test ChromeDriverSiteIsolation.testCanClickOOPIF fails on Chrome v66 for all desktop platforms [[Pri-1]] Resolved issue 1940: Many window command endpoints are unimplemented in Chromedriver [[Pri-2]] Resolved issue 1937: Get element rect is not implemented [[Pri-2]] Resolved issue 2329: ChromeDriver does not allow value of 0 for extensionLoadTimeout option [[Pri-2]] ----------ChromeDriver v2.36 (2018-03-02)---------- Supports Chrome v63-65 Resolved issue 1819: testIFrameWithExtensionsSource is failing on Chrome v60+ [[Pri-1]] Resolved issue 2221: Add command-line option to log INFO level to stderr [[Pri-2]] Resolved issue 450: ChromeDriver hangs when switching to new window whose document is being overwritten [[Pri-2]] Resolved issue 2235: Add option to control the wait for extension background pages [[Pri-2]] Resolved issue 2234: fixed webview_devtools_remote_ is not right [[Pri-2]] Resolved issue 2223: Unable to load extension if background page name starts with / [[Pri-2]] Resolved issue 2280: ChromeDriver should be more extensible [[Pri-]] Resolved issue 2231: Pixel 2 and Pixel 2 XL not working in Mobile Emulation [[Pri-]] Resolved issue 746266: Chromedriver does not support OOPIF ......