Protractor has stopped working with latest version of Chrome
Bug report
- Node Version:
6.10.0 - Protractor Version:
5.1.2 - Angular Version:
4.3.6 - Browser(s):
Chrome 61.0.3163.91 - Operating System and Version
Windows 10
Our protractor tests have been running fine with Chrome v60 but since upgrading to v61 they won't start.
I'm seeing the following errors when the tests start up and then the browser just hangs eventually timing out the tests:
[11:37:09] I/launcher - Running 1 instances of WebDriver
[11:37:09] I/direct - Using ChromeDriver directly...
[135932:134088:0920/113710.527:ERROR:gl_surface_egl.cc(744)] eglInitialize D3D9 failed with error EGL_NOT_INITIALIZED
[135932:134088:0920/113710.527:ERROR:gl_initializer_win.cc(232)] GLSurfaceEGL::InitializeOneOff failed.
[135932:134088:0920/113710.593:ERROR:gpu_child_thread.cc(252)] Exiting GPU process due to errors during initialization
[130032:95456:0920/113710.599:ERROR:browser_gpu_channel_host_factory.cc(103)] Failed to launch GPU process.
Hi @kaiza
Which version of ChromeDriver are you using, can you also paste a piece of your config here?
Chrome 61 + ChromeDriver 2.32 + OSX 10.12.6 are still working here, we only have a click / scroll issue but that's possibly a bug in the ChromeDriver
Here's the config:
const { SpecReporter } = require('jasmine-spec-reporter');
const HtmlScreenshotReporter = require('protractor-jasmine2-screenshot-reporter');
const screenshotReporter = new HtmlScreenshotReporter({
dest: 'e2e/screenshots',
filename: 'screenshots.html'
});
exports.config = {
allScriptsTimeout: 60000,
specs: [
'./e2e/**/*.e2e-spec.ts'
],
capabilities: {
'browserName': 'chrome',
'chromeOptions': {
'args': ['--no-sandbox'],
'mobileEmulation': {
'deviceMetrics': {
'width': 1280,
'height': 1024
}
}
}
},
directConnect: true,
baseUrl: 'http://localhost:4200/',
framework: 'jasmine',
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 60000,
print: function() {}
},
beforeLaunch: function() {
require('ts-node').register({
project: 'e2e/tsconfig.e2e.json'
});
return new Promise(function(resolve){
screenshotReporter.beforeLaunch(resolve);
});
},
onPrepare() {
jasmine.getEnv().addReporter(new SpecReporter({ spec: { displayStacktrace: true } }));
jasmine.getEnv().addReporter(screenshotReporter);
},
afterLaunch: function(exitCode) {
return new Promise(function(resolve){
screenshotReporter.afterLaunch(resolve.bind(this, exitCode));
});
}
};
And ChromeDriver version is 2.32
Hmm, doesn't look that strange, what happens if you don't use directConnect and use a local seleniumServer?
I'll give seleniumServer a go.
Just noticed something else though. The first test does actually complete and then it's like it gets stuck. If I press enter in the address bar of the chrome window it then continues running fine.
Ok, looks like there is a different problem. Curious what the outcome will be
Looks like it has something to do with the screenshot reporter. Took out all references to it and now everything runs fine.
Ok, tnx,
I'm going to close it for now because it looks like an issue with a third-party module. Tnx for the feedback on it