Git Product home page Git Product logo

selenium-standalone's Introduction

Node.js Selenium Standalone Test Supported node versions

A node based CLI library for launching Selenium with WebDriver support.

Supported Drivers:

Available browsers

By default, Google Chrome, Firefox and Microsoft Edge are available when installed on the host system.

Starting from v6.22 chrome, edgechromium, and geckodriver support latest as version.

Starting from v9.0.6 supported changes regarding new storage for latest versions of chromedriver.

Starting from v9.2.0 added new feature 'onlyDriver'

Install & Run

As Global NPM Package

npm install selenium-standalone -g
selenium-standalone install && selenium-standalone start

As a Local NPM Package

npm install selenium-standalone --save-dev
npx selenium-standalone install && npx selenium-standalone start

As a Docker Service

docker run -it -p 4444:4444 webdriverio/selenium-standalone

If you run Chrome or Firefox tests within a Docker container make sure you set capabilities so that the session is headless, e.g.:

capabilities: {
  browserName: 'chrome',
  'goog:chromeOptions': {
    args: ['--no-sandbox', '--headless']
  }
}

or Firefox:

capabilities: {
  browserName: 'firefox',
  'moz:firefoxOptions': {
    args: ['-headless']
  }
}

If you are looking for more sophisticated Docker container that allows you to run browser, check out the Docker Selenium project.

Command line interface (CLI)

See CLI docs

Application Programming Interface (API)

See API docs

Tips

Examples of combining with other tools

πŸ‘©β€πŸ’» πŸ‘¨β€πŸ’» Contributing

You like this project and want to help making it better? Awesome! Have a look into our Contributor Documentation to get started with setting up the repo.

If you're looking for issues to help out with, check out the issues labelled "good first pick". You can also reach out in on Discord if you have question on where to start contributing.

selenium-standalone's People

Contributors

catalan-adobe avatar christian-bromann avatar daleharvey avatar dependabot[bot] avatar dfreedm avatar eric1234 avatar erwinheitzman avatar geskill avatar harsha509 avatar icecreamyou avatar jrit avatar jucrouzet avatar leventebalogh avatar lthurr avatar marsup avatar mgrybyk avatar molily avatar oleksiizozulenko avatar patthiel avatar plessbd avatar potapovdim avatar renovate-bot avatar renovate[bot] avatar seanpoulter avatar serbanghita avatar silvenon avatar stephenash avatar udarrr avatar vvo avatar wdio-bot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

selenium-standalone's Issues

Install hangs after "Installation finished" message

Downloading http://selenium-release.storage.googleapis.com/2.42/selenium-server-standalone-2.42.0.jar 200
Downloading http://chromedriver.storage.googleapis.com/2.9/chromedriver_mac32.zip 200
Unzipping http://chromedriver.storage.googleapis.com/2.9/chromedriver_mac32.zip
chmod+x chromedriver
Installation finished

Then it hangs :)

Error: Could not download http://selenium-release.storage.googleapis.com/2.41/selenium-server-standalone-2.41.0.jar

Error: Could not download http://selenium-release.storage.googleapis.com/2.41/selenium-server-standalone-2.41.0.jar
at ClientRequest.<anonymous> (/Users/mbenin/projects/copilot/node_modules/selenium-standalone/install.js:100:21)
at ClientRequest.g (events.js:180:16)
at ClientRequest.EventEmitter.emit (events.js:95:17)
at HTTPParser.parserOnIncomingClient [as onIncoming] (http.js:1688:21)
at HTTPParser.parserOnHeadersComplete [as onHeadersComplete] (http.js:121:23)
at Socket.socketOnData [as ondata] (http.js:1583:20)
at TCP.onread (net.js:527:27)

webdriverio-boneyard/grunt-webdriver#29

Gulp plugin

Would be good to have one which is also able to kill the process upon completion.

Stop?

How do we stop selenium-standalone programatically?

Empty "File from" output

With the following code I see weird outputs:

gulp.task('selenium-install', (cb) ->
  selenium.install({
    # Check for more recent versions of selenium here:
    # http://selenium-release.storage.googleapis.com/index.html
    version: '2.44.0',
    baseURL: 'http://selenium-release.storage.googleapis.com',
    drivers: {
      chrome: {
        # Check for more recent versions of chrome driver here:
        # http://chromedriver.storage.googleapis.com/index.html
        version: '2.14'
        arch:    process.arch
        baseURL: 'http://chromedriver.storage.googleapis.com'
      },
      ie: {
        # Check for more recent versions of internet explorer driver here:
        # http://selenium-release.storage.googleapis.com/index.html
        version: '2.44'
        arch:    process.arch
        baseURL: 'http://selenium-release.storage.googleapis.com'
      }
    },
    logger: (message) ->
      gutil.log(message)
  }, cb)
)
[14:09:56] Starting 'selenium-install'...
[14:09:56] ----------
[14:09:56] selenium-standalone installation starting
[14:09:56] ----------
[14:09:56] 
[14:09:56] ---
[14:09:56] selenium install:
[14:09:56] from: http://selenium-release.storage.googleapis.com/2.44/selenium-server-standalone-2.44.0.jar
[14:09:56] to: /home/xxx/node_modules/selenium-standalone/.selenium/selenium-server/2.44.0-server.jar
[14:09:56] ---
[14:09:56] chrome install:
[14:09:56] from: http://chromedriver.storage.googleapis.com/2.14/chromedriver_linux64.zip
[14:09:56] to: /home/xxx/node_modules/selenium-standalone/.selenium/chromedriver/2.14-x64-chromedriver
[14:09:56] ---
[14:09:56] File from
[14:09:56] ---
[14:09:56] File from
[14:09:56] 
[14:09:56] 
[14:09:56] -----
[14:09:56] selenium-standalone installation finished
[14:09:56] -----
[14:09:56] Finished 'selenium-install' after 458 ms

What do these [14:09:56] File from mean? They are empty and we have no idea what file.

Probably a bug?

