Skip to content

Add msedge to sauce.conf.js. - #4260

Closed
jdalton wants to merge 1 commit into
angular:masterfrom
jdalton:msedge
Closed

jdalton wants to merge 1 commit into
angular:masterfrom
jdalton:msedge

Conversation

@jdalton

@jdalton jdalton commented Sep 18, 2015

Copy link
Copy Markdown
Contributor

Add to the sauce runner.

@googlebot

Copy link
Copy Markdown

Thanks for your pull request. It looks like this may be your first contribution to a Google open source project, in which case you'll need to sign a Contributor License Agreement (CLA).

📝 Please visit https://cla.developers.google.com/ to sign.

Once you've signed, please reply here (e.g. I signed it!) and we'll verify. Thanks.


  • If you've already signed a CLA, it's possible we don't have your GitHub username or you're using a different email address. Check your existing CLA data and verify that your email is set on your git commits.
  • If you signed the CLA as a corporation, please let us know the company's name.

@jdalton

jdalton commented Sep 18, 2015

Copy link
Copy Markdown
Contributor Author

May be more involved in you all depend on a specific selenium version but the gist of what to do is included in the PR if someone more familiar with the Angular flow wants to take the ball.

@googlebot

Copy link
Copy Markdown

CLAs look good, thanks!

@marclaval

Copy link
Copy Markdown
Contributor

Relaunched the build and found some issues with Edge:

  1. It is identified as Chrome 42 by Karma -> Karma to be updated

  2. Edge gets disconnected before running all tests:

ERROR [launcher.sauce]: Heartbeat to microsoftedge 20.10240 (Windows 10) failed
  [title()] Error response status: 13, , UnknownError - An unknown server-side error occurred while processing the command. Selenium error: unknown error (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 328 milliseconds
Build info: version: '2.47.1', revision: '411b314', time: '2015-07-30 03:03:16'
System info: host: 'WIN-SB3ER6JQ6ME', ip: '172.20.20.203', os.name: 'Windows 8.1', os.arch: 'x86', os.version: '6.3', java.version: '1.8.0_51'
Driver info: org.openqa.selenium.edge.EdgeDriver
Capabilities [{acceptSslCerts=true, browserVersion=20.10240.16384.0, platformVersion=10, browserName=MicrosoftEdge, takesScreenshot=true, pageLoadStrategy=normal, takesElementScreenshot=true, platformName=windows, platform=ANY}]
Session ID: XXXXXXXX-XXXX-XXXX-XXXX-XXXX9C9B8746
WARN [Chrome 42.0.2311 (Windows)]: Disconnected (1 times)
Chrome 42.0.2311 (Windows): Executed 399 of 0 (skipped 1) DISCONNECTED (3 mins 2.474 secs / 38.669 secs)

@jdalton: have you seen such errors already please?

@jdalton

jdalton commented Sep 25, 2015

Copy link
Copy Markdown
Contributor Author

Thanks @Mlaval! In my use of Sauce I haven't issues but I run the rest api. I've setup Edge testing with Underscore and Backbone which use Karma and their's works (though they could be using the rest API too).

Any ideas @jonah?

@marclaval

Copy link
Copy Markdown
Contributor

I've got the same issue locally. Edge disconnects and the campaign restarts automatically, ending up in an infinite loop.

When opening the dev tools to find more details, I bump into another bug due to the way systemjs loads scripts.
Basically it does:

var head = document.head;
var script = document.createElement('script');
script.text = 'some javascript code';
head.appendChild(script);
head.removeChild(script);

See https://github.com/systemjs/systemjs/blob/master/lib/global-eval.js#L71
At the some point, the script loaded is not evaluated.
It happens always for the same script, as if a limit is reached.
The campaign doesn't even start in that case, that's a different issue.
Note that the same problem is also in IE11.

After hacking systemjs to change the load mechanism, the campaign is finally successful ...

@jdalton

jdalton commented Sep 25, 2015

Copy link
Copy Markdown
Contributor Author

If using SystemJS you'll need to include their shim script, dist/system-polyfills.js, for URL too. Related to systemjs/systemjs@47d9bf0 and ModuleLoader/es-module-loader#398.

@marclaval

Copy link
Copy Markdown
Contributor

@jdalton

jdalton commented Sep 25, 2015

Copy link
Copy Markdown
Contributor Author

Hmmm... pinging @guybedford.

@guybedford

Copy link
Copy Markdown

I'd suggest upgrading to SystemJS 0.19.3 here and seeing if the error still persists as we recently fixed a critical IE loading bug.

@jdalton

jdalton commented Sep 27, 2015

Copy link
Copy Markdown
Contributor Author

@guybedford Do you have a reference handy for the bug. I'll report it on our end.

@marclaval

Copy link
Copy Markdown
Contributor

Upgrading to SystemJS 0.19.3 doesn't help, but I don't think this is the root cause here. I did some more investigations and there seems to be 2 distinct issues.

1) In Edge only, when the F12 dev tools are closed:
The browser disconnects in the middle of the campaign, and restarts it automatically.
I found out that 3 tests are causing the issue, but without obvious reason.
Deactivating them solves the problem: marclaval@b42cbcb ...

