protractor: Protractor fails with error code 199 on WebDriver.createSession()
Hi guys. I am using angular-cli and protractor fails to run my tests. I am sitting behind a corporate proxy which I add as a param when updating the webdriver. This is the output I get:
$ ./node_modules/.bin/webdriver-manager update --proxy=proxy_url_here
[15:11:28] I/update - selenium standalone: file exists C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\node_modules\webdriver-manager\selenium\selenium-server-standalone-3.4.0.jar
[15:11:28] I/update - selenium standalone: selenium-server-standalone-3.4.0.jar up to date
[15:11:28] E/downloader - undefined
[15:11:28] I/update - geckodriver: file exists C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\node_modules\webdriver-manager\selenium\geckodriver-v0.17.0.zip
[15:11:28] I/update - geckodriver: unzipping geckodriver-v0.17.0.zip
(node:12156) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Invalid filename
[15:11:28] I/update - chromedriver: unzipping chromedriver_2.30.zip
$ ./node_modules/.bin/protractor ./protractor.conf.js
[15:26:13] I/launcher - Running 1 instances of WebDriver
[15:26:13] I/direct - Using ChromeDriver directly...
[15:26:15] E/launcher - spawn UNKNOWN
[15:26:15] E/launcher - Error: spawn UNKNOWN
at exports._errnoException (util.js:1022:11)
at ChildProcess.spawn (internal/child_process.js:313:11)
at Object.exports.spawn (child_process.js:380:9)
at exec (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\selenium-webdriver\io\exec.js:116:27)
at resolveCommandLineFlags.then.args (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\selenium-webdriver\remote\index.js:219:25)
at process._tickCallback (internal/process/next_tick.js:103:7)
From: Task: WebDriver.createSession()
at Function.createSession (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\selenium-webdriver\lib\webdriver.js:777:24)
at Function.createSession (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\selenium-webdriver\chrome.js:709:29)
at Direct.getNewDriver (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\lib\driverProviders\direct.ts:90:25)
at Runner.createBrowser (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\lib\runner.ts:225:39)
at q.then.then (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\lib\runner.ts:391:27)
at _fulfilled (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\node_modules\q\q.js:834:54)
at self.promiseDispatch.done (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\node_modules\q\q.js:863:30)
at Promise.promise.promiseDispatch (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\node_modules\q\q.js:796:13)
at C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\node_modules\q\q.js:556:49
at runSingle (C:\Users\g8uibf\Projects\mbsportal-ui\node_modules\protractor\node_modules\q\q.js:137:13)
[15:26:15] E/launcher - Process exited with error code 199
- Node Version:
v6.9.5
- Protractor Version:
5.1.2
- Angular Version:
4
- Browser(s):
chrome 58
- Operating System and Version
Windows 10
- Your protractor configuration file
const { SpecReporter } = require('jasmine-spec-reporter');
exports.config = {
allScriptsTimeout: 11000,
specs: [
'./e2e/**/*.e2e-spec.ts'
],
capabilities: {
'browserName': 'chrome'
},
directConnect: true,
baseUrl: 'http://localhost:8080/',
framework: 'jasmine',
jasmineNodeOpts: {
showColors: true,
defaultTimeoutInterval: 30000,
print: function() {}
},
onPrepare() {
require('ts-node').register({
project: 'e2e/tsconfig.e2e.json'
});
jasmine.getEnv().addReporter(new SpecReporter({ spec: { displayStacktrace: true } }));
}
};
Thank you for the help in advance!
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Reactions: 15
- Comments: 41 (8 by maintainers)
Commits related to this issue
- fixes protractor failing with error code 199 - https://github.com/angular/protractor/issues/4347 — committed to mitchell852/trafficcontrol by mitchell852 5 years ago
- fixes protractor failing with error code 199 - https://github.com/angular/protractor/issues/4347 (#3551) — committed to apache/trafficcontrol by mitchell852 5 years ago
For those still have this issue, after checking the official FAQ, I fixed the issue by adding the flag
--no-sandbox
for Chrome 66.Hi Team, Even i am facing the issue webdriver-manager status
[14:56:47] I/status - selenium standalone version available: 3.141.59 [last] [14:56:47] I/status - chromedriver version available: 87.0.4280.88 [last] [14:56:47] I/status - geckodriver version available: v0.28.0 [last] [14:56:47] I/status - android-sdk is not present [14:56:47] I/status - appium is not present
@amit-kumar88 In your
protractor.conf.js
:Same for me, my issue was solved by downgrading chromedriver to 2.29.
I used the solution of @rkrisztian from the issue #98 to fix my chrome driver version:
package.json
protractor.ci.conf.js
Chromedriver 2.31 still crash…
The issue was reproduced with Chrome 59, protractor 5.1.2, chromedriver 2.30, Windows 10. After removing all latest Windows July updates the issue disappeared. Maybe it helps for somebody.
same issue : [17:39:49] I/launcher - Running 1 instances of WebDriver [17:39:49] I/direct - Using ChromeDriver directly… [17:39:49] E/launcher - spawn Unknown system error -86 [17:39:49] E/launcher - Error: spawn Unknown system error -86 at ChildProcess.spawn (internal/child_process.js:407:11) at Object.spawn (child_process.js:548:9) at exec (/Applications/Projects/atom-web/node_modules/selenium-webdriver/io/exec.js:116:27) at /Applications/Projects/atom-web/node_modules/selenium-webdriver/remote/index.js:219:25 at processTicksAndRejections (internal/process/task_queues.js:97:5) From: Task: WebDriver.createSession() at Function.createSession (/Applications/Projects/atom-web/node_modules/selenium-webdriver/lib/webdriver.js:769:24) at Function.createSession (/Applications/Projects/atom-web/node_modules/selenium-webdriver/chrome.js:761:15) at Direct.getNewDriver (/Applications/Projects/atom-web/node_modules/protractor/built/driverProviders/direct.js:77:33) at Runner.createBrowser (/Applications/Projects/atom-web/node_modules/protractor/built/runner.js:195:43) at /Applications/Projects/atom-web/node_modules/protractor/built/runner.js:339:29 at _fulfilled (/Applications/Projects/atom-web/node_modules/protractor/node_modules/q/q.js:834:54) at /Applications/Projects/atom-web/node_modules/protractor/node_modules/q/q.js:863:30 at Promise.promise.promiseDispatch (/Applications/Projects/atom-web/node_modules/protractor/node_modules/q/q.js:796:13) at /Applications/Projects/atom-web/node_modules/protractor/node_modules/q/q.js:556:49 at runSingle (/Applications/Projects/atom-web/node_modules/protractor/node_modules/q/q.js:137:13) [17:39:49] E/launcher - Process exited with error code 199
above solutions are not working
Downgrading a driver seems like a workaround rather than a fix?
And what “error code 199” means, after all?
…and “error code 135”?
What sense has “finding the solution”, when you don’t even know what is the problem?
I am getting this error now. E/launcher - EACCES connect EACCES 127.0.0.1:4444