IE Stability issue - WebDriverError
See original GitHub issueNode version: 7.4.0 Protractor version: 5.1.1 Operating system: Windows 7 Browser: Internet Explorer 11
I recently upgraded to Protractor 5.1.1 and started to seeing this error show up occasionally:
WebDriverError: JavaScript error (WARNING: The server did not provide any stacktrace information) Command duration or timeout: 49 milliseconds
It seems to be coming from the following code under *\lib\browser.ts
return this.driver.wait(() => {
return this.executeScriptWithDescription('return window.location.href;', msg('get url'))
.then(
(url: any) => {
return url !== this.resetUrl;
},
(err: IError) => {
if (err.code == 13 || err.name === 'JavascriptError') {
// Ignore the error, and continue trying. This is
// because IE driver sometimes (~1%) will throw an
// unknown error from this execution. See
// https://github.com/angular/protractor/issues/841
// This shouldn't mask errors because it will fail
// with the timeout anyway.
return false;
} else {
throw err;
}
});
If I change the the line above from
if (err.code == 13 || err.name === 'JavascriptError')
to
if (err.code == 13 || err.name === 'JavascriptError' || err.name === WebDriverError)
then the problem goes away.
Issue Analytics
- State:
- Created 6 years ago
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Unable to open IE11 driver instance using Selenium ...
You cannot open IE browser instance if Protected Mode settings are not the same for all zones OR if the browser is zoomed....
Read more >Top 10 Selenium Exceptions and How To Handle These ...
Handling Exceptions in Selenium WebDriver - In this tutorial we will learn about types of exceptions and how to handle top 10 most...
Read more >Selenium WebDriver -- Fix for 3 common IE errors - YouTube
http://www.joecolantonio.comThis video shows you how to fix three of the most common Selenium WebDriver IE issues :-Protected Mode settings ...
Read more >angular/protractor - Gitter
Just an update. Found some questions on Stackoverflow pointing to using $interval instead of $timeout resulting in protractor not waiting for the timeout....
Read more >selenium-webdriver 0.1.3 → 0.1.4 - Diffend
+ * Improve IE driver stability, IE9 support ... + * Fix bug where Element#disabled? would alternate between true/false (r11438).
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I reported this issue previously and it was closed with a reference to 4149. However, that reference is to a different issue.
I have the same issues as OP. The first IE test fails in approximately every second test run. The changes proposed in the first post fix the issues for me locally. Is somebody still on this?