question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

'directConnect: true' has issues for Chrome Driver

See original GitHub issue

Could some please help take a look at below issue? Here’re my config files and error logs.

Config file, local.js

'use strict';

let config = require('./default').config;

config.capabilities = {
       browserName: 'chrome',
       chromeOptions: {
           'args': ['--start-maximized', 'disable-infobars', 'disable-gpu', 'incognito']
       }
     };

config.directConnect = true;

config.specs = ['../specs/*.spec.js'];

exports.config = config;

Command config

"local": "node_modules/.bin/protractor ./src/config/local.js --baseUrl=https://angularjs.org",

Command npm run local

error logs

> protractor_jasmine@1.0.0 local /Users/shanliu/Projects/protractor_jasmine
> protractor ./src/config/local.js --baseUrl=https://angularjs.org

(node:76217) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.
[18:04:22] W/driverProviders - Using driver provider directConnect, but also found extra driver provider parameter(s): seleniumAddress
[18:04:22] I/launcher - Running 1 instances of WebDriver
[18:04:22] I/direct - Using ChromeDriver directly...
[18:04:22] E/direct - Error code: 135
[18:04:22] E/direct - Error message: Could not find update-config.json. Run 'webdriver-manager update' to download binaries.
[18:04:22] E/direct - Error: Could not find update-config.json. Run 'webdriver-manager update' to download binaries.
    at Direct.getNewDriver (/Users/shanliu/Projects/protractor_jasmine/node_modules/protractor/built/driverProviders/direct.js:63:31)
    at Runner.createBrowser (/Users/shanliu/Projects/protractor_jasmine/node_modules/protractor/built/runner.js:195:43)
    at q.then.then (/Users/shanliu/Projects/protractor_jasmine/node_modules/protractor/built/runner.js:339:29)
    at _fulfilled (/Users/shanliu/Projects/protractor_jasmine/node_modules/q/q.js:834:54)
    at /Users/shanliu/Projects/protractor_jasmine/node_modules/q/q.js:863:30
    at Promise.promise.promiseDispatch (/Users/shanliu/Projects/protractor_jasmine/node_modules/q/q.js:796:13)
    at /Users/shanliu/Projects/protractor_jasmine/node_modules/q/q.js:556:49
    at runSingle (/Users/shanliu/Projects/protractor_jasmine/node_modules/q/q.js:137:13)
    at flush (/Users/shanliu/Projects/protractor_jasmine/node_modules/q/q.js:125:13)
    at process._tickCallback (internal/process/next_tick.js:61:11)
[18:04:22] E/launcher - Process exited with error code 135
npm ERR! code ELIFECYCLE
npm ERR! errno 135
npm ERR! protractor_jasmine@1.0.0 local: `protractor ./src/config/local.js --baseUrl=https://angularjs.org`
npm ERR! Exit status 135
npm ERR! 
npm ERR! Failed at the protractor_jasmine@1.0.0 local script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/shanliu/.npm/_logs/2018-07-18T10_04_22_458Z-debug.log
------------------------------------------------------------

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
nishankkumar1994commented, Feb 13, 2019

Please make sure to install npm install protractor

Update web driver manager webdriver-manager update

Run this command from your root node node_modules\protractor\bin\webdriver-manager update

Now start up a server with: webdriver-manager start

Also make sure that your protractor.conf.js file has below line // baseUrl: 'http://localhost:4200/', seleniumAddress: 'http://localhost:4444/wd/hub/',

Now run your e2e tests on different browsers ng e2e

1reaction
IgorSasovetscommented, Jul 19, 2018

Try to run node_modules/protractor/bin/webdriver-manager update from project root folder.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Using protractor with directconnect=true - how to fix
But there is an exception, the chrome browser version is very high, but your protractor is a very low version and its binded...
Read more >
Angularjs – protractor fails to run with directConnect – iTecNote
When I run protractor with directConnect: true , I get: Using ChromeDriver directly… [launcher] Running 1 instances of WebDriver Error: spawn ENOENT
Read more >
What is the use of directConnect in Protractor? - ProgramsBuzz
directConnect : true – Your test script communicates directly Chrome Driver or Firefox Driver, bypassing any Selenium Server. If this is true ...
Read more >
Protractor console logs when run with directConnect:True
directConnet=true bypasses SeleniumServer and execute against Chrome driver and Firefox driver . If you are using other than chrome or ...
Read more >
Setting Up the Selenium Server - Protractor
directConnect : true - Your test script communicates directly Chrome Driver or Firefox Driver, bypassing any Selenium Server. If this is true, settings...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found