Selenium ends randomly with uncaught error

2019-08-11 02:51发布

I'm using mocha, webdriverio, phantomjs Trying to find a way why Selenium is failing in random cases (50% its ok, 50% breaks in different tests with the same code).

The error is

Uncaught RuntimeError
(UnknownError:13) An unknown server-side error occurred while processing the command.
Problem: POST /session//url
Build info: version: '2.42.0', revision: '5e82430', time: '2014-05-22 19:00:03'
System info: host: 'example.com', ip: '127.0.0.1', os.name: 'Linux', os.arch: 'amd64', os.version: '2.6.20', java.version: '1.7.1'
Driver info: driver.version: unknown

In fact driver info is EventFiringWebDriver and sometimes it doesn't shown.

Looked through the internet and can't find any solutions. Tests are asynchronus, but 1 to 1 as in the example, the total ammount is about 200, timeout is made really big, it's not a problem.

1条回答
Lonely孤独者°
2楼-- · 2019-08-11 03:15

The issue is pretty old and could be found here https://github.com/detro/ghostdriver/issues/140

Could be partly fixed with this http://matejtymes.blogspot.co.uk/2014/10/webdriver-fix-for-unreachablebrowserexc.html but you need to rebuild selenium from sources (not so difficult :))

查看更多
登录 后发表回答