Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.
Evan N3,244 Points
I am returning an error after I create "const driver = new selenium.Builder().forBrowser("chrome").build();" in noderepl
Hi everyone, I am running into a problem within my node repl on MacOS where it throws back an ECONNREFUSED with the specified port. Is there an easy workaround for this? In the meantime, I am going to google the exact error.
Thank you all,
> const driver = new selenium.Builder().forBrowser("chrome").build(); undefined > /Users/evan/Documents/Treehouse/Selenium/node_modules/selenium-webdriver/lib/promise.js:2634 throw error; ^ Error: ECONNREFUSED connect ECONNREFUSED 127.0.0.1:55130 at ClientRequest.<anonymous> (/Users/evan/Documents/Treehouse/Selenium/node_modules/selenium-webdriver/http/index.js:238:15) at emitOne (events.js:96:13) at ClientRequest.emit (events.js:188:7) at Socket.socketErrorListener (_http_client.js:310:9) at emitOne (events.js:96:13) at Socket.emit (events.js:188:7) at emitErrorNT (net.js:1278:8) at _combinedTickCallback (internal/process/next_tick.js:74:11) at process._tickDomainCallback (internal/process/next_tick.js:122:9) From: Task: WebDriver.createSession() at Function.createSession (/Users/evan/Documents/Treehouse/Selenium/node_modules/selenium-webdriver/lib/webdriver.js:769:24) at Function.createSession (/Users/evan/Documents/Treehouse/Selenium/node_modules/selenium-webdriver/chrome.js:761:15) at createDriver (/Users/evan/Documents/Treehouse/Selenium/node_modules/selenium-webdriver/index.js:170:33) at Builder.build (/Users/evan/Documents/Treehouse/Selenium/node_modules/selenium-webdriver/index.js:642:16) at repl:1:60 at sigintHandlersWrap (vm.js:22:35) at sigintHandlersWrap (vm.js:96:12) at ContextifyScript.Script.runInThisContext (vm.js:21:12) at REPLServer.defaultEval (repl.js:340:29) at bound (domain.js:280:14) '''
Craig DennisTreehouse Teacher
Hmm... I noticed in another post you had Selenium already set up for Python. Stab in the dark here but, is it possible you have an environment variable set? That port seems fishy.
env in your console and look for any variable that starts with
How did you update chromedriver to the latest via npm? I tried npm install chromedriver --chromedriver_version=LATEST but it still shows old version ChromeDriver 2.20.353145 (343b531d31eeb933ec778dbcf7081628a1396067)
Please advise. Thank you
I found out that I need to delete the chromedriver files in the following locations after running command "where chromedriver"
C:\Jars\chromedriver.exe C:\Users\Tom\AppData\Roaming\npm\chromedriver C:\Users\Tom\AppData\Roaming\npm\chromedriver.cmd