Chrome diver not working - it pops up and closes immediately

Hi I am using the selenium-standalone alone with the webdriverIO for automation. with the latest version if I run my automation script on chrome browser, the chrome pops up and closes immediately hence test cases are failed. this issue is not appearing if I use older version of selenium-standalone which has the chrome version of 2.9. Please suggest me.

Proxy options not working

Greetings!

I'm trying to run selenium-standalone with proxy options as arguments. I tried this:
start-selenium -Dhttp.proxyHost=107.17.100.254 -Dhttp.proxyPort=8080
and programmatic way:

selenium = require 'selenium-standalone'
spawnOptions = stdio: 'pipe'
seleniumArgs = [
  '-debug'
  'PATH="path_to_phantomjs/bin:$PATH"'
  '-Dhttp.proxyHost=107.17.100.254'
  '-Dhttp.proxyPort=8080'
]
server = selenium(spawnOptions, seleniumArgs)
server.stdout.on 'data', (output) ->
  console.log(output)

Proxy was taken from http://proxylist.hidemyass.com/#proxy-search-form

How I tested my ip address:

webdriverio = require 'webdriverio'

options =
  desiredCapabilities:
    browserName: 'phantomjs'

webdriverio
  .remote(options)
  .init()
  .url('http://myhttp.info/')
  .getText 'h1', (err, res) ->
    console.log res
  .end()

In both cases I received my real ip address (if I use proxy with authentication - it still doesn't work). At the same time, if I use that proxy in https://github.com/mikeal/request or phantomjs/phridge setup - my real IP is hidden, as expected.
Can you please tell how can I use proxy with selenium-standalone?

Thanks in advance.

UPD: Also, I've noticed, that specifying the path to phantomjs via '-Dphantomjs.binary.path' does not work either, so may be the problem is not in proxy options.

npm cache not used; results in downloading every time

For users on slower connections, it is onerous to have to download fresh every time, as this node package seems to do:

> [email protected] install /Users/foo-bar/project-foo/node_modules/selenium-standalone
> node install.js

Downloading http://chromedriver.storage.googleapis.com/2.12/chromedriver_mac32.zip 200
Unzipping http://chromedriver.storage.googleapis.com/2.12/chromedriver_mac32.zip
Downloading http://selenium-release.storage.googleapis.com/2.44/selenium-server-standalone-2.44.0.jar 200
chmod+x chromedriver
Installation finished

How can this be fixed?

Problem when installing with NPM

Hello,

I'm having an error when installing with nom, here's a screenshot:

npm_error

It looks like it can't find the cookies module, I'm trying to figure this out. Can you help?

Thank you.

Add to REAMDE.me example to set it up in coffee script and how to test it

Here is how I just did it (which hopefully will help others (note that I also use a custom port))

code

require 'fluentnode'
wd       = require('wd');
selenium = require('selenium-standalone');

class App
  constructor: (show_Logs, port)->
    @server    = null
    @port      = port || 4447
    @wd_url    = "http://localhost:#{@port}"
    @wd_hub    = @wd_url.append("/wd/hub/static/resource/hub.html")
    @show_Logs = if typeof(show_Logs) is 'boolean' then show_Logs else true    # interesting issue here when trying to map this correctly

  startSeleniumServer: (next)=>
    spawnOptions = { stdio: 'pipe'}
    seleniumArgs = ['-Dwebdriver.chrome.driver=./node_modules/nodewebkit/nodewebkit/chromedriver', '-port',@port]

    @server = selenium(spawnOptions, seleniumArgs)
    if (@show_Logs)
      @server.stdout.on 'data', (output)-> console.log(output + "")
      @server.stderr.on 'data', (output)-> console.log(output.str().trim())

    @server.stderr.on 'data', (output)->
      if output.str().contains('Started org.openqa.jetty.jetty.Server@')
        next()

  stopSeleniumServer:(next) =>
    @server.on('exit', -> next())
    process.kill(@server.pid)

module.exports = App
return

test

App = require '../app/App'

describe 'test-App', ->
    show_Logs = false
    app = new App(show_Logs)

    it 'constructor',->
        App.assert_Is_Function()
        app.assert_Is_Object()
        assert_Is_Null(app.server)
        app.wd_url.assert_Contains('http').assert_Contains('localhost').assert_Contains(app.port)
        app.wd_hub.assert_Contains(app.wd_hub).assert_Contains('hub.html')
        app.show_Logs.assert_Is_False()

        new App(      ).show_Logs.assert_Is_True()
        new App(false ).show_Logs.assert_Is_False()
        new App(true  ).show_Logs.assert_Is_True()
        new App(0,1234).port     .assert_Is(1234)

    describe 'start and stop selenium server |', ->

        it 'check that server is NOT up',(done)->
            app.wd_url.GET (html)->
                assert_Is_Null(html)
                done()

        it 'App.startSeleniumServer', (done)->
            app.startSeleniumServer.assert_Is_Function()
            app.startSeleniumServer ->
                app.server.assert_Is_Not_Null()
                done();

        it 'check that server is up',(done)->
            app.wd_hub.GET (html)->
                html.assert_Contains('<title>WebDriver Hub</title>')
                done()

        it 'App.stopSeleniumServer', (done)->
            app.stopSeleniumServer(done)

        it 'check that server is NOT up',(done)->
            app.wd_url.GET (html)->
                assert_Is_Null(html)
                done()

    #see https://github.com/vvo/selenium-standalone/issues/40
    it 'feature: selenium-standalone is using strerr instead of stdout',(done)->
        selenium = require('selenium-standalone');
        spawnOptions = { stdio: 'pipe' }
        seleniumArgs = []
        server = new selenium(spawnOptions, seleniumArgs)
        server.stdout.on 'data', (output)->
            throw 'if this thowns, it means the bug is fixed :)'
        server.stderr.on 'data', (output)->
            output.str().assert_Contains('INFO - Launching a standalone server')
            process.kill(server.pid)
            done()

error when installing version 2.45

I tried to install version 2.45 (to fix this issue https://code.google.com/p/selenium/issues/detail?id=8088), and got the following error:

❯ selenium-standalone install --version 2.45
----------
selenium-standalone installation starting
----------


/usr/local/lib/node_modules/selenium-standalone/lib/compute-download-urls.js:14
eleniumVersion = opts.seleniumVersion.slice(0, opts.seleniumVersion.lastIndexO
                                                                    ^
TypeError: Object 2.45 has no method 'lastIndexOf'
    at computeDownloadUrls (/usr/local/lib/node_modules/selenium-standalone/lib/compute-download-urls.js:14:81)
    at Object.install (/usr/local/lib/node_modules/selenium-standalone/lib/install.js:50:14)
    at Object.actions.install (/usr/local/lib/node_modules/selenium-standalone/bin/selenium-standalone:79:14)
    at javaFound (/usr/local/lib/node_modules/selenium-standalone/bin/selenium-standalone:42:18)
    at /usr/local/lib/node_modules/selenium-standalone/node_modules/whereis/index.js:28:14
    at ChildProcess.exithandler (child_process.js:645:7)
    at ChildProcess.EventEmitter.emit (events.js:98:17)
    at maybeClose (child_process.js:753:16)
    at Socket.<anonymous> (child_process.js:966:11)
    at Socket.EventEmitter.emit (events.js:95:17)

phantomjs: Element is not currently visible and may not be manipulated

Hi!
I ran into a problem specifying phantomjs as one of my desiredCapabilities of selenium-standalone.

my set-up

I set up my selenium test stack using:

  • cucumber
  • webdriverio and
  • selenium-standalone

To be more precisely I'm initializing my client like so:

this.client = webdriverio.remote({
    desiredCapabilities: {
        browserName: 'phantomjs'
    },
//    logLevel: 'verbose',
    singleton: true
});
this.client.init();

For now I'm starting the selenium-standalone instance by running

$ start-selenium

Lastly I run my cucumber features by running the cucumber-js binary (via gulp).

Tools and versions

I "brew installed" phantomjs version 1.9.7
I'm running the current version of selenium-standalone
I installed webdriverio version 2.1.2

The point where I'm not able to go any further unaided

When setting the browserName Attribute to 'chrome' everything works fine. Setting it back to phantomjs makes the following error occur:

RuntimeError: RuntimeError
     (UnknownError:13) An unknown server-side error occurred while processing the command.
     Problem: Element is not currently visible and may not be manipulated

     Callstack:
     -> elementIdClick("2")
     -> click("#btn_login")

Here ist the sellenium server log:

15:02:37.648 INFO - Executing: [new session: Capabilities [{platform=ANY, javascriptEnabled=true, browserName=phantomjs, handlesAlerts=true, rotatable=true, locationContextEnabled=true, version=}]])
15:02:37.661 INFO - Creating a new session for Capabilities [{platform=ANY, javascriptEnabled=true, browserName=phantomjs, handlesAlerts=true, rotatable=true, locationContextEnabled=true, version=}]
15:02:37.685 INFO - executable: /usr/local/bin/phantomjs
15:02:37.685 INFO - port: 2547
15:02:37.685 INFO - arguments: [--webdriver=2547, --webdriver-logfile=/Users/niels/phantomjsdriver.log]
15:02:37.685 INFO - environment: {}
PhantomJS is launching GhostDriver...
[INFO  - 2014-08-27T13:02:39.168Z] GhostDriver - Main - running on port 2547
[INFO  - 2014-08-27T13:02:39.588Z] Session [6c9dde00-2dea-11e4-a28c-83955ee08517] - page.settings - {"XSSAuditingEnabled":false,"javascriptCanCloseWindows":true,"javascriptCanOpenWindows":true,"javascriptEnabled":true,"loadImages":true,"localToRemoteUrlAccessEnabled":false,"userAgent":"Mozilla/5.0 (Macintosh; PPC Mac OS X) AppleWebKit/534.34 (KHTML, like Gecko) PhantomJS/1.9.7 Safari/534.34","webSecurityEnabled":true}
[INFO  - 2014-08-27T13:02:39.589Z] Session [6c9dde00-2dea-11e4-a28c-83955ee08517] - page.customHeaders:  - {}
[INFO  - 2014-08-27T13:02:39.589Z] Session [6c9dde00-2dea-11e4-a28c-83955ee08517] - Session.negotiatedCapabilities - {"browserName":"phantomjs","version":"1.9.7","driverName":"ghostdriver","driverVersion":"1.1.0","platform":"mac-unknown-64bit","javascriptEnabled":true,"takesScreenshot":true,"handlesAlerts":false,"databaseEnabled":false,"locationContextEnabled":false,"applicationCacheEnabled":false,"browserConnectionEnabled":false,"cssSelectorsEnabled":true,"webStorageEnabled":false,"rotatable":false,"acceptSslCerts":false,"nativeEvents":true,"proxy":{"proxyType":"direct"}}
[INFO  - 2014-08-27T13:02:39.589Z] SessionManagerReqHand - _postNewSessionCommand - New Session Created: 6c9dde00-2dea-11e4-a28c-83955ee08517
15:02:39.638 INFO - Done: [new session: Capabilities [{platform=ANY, javascriptEnabled=true, browserName=phantomjs, handlesAlerts=true, rotatable=true, locationContextEnabled=true, version=}]]
15:02:39.650 INFO - Executing: [get: http://inform2.dev])
15:02:40.722 INFO - Done: [get: http://inform2.dev]
15:02:40.730 INFO - Executing: [find elements: By.id: su_username])
15:02:40.773 INFO - Done: [find elements: By.id: su_username]
15:02:40.780 INFO - Executing: [clear: 0 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_username]])
15:02:40.801 INFO - Done: [clear: 0 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_username]]
15:02:40.808 INFO - Executing: [send keys: 0 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_username], [i, n, o, s, t, u, d, i, o]])
15:02:40.847 INFO - Done: [send keys: 0 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_username], [i, n, o, s, t, u, d, i, o]]
15:02:40.853 INFO - Executing: [find elements: By.id: su_password])
15:02:40.867 INFO - Done: [find elements: By.id: su_password]
15:02:40.872 INFO - Executing: [clear: 1 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_password]])
15:02:40.895 INFO - Done: [clear: 1 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_password]]
15:02:40.900 INFO - Executing: [send keys: 1 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_password], [r, o, q, k, N, f, 0, r, t, 3, r]])
15:02:40.931 INFO - Done: [send keys: 1 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: su_password], [r, o, q, k, N, f, 0, r, t, 3, r]]
15:02:40.936 INFO - Executing: [find element: By.id: btn_login])
15:02:40.957 INFO - Done: [find element: By.id: btn_login]
15:02:40.961 INFO - Executing: [click: 2 [[PhantomJSDriver: phantomjs on MAC (6c9dde00-2dea-11e4-a28c-83955ee08517)] -> id: btn_login]])
15:02:42.715 WARN - Exception thrown
org.openqa.selenium.ElementNotVisibleException: {"errorMessage":"Element is not currently visible and may not be manipulated","request":{"headers":{"Accept-Encoding":"gzip,deflate","Connection":"Keep-Alive","Content-Length":"27","Content-Type":"application/json; charset=utf-8","Host":"localhost:2547","User-Agent":"Apache-HttpClient/4.3.2 (java 1.5)"},"httpVersion":"1.1","method":"POST","post":"{\"id\":\":wdc:1409144560748\"}","url":"/click","urlParsed":{"anchor":"","query":"","file":"click","directory":"/","path":"/click","relative":"/click","port":"","host":"","password":"","user":"","userInfo":"","authority":"","protocol":"","source":"/click","queryKey":{},"chunks":["click"]},"urlOriginal":"/session/6c9dde00-2dea-11e4-a28c-83955ee08517/element/%3Awdc%3A1409144560748/click"}}
Command duration or timeout: 132 milliseconds
Build info: version: '2.42.2', revision: '6a6995d', time: '2014-06-03 17:42:03'
System info: host: 'Inostudios-iMac.local', ip: '192.168.56.1', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.4', java.version: '1.7.0_45'
Session ID: 6c9dde00-2dea-11e4-a28c-83955ee08517
Driver info: org.openqa.selenium.phantomjs.PhantomJSDriver
Capabilities [{platform=MAC, acceptSslCerts=false, javascriptEnabled=true, browserName=phantomjs, rotatable=false, driverVersion=1.1.0, locationContextEnabled=false, version=1.9.7, cssSelectorsEnabled=true, databaseEnabled=false, handlesAlerts=false, browserConnectionEnabled=false, webStorageEnabled=false, nativeEvents=true, proxy={proxyType=direct}, applicationCacheEnabled=false, driverName=ghostdriver, takesScreenshot=true}]
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
    at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:204)
    at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:156)
    at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:599)
    at org.openqa.selenium.remote.RemoteWebElement.execute(RemoteWebElement.java:268)
    at org.openqa.selenium.remote.RemoteWebElement.click(RemoteWebElement.java:79)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at org.openqa.selenium.support.events.EventFiringWebDriver$EventFiringWebElement$1.invoke(EventFiringWebDriver.java:331)
    at com.sun.proxy.$Proxy4.click(Unknown Source)
    at org.openqa.selenium.support.events.EventFiringWebDriver$EventFiringWebElement.click(EventFiringWebDriver.java:344)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at org.openqa.selenium.remote.server.KnownElements$1.invoke(KnownElements.java:63)
    at com.sun.proxy.$Proxy5.click(Unknown Source)
    at org.openqa.selenium.remote.server.handler.ClickElement.call(ClickElement.java:29)
    at org.openqa.selenium.remote.server.handler.ClickElement.call(ClickElement.java:1)
    at java.util.concurrent.FutureTask.run(FutureTask.java:262)
    at org.openqa.selenium.remote.server.DefaultSession$1.run(DefaultSession.java:169)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
    at java.lang.Thread.run(Thread.java:744)
Caused by: org.openqa.selenium.remote.ScreenshotException: Screen shot has been taken
Build info: version: '2.42.2', revision: '6a6995d', time: '2014-06-03 17:42:03'
System info: host: 'Inostudios-iMac.local', ip: '192.168.56.1', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.4', java.version: '1.7.0_45'
Driver info: driver.version: RemoteWebDriver
    at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:136)
    ... 23 more
Caused by: org.openqa.selenium.remote.ErrorHandler$UnknownServerException: {"errorMessage":"Element is not currently visible and may not be manipulated","request":{"headers":{"Accept-Encoding":"gzip,deflate","Connection":"Keep-Alive","Content-Length":"27","Content-Type":"application/json; charset=utf-8","Host":"localhost:2547","User-Agent":"Apache-HttpClient/4.3.2 (java 1.5)"},"httpVersion":"1.1","method":"POST","post":"{\"id\":\":wdc:1409144560748\"}","url":"/click","urlParsed":{"anchor":"","query":"","file":"click","directory":"/","path":"/click","relative":"/click","port":"","host":"","password":"","user":"","userInfo":"","authority":"","protocol":"","source":"/click","queryKey":{},"chunks":["click"]},"urlOriginal":"/session/6c9dde00-2dea-11e4-a28c-83955ee08517/element/%3Awdc%3A1409144560748/click"}}
Build info: version: '2.42.2', revision: '6a6995d', time: '2014-06-03 17:42:03'
System info: host: 'Inostudios-iMac.local', ip: '192.168.56.1', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.4', java.version: '1.7.0_45'
Driver info: driver.version: unknown
15:02:42.722 WARN - Exception: {"errorMessage":"Element is not currently visible and may not be manipulated","request":{"headers":{"Accept-Encoding":"gzip,deflate","Connection":"Keep-Alive","Content-Length":"27","Content-Type":"application/json; charset=utf-8","Host":"localhost:2547","User-Agent":"Apache-HttpClient/4.3.2 (java 1.5)"},"httpVersion":"1.1","method":"POST","post":"{\"id\":\":wdc:1409144560748\"}","url":"/click","urlParsed":{"anchor":"","query":"","file":"click","directory":"/","path":"/click","relative":"/click","port":"","host":"","password":"","user":"","userInfo":"","authority":"","protocol":"","source":"/click","queryKey":{},"chunks":["click"]},"urlOriginal":"/session/6c9dde00-2dea-11e4-a28c-83955ee08517/element/%3Awdc%3A1409144560748/click"}}
Build info: version: '2.42.2', revision: '6a6995d', time: '2014-06-03 17:42:03'
System info: host: 'Inostudios-iMac.local', ip: '192.168.56.1', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.9.4', java.version: '1.7.0_45'
Driver info: driver.version: unknown

Thank you so much in advance!
Kind regards
Niels

Why Driver info: driver.version: unknown?

We have a remote build machine here, running all the tests before deployment.

It fails at the beginning of our end to end gulp tests with this error

[23:48:12] Starting 'test:e2e'...
FF
RuntimeError: RuntimeError
     (UnknownError:13) An unknown server-side error occurred while processing the command.
     Problem: POST /session//timeouts/async_script
Build info: version: '2.45.0', revision: '5017cb8', time: '2015-02-26 23:59:50'
System info: host: 'xxx', ip: '10.0.0.88', os.name: 'Linux', os.arch: 'amd64', os.version: '2.6.18-371.3.1.el5.centos.plus', java.version: '1.7.0_17'
Driver info: driver.version: unknown

Really surprised why driver version is unknown.

The chrome driver has been installed successfully:

[22:56:46] Using gulpfile ~/workspace/xxx-frontend-review/gulpfile.coffee
[22:56:46] Starting 'selenium:install'...
[22:56:46] ----------
[22:56:46] selenium-standalone installation starting
[22:56:46] ----------
[22:56:46] 
[22:56:46] ---
[22:56:46] selenium install:
[22:56:46] from: http://selenium-release.storage.googleapis.com/2.45/selenium-server-standalone-2.45.0.jar
[22:56:46] to: /home/buildagent/workspace/xxx-frontend-review/node_modules/selenium-standalone/.selenium/selenium-server/2.45.0-server.jar
[22:56:46] ---
[22:56:46] chrome install:
[22:56:46] from: http://chromedriver.storage.googleapis.com/2.14/chromedriver_linux64.zip
[22:56:46] to: /home/zzz/workspace/xxx-frontend-review/node_modules/selenium-standalone/.selenium/chromedriver/2.14-x64-chromedriver
[22:56:51] 
[22:56:51] 
[22:56:51] -----
[22:56:51] selenium-standalone installation finished
[22:56:51] -----
[22:56:51] Finished 'selenium:install' after 5.26 s

We just start selenium with selenium.start() inside gulp. Works fine on our local machines.

Any clues? It is architecture/hardware related or a bug?

IE does not match with current platform: LINUX

When running selenium-standalone start I spotted this obscure line

14:58:00.273 INFO - Default driver org.openqa.selenium.ie.InternetExplorerDriver registration is skipped: registration capabilities Capabilities [{platform=WINDOWS, ensureCleanSession=true, browserName=internet explorer, version=}] does not match with current platform: LINUX`

Should I be worried about this? Can't IE be run headlessly on Linux?

ECONNRESET in windows

Hey man,

that error is happening when i run node install.js in a win platform.
Do you know why and how to fix?

C:\test projects\selenium-standalone\install.js:29
throw err;
^
Error: read ECONNRESET
at errnoException (net.js:901:11)
at TCP.onread (net.js:556:19)
npm ERR! weird error 8
npm ERR! not ok code 0

Generic error when the jar is missing

When running selenium.start without having the jar in place, you end up with a generic error (timeout). Highlights two things, actually:

  • IMO there should be a specific error for this case (it'll probably be common for API usage)
  • selenium.start should listen to the exit event and generate an error if it has yet to start

Closing browsers

Everything seems to be working smoothly, except that my Firefox browser instance is left open after running all the tests. Is there a way to tell Selenium to close all the browser instances?

readme issue

You have:

npm install start-selenium -g

should be:

npm install selenium-standalone -g

selenium-standalone start Not working in Ubuntu 14.04 LTS

I'm getting this error when installed in ubuntu

 uname -a
Linux siva-HP-Mini-110-1100 3.13.0-32-generic #57-Ubuntu SMP Tue Jul 15 03:51:12 UTC 2014 i686 i686 i686 GNU/Linux
events.js:72
        throw er; // Unhandled 'error' event
              ^
Error: spawn ENOENT
    at errnoException (child_process.js:1011:11)
    at Process.ChildProcess._handle.onexit (child_process.js:802:34)

npm install failed when behind proxy

I got the following when I run
npm install selenium-standalone --verbose

[email protected] install .../node_modules/selenium-standalone
node install.js

Downloading http://chromedriver.storage.googleapis.com/2.9/chromedriver_linux64.zip
Downloading https://selenium.googlecode.com/files/selenium-server-standalone-2.39.0.jar

.../node_modules/selenium-standalone/install.js:28
throw err
^
Error: getaddrinfo ENOTFOUND
at errnoException (dns.js:37:11)
at Object.onanswer as oncomplete
npm info [email protected] Failed to exec install script
npm info .../node_modules/selenium-standalone unbuild
npm info preuninstall [email protected]
npm info uninstall [email protected]
npm verb true,.../node_modules,.../node_modules unbuild [email protected]
npm verb .../node_modules/.bin,[object Object] binRoot
npm info postuninstall [email protected]
npm ERR! weird error 8
npm verb exit [ 1, true ]
npm ERR! not ok code 0

Chromedriver.zip and Selenium-server-standalone.jar Downloads fail due to proxy format

Hey Guys,

I've run into an issue during the execution of install.js. The download of Chromedriver.zip and Selenium-server-standalone.jar fail because my proxy environment variable HTTP_PROXY is configured as follows 'http://login:password @ : '. After pulling the source code and debugging it a little I've identified the root cause of the issue in the getDownloadStream function. There is a regular expression used to parse the proxy string, however it only supports proxies in the format of 'http://proxy:uri:'. When processing my proxy string the wrong data is matched and the proxy URI is not correctly extracted.

Rather than mess with the regular expressions and make attempts to configure the http function's 'options' correctly i pulled down 'request' https://github.com/mikeal/request and did a slight refactor to see if i could get your install working with it. I was able to get the downloads working however I hit some stream issues on the unzip and write to disk, my lack of experience in the Node.js programming space isn't helping :)

So I think there are a couple ways to fix this issue as i see it

  1. get this working using the node.js http function by enhancing the regular expression(s) and then correctly setup the http function options object to support proxy authentication.
  2. get this working with 'request' as it handles all the proxy authentication for you.

I will tinker with option 2 a bit when i get some free time, however I figured one of the existing contributors might be able to figure this out and make the necessary changes before I get back to it.

Cheers!

npm install hangs at "Installation finished"

when running npm install, this package never fully finishes. It shows "Installation finished" and then shows the animated spinner. I have let it sit for several minutes. Is there a log perhaps I can check? --verbose mode with npm doesn't help.

> [email protected] install /path/node_modules/selenium-standalone
> node install.js

Downloading http://chromedriver.storage.googleapis.com/2.9/chromedriver_mac32.zip 200
Unzipping http://chromedriver.storage.googleapis.com/2.9/chromedriver_mac32.zip
Downloading http://selenium-release.storage.googleapis.com/2.42/selenium-server-standalone-2.42.0.jar 200
chmod+x chromedriver
Installation finished

Chrome driver does not launch‏

I had installed you awesome selenium-standalone server. When I run selenium-standalone start and an example script from https://github.com/admc/wd,

mocha ./examples/promise/mocha-specs.js

The chromedriver does not startup, could you please tell me what is the problem.

Message from terminal:

23:47:52.597 INFO - Executing: [new session: Capabilities [{browserName=chrome, javascriptEnabled=true, version=, platform=ANY}]])

23:47:52.609 INFO - Creating a new session for Capabilities [{browserName=chrome, javascriptEnabled=true, version=, platform=ANY}]

Starting ChromeDriver 2.14.313457 (3d645c400edf2e2c500566c9aa096063e707c9cf) on port 7240

Only local connections are allowed.

23:48:02.627 INFO - Executing: [new session: Capabilities [{browserName=chrome, javascriptEnabled=true, version=, platform=ANY}]])

23:48:02.629 INFO - Creating a new session for Capabilities [{browserName=chrome, javascriptEnabled=true, version=, platform=ANY}]

Starting ChromeDriver 2.14.313457 (3d645c400edf2e2c500566c9aa096063e707c9cf) on port 31279

Only local connections are allowed.

23:48:12.901 WARN - Exception thrown

java.util.concurrent.ExecutionException: org.openqa.selenium.WebDriverException: java.lang.reflect.InvocationTargetException

Build info: version: '2.45.0', revision: '5017cb8', time: '2015-02-26 23:59:50'

System info: host: 'localhost', ip: '127.0.0.1', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.10.1', java.version: '1.8.0_31'

Driver info: driver.version: unknown

at java.util.concurrent.FutureTask.report(FutureTask.java:122)

at java.util.concurrent.FutureTask.get(FutureTask.java:192)

at org.openqa.selenium.remote.server.DefaultSession.execute(DefaultSession.java:175)

at org.openqa.selenium.remote.server.DefaultSession.(DefaultSession.java:111)

at org.openqa.selenium.remote.server.DefaultSession.createSession(DefaultSession.java:88)

at org.openqa.selenium.remote.server.DefaultDriverSessions.newSession(DefaultDriverSessions.java:109)

at org.openqa.selenium.remote.server.handler.NewSession.handle(NewSession.java:57)

at org.openqa.selenium.remote.server.handler.NewSession.handle(NewSession.java:1)

at org.openqa.selenium.remote.server.rest.ResultConfig.handle(ResultConfig.java:110)

at org.openqa.selenium.remote.server.JsonHttpCommandHandler.handleRequest(JsonHttpCommandHandler.java:172)

at org.openqa.selenium.remote.server.DriverServlet.handleRequest(DriverServlet.java:201)

at org.openqa.selenium.remote.server.DriverServlet.doPost(DriverServlet.java:163)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)

at org.openqa.selenium.remote.server.DriverServlet.service(DriverServlet.java:129)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at org.openqa.jetty.jetty.servlet.ServletHolder.handle(ServletHolder.java:428)

at org.openqa.jetty.jetty.servlet.ServletHandler.dispatch(ServletHandler.java:680)

at org.openqa.jetty.jetty.servlet.ServletHandler.handle(ServletHandler.java:571)

at org.openqa.jetty.http.HttpContext.handle(HttpContext.java:1526)

at org.openqa.jetty.http.HttpContext.handle(HttpContext.java:1479)

at org.openqa.jetty.http.HttpServer.service(HttpServer.java:920)

at org.openqa.jetty.http.HttpConnection.service(HttpConnection.java:820)

at org.openqa.jetty.http.HttpConnection.handleNext(HttpConnection.java:986)

at org.openqa.jetty.http.HttpConnection.handle(HttpConnection.java:837)

at org.openqa.jetty.http.SocketListener.handleConnection(SocketListener.java:243)

at org.openqa.jetty.util.ThreadedServer.handle(ThreadedServer.java:358)

at org.openqa.jetty.util.ThreadPool$PoolThread.run(ThreadPool.java:537)

Caused by: org.openqa.selenium.WebDriverException: java.lang.reflect.InvocationTargetException

Build info: version: '2.45.0', revision: '5017cb8', time: '2015-02-26 23:59:50'

System info: host: 'localhost', ip: '127.0.0.1', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.10.1', java.version: '1.8.0_31'

Driver info: driver.version: unknown

at org.openqa.selenium.remote.server.DefaultDriverProvider.callConstructor(DefaultDriverProvider.java:69)

at org.openqa.selenium.remote.server.DefaultDriverProvider.newInstance(DefaultDriverProvider.java:53)

at org.openqa.selenium.remote.server.DefaultDriverFactory.newInstance(DefaultDriverFactory.java:54)

at org.openqa.selenium.remote.server.DefaultSession$BrowserCreator.call(DefaultSession.java:214)

at org.openqa.selenium.remote.server.DefaultSession$BrowserCreator.call(DefaultSession.java:1)

at java.util.concurrent.FutureTask.run(FutureTask.java:266)

at org.openqa.selenium.remote.server.DefaultSession$1.run(DefaultSession.java:168)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

at java.lang.Thread.run(Thread.java:745)

Caused by: java.lang.reflect.InvocationTargetException

at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)

at java.lang.reflect.Constructor.newInstance(Constructor.java:408)

at org.openqa.selenium.remote.server.DefaultDriverProvider.callConstructor(DefaultDriverProvider.java:59)

... 9 more

selenium-standalone is using strerr instead of stdout

Here is a test that replicates the issue

    it 'bug: selenium-standalone is using strerr instead of stdout',(done)->
        selenium = require('selenium-standalone');
        spawnOptions = { stdio: 'pipe' }
        seleniumArgs = []
        server = new selenium(spawnOptions, seleniumArgs)
        server.stdout.on 'data', (output)->
            throw 'if this thowns, it means the bug is fixed :)'
        server.stderr.on 'data', (output)->
            output.str().assert_Contains('INFO - Launching a standalone server')
            server.kill('SIGINT');
            done()

Browsermob proxy issue

Hi,

I have already a similar issue on the WebdriverIO repo. But I think, I have more chance to get an answer here.

I got a selenium issue when I try to use it with Browsermob to generate HAR file and so capture the network traffic.

What I did. Download the proxy and launch it.

tetienne ~/qa/browsermob-proxy/bin $ sh browsermob-proxy
INFO 10/31 16:30:50 n.s.u.i.d.DataBuild~ - No pattern available for 'Other'.
INFO 10/31 16:30:50 n.s.u.i.d.DataBuild~ - No pattern available for 'Personal computer'.
INFO 10/31 16:30:51 n.s.u.i.d.DataBuild~ - No pattern available for 'Personal computer'.
INFO 10/31 16:30:51 n.l.b.p.Main         - Starting BrowserMob Proxy version %s
INFO 10/31 16:30:51 o.e.j.u.log          - jetty-7.3.0.v20110203
INFO 10/31 16:30:51 o.e.j.u.log          - started o.e.j.s.ServletContextHandler{/,null}
INFO 10/31 16:30:52 o.e.j.u.log          - Started [email protected]:8080

Then using grunt-webdiver, I've created a task in my GruntFile

Proxy = require('browsermob-proxy').Proxy
proxy = new Proxy()
...
webdriver:
      options:
        slow: 10000
        reporter: 'spec'
        #reporter: 'xunit-file'

      mustang:
        tests: ['conf/*.coffee', '<%= dirs%>/**/*.*coffee']
        options:
          desiredCapabilities:
            browserName: 'chrome'
            proxy: {httpProxy: proxy}

But when I launch my task

RuntimeError: RuntimeError
     (UnknownError:13) An unknown server-side error occurred while processing the command.
     Problem: unknown error: cannot parse capability: proxy
from unknown error: 'proxyType' must be a string
  (Driver info: chromedriver=2.9.248304,platform=Linux 3.15.10-1-MANJARO x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 506 milliseconds
Build info: version: '2.42.2', revision: '6a6995d', time: '2014-06-03 17:42:03'
System info: host: 'Dakara', ip: '192.168.0.31', os.name: 'Linux', os.arch: 'amd64', os.version: '3.15.10-1-MANJARO', java.version: '1.7.0_65'
Driver info: org.openqa.selenium.chrome.ChromeDriver

Apparently my desiredCapabilities proxy is not well understood. Perhaps I'm not using this field correctly. Do you see what I missed?

When crashed, the chromedriver is still running

I figured out that when a fatal error occured in the middle of my tests, i.E. a TypeError, then it crashes of course. But the ps -aux | grep selenium command has shown that the Selenium instance is still running.

So I put this ugly hack in my Gulp:

process.on 'exit', ->
  if seleniumProcess then seleniumProcess.kill()

and that solved. But there is still one process remaining: the chromedriver!

/node_modules/selenium-standalone/.selenium/chromedriver/2.14-x64-chromedriver --port=16277

How can I kill it as well? Why isn't selenium killing it?

Wrapping selenium-standalone to grunt task

I'm into wrap this module in a grunt task just to start and stop the server.

Do you know how I can kill the server using javascript?

Do I need to get the PID manually to do it or the function kill() available in the module do it for me?

Unzipping IE driver fails silently

ZIP file is downloaded successfully, but it's not extracted at all.

I'm using the following configuration:

ie: {
    version: '2.44.0',
    arch: process.arch,
    baseURL: 'http://selenium-release.storage.googleapis.com'
}

Environment:

Windows 7 x64
Node v0.10.33

baseURL for the Firefox and Safari drivers

Hello again

In the README.md I can see the baseURLs for Chrome and IE but not for other browsers:

  drivers: {
    chrome: {
      // check for more recent versions of chrome driver here:
      // http://chromedriver.storage.googleapis.com/index.html
      version: '2.14',
      arch: process.arch,
      baseURL: 'http://chromedriver.storage.googleapis.com'
    },
    ie: {
      // check for more recent versions of internet explorer driver here:
      // http://selenium-release.storage.googleapis.com/index.html
      version: '2.44',
      arch: process.arch,
      baseURL: 'http://selenium-release.storage.googleapis.com'
    }
  },

I tried to search for drivers for Firefox and Safari but didn't find any. Can you help me pointing to their correct URLs? Thanks!

How to know if the server is fully started?

Can you please update the example to show how the webdriver is used on the stdout data callback?

When I am trying like the following,

var webdriver = require('selenium-webdriver');

server.stdout.on('data', function(output) {
  driver.get('http://www.google.com'); 
});

I am getting null error exception on selenium-webdriver. Is this the right way to do?

Switch from install time installation to runtime

Currently this will pull down the required selenium and drivers at install time, this is less flexible as it means an npm install every time you want to switch versions or a double install if you want to use the programatic api to configure your version.

I think we should take out the install script from package.json, and wrap the programatic api + cli with the install process, so something similiar to:

var selenium = require('selenium-standalone');

var opts = { 
  seleniumVersion: '2.42.0', 
  stdio: 'pipe' 
};

// options to pass to `java -jar selenium-server-standalone-X.XX.X.jar`
var seleniumArgs = [
  '-debug'
];

selenium(opts, seleniumArgs, function(server) { 
  // or, var server = selenium();
  // returns ChildProcess instance
  // http://nodejs.org/api/child_process.html#child_process_class_childprocess

  // spawnOptions defaults to `{ stdio: 'inherit' }`
  // seleniumArgs defaults to `[]`

  server.stdout.on('data', function(output) {
    console.log(output);
  });
});

Browsermob proxy issue

Hi,

I have already a similar issue on the WebdriverIO repo. But I think, I have more chance to get an answer here.

I got a selenium issue when I try to use it with Browsermob to generate HAR file and so capture the network traffic.

What I did. Download the proxy and launch it.

tetienne ~/qa/browsermob-proxy/bin $ sh browsermob-proxy
INFO 10/31 16:30:50 n.s.u.i.d.DataBuild~ - No pattern available for 'Other'.
INFO 10/31 16:30:50 n.s.u.i.d.DataBuild~ - No pattern available for 'Personal computer'.
INFO 10/31 16:30:51 n.s.u.i.d.DataBuild~ - No pattern available for 'Personal computer'.
INFO 10/31 16:30:51 n.l.b.p.Main         - Starting BrowserMob Proxy version %s
INFO 10/31 16:30:51 o.e.j.u.log          - jetty-7.3.0.v20110203
INFO 10/31 16:30:51 o.e.j.u.log          - started o.e.j.s.ServletContextHandler{/,null}
INFO 10/31 16:30:52 o.e.j.u.log          - Started [email protected]:8080

Then using grunt-webdiver, I've created a task in my GruntFile

Proxy = require('browsermob-proxy').Proxy
proxy = new Proxy()
...
webdriver:
      options:
        slow: 10000
        reporter: 'spec'
        #reporter: 'xunit-file'

      mustang:
        tests: ['conf/*.coffee', '<%= dirs%>/**/*.*coffee']
        options:
          desiredCapabilities:
            browserName: 'chrome'
            proxy: {httpProxy: proxy}

But when I launch my task

RuntimeError: RuntimeError
     (UnknownError:13) An unknown server-side error occurred while processing the command.
     Problem: unknown error: cannot parse capability: proxy
from unknown error: 'proxyType' must be a string
  (Driver info: chromedriver=2.9.248304,platform=Linux 3.15.10-1-MANJARO x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 506 milliseconds
Build info: version: '2.42.2', revision: '6a6995d', time: '2014-06-03 17:42:03'
System info: host: 'Dakara', ip: '192.168.0.31', os.name: 'Linux', os.arch: 'amd64', os.version: '3.15.10-1-MANJARO', java.version: '1.7.0_65'
Driver info: org.openqa.selenium.chrome.ChromeDriver

Apparently my desiredCapabilities proxy is not well understood. Perhaps I'm not using this field correctly. Do you see what I missed?

Install could use a verbose mode

Like v2's install script; would be helpful to aid debugging, and explain to the user what's going on - as it can take a while.

Starting Selenium server fails with obscure error when Java is not installed

When trying to run selenium before installing Java the following output is generated when starting Selenium:

> var selenium = require('selenium-standalone');
> var server = selenium();
> execvp(): No such file or directory

events.js:72
        throw er; // Unhandled 'error' event
              ^
Error: spawn ENOENT
    at errnoException (child_process.js:988:11)
    at Process.ChildProcess._handle.onexit (child_process.js:779:34)

After installing Java on the machine the above code runs just fine. Although it probably isn't feasible to install Java from npm, a nice warning when trying to require or start selenium without Java installed might be warranted.

prefer Win32 version of IEDriverServer

There are severe performance issues with 64bit IEDriverServer when using IE 10. Prefer Win32 version of IEDriverServer over x64 version regardless of the processor architecture. Or at least provide possibility to override the architecture based driver selection.

Do not want to see errors when killing

Every time I kill the selenium process I see this error:

     Callstack:
     -> session("delete")
     -> end()
]
  message: 'RuntimeError\n     (ECONNREFUSED:-1) Couldn\'t connect to selenium server\n     Problem: Couldn\'t connect to selenium server\u001b[1;30m\n\n     Callstack:\n     -> session("delete")\n     -> end()\n',
  name: 'RuntimeError',
  hasCallStack: true }

in the process.uncaughtException handler.

Honestly, when it is getting killed, it should not throw an ECONNREFUSED error

phantomjs on win7x64 doesn't work

14:39:33.117 ERROR - org.apache.commons.exec.ExecuteException: Execution failed (Exit value: -559038737. Caused by java.io.IOException: Cannot run program "C:\Users\aris\AppDa
ta\Roaming\npm\phantomjs" (in directory "."): CreateProcess error=193, %1 is not a valid Win32 application)

running phantomjs (latest) from command prompt works OK.
selenium-standalone works with chrome OK.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.