2) In both Edge and IE11, when the F12 dev tools are opened:
The browser doesn't load all the scripts. SystemJS does it this way: https://github.com/systemjs/systemjs/blob/master/lib/global-eval.js#L71-L102
What happens is that after having successfully loaded ~40 scripts, it doesn't work anymore for all the following attempts.
It can be easily spotted by adding some console.log to the script.text. It shows that the scripts are simply not evaluated, even if the <script> element is added to the <head>.
As a result, the campaign doesn't even start.
The very same phenomenon happens in both IE11 and Edge, with the very same scripts not loading.

Note that the campaign is successful in IE11 when the F12 dev tools are closed.

@guybedford

Copy link
Copy Markdown

@Mlaval thanks for the detailed report here. I can replicate this as well in the tests. It does sound like this is a limitation of this execution method in IE. I've created an issue in systemjs/systemjs#814 to track.

I'd suggest forking SystemJS for now and including the hack to ensure eval-based execution.

The thing is, we do need the inline script execution mode because many global scripts expect var MyGlobal = value to assign to the global object, and this is the only execution mode that gives us that.

Ideally some queueing mechanism or otherwise can be implemented to ensure we can get this to work in IE.

@marclaval

Copy link
Copy Markdown
Contributor

I'd like to stress out that this loading bug happens only when the F12 dev tools are opened.
It works just fine when they are closed.

@tbosch tbosch added the action: review The PR is still awaiting reviews from at least one requested reviewer label Sep 28, 2015
@jdalton

jdalton commented Sep 28, 2015

Copy link
Copy Markdown
Contributor Author

\cc @andysterland @jonathandturner

Comment thread sauce.conf.js

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd hold off with merging that until Sauce updates its Edge version number or it will start breaking after the fact.

@jdalton Do you know when they plan to do it? I contacted BrowserStack & they switched to "12.0".

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd hold off with merging that until Sauce updates its Edge version number or it will start breaking after the fact.

Sauce has been pretty good about not breaking folks with similar changes in the past, the existing '20.10240' is specific enough to avoid conflict for future versions too so I imagine they'll just alias it to '12'.

Do you know when they plan to do it?

I don't have an eta from them.
They've created an internal ticket with the request to change the version for MS Edge.

I contacted BrowserStack & they switched to "12.0".

Yap :D

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the existing '20.10240' is specific enough to avoid conflict for future versions too so I imagine they'll just alias it to '12'.

I don't fully know the Sauce Labs API as I mostly use BrowserStack but can you not pass just a major version, i.e. here 20? If you can then it will get in conflict with a future EdgeHTML 20 version, won't it?

OTH, the build number will be greater then so if they won't use the major only but continue to provide the build number, 20.SOMETHING_LARGE should be preferred to 20.10240 when you just specify 20.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm we'll see.

@marclaval

Copy link
Copy Markdown
Contributor

Same issues still happening after the big update to latest Node.js and Karma

@pkozlowski-opensource

Copy link
Copy Markdown
Member

Edge support landed via 427860a. There is still an issue to be solved (few tests were disabled) but this is being tracked via #4756

@angular-automatic-lock-bot

Copy link
Copy Markdown

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: review The PR is still awaiting reviews from at least one requested reviewer cla: yes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants