您的位置:首页 > 移动开发

第一次使用appium web driver遇到的两个问题

2017-11-19 16:40 561 查看
首次使用appium web driver,不说搭建环境的麻烦,初次写完一个操作计算器的程序,但是运行一直报错:selenium.common.exceptions.WebDriverException:
Message: The URL '/wd/hub//session' did not map to a valid resource。查了好多百度资料,也没找到原因。最后发现是driver = webdriver.Remote('http://127.0.0.1:4723/wd/hub/',
desired_caps),多写了一个“/”,这也太不智能了。
改完后又出现另一个问题:WebDriverException:
Message: Parameters were incorrect. We wanted {"required":["desiredCapabilities"],"optional":["requiredCapabilities","sessionId","id"]} and you sent ["capabilities","desiredCapabilities"]。百度了一圈之后,才发现原来是selenium的版本太高了,把selenium版本降为3.0.1就好了。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: