Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Selenium 3-beta] Server fails to start when launched with chromedriver v2.22 #2566

Closed
mehmetg opened this issue Aug 4, 2016 · 11 comments
Closed

Comments

@mehmetg
Copy link

mehmetg commented Aug 4, 2016

Meta -

OS:
OSX 10.11.6
Selenium Version:
Se3 Beta 2
Browser:
N/A

Browser Version:
chromedriver v2.22

Expected Behavior -

Selenium server should start
using the following command line
java -debug -jar /Users/mehmetgerceker/workspace/nerdytests/resources/selenium-server-standalone-3.0.0-beta2.jar -Dwebdriver.chrome.driver=/Users/mehmetgerceker/workspace/nerdytests/resources/chromedriver-2.22 -Dwebdriver.gecko.driver=/Users/mehmetgerceker/workspace/nerdytests/resources/geckodriver-0.10.0

Actual Behavior -

Selenium server throws the following error

Exception in thread "main" com.beust.jcommander.ParameterException: Unknown option: -Dwebdriver.chrome.driver=/Users/mehmetgerceker/workspace/nerdytests/resources/chromedriver-2.22
        at com.beust.jcommander.JCommander.parseValues(JCommander.java:742)
        at com.beust.jcommander.JCommander.parse(JCommander.java:282)
        at com.beust.jcommander.JCommander.parse(JCommander.java:265)
        at com.beust.jcommander.JCommander.<init>(JCommander.java:210)
        at org.openqa.grid.selenium.GridLauncherV3$1.setConfiguration(GridLauncherV3.java:202)
        at org.openqa.grid.selenium.GridLauncherV3.buildLauncher(GridLauncherV3.java:130)
        at org.openqa.grid.selenium.GridLauncherV3.main(GridLauncherV3.java:67)

Steps to reproduce -

java -debug -jar /Users/mehmetgerceker/workspace/nerdytests/resources/selenium-server-standalone-3.0.0-beta2.jar -Dwebdriver.chrome.driver=/Users/mehmetgerceker/workspace/nerdytests/resources/chromedriver-2.22 -Dwebdriver.gecko.driver=/Users/mehmetgerceker/workspace/nerdytests/resources/geckodriver-0.10.0

@lukeis
Copy link
Member

lukeis commented Aug 4, 2016

Java command line usage requires system properties to be specified BEFORE the -jar

Please move all -D command line arguments before the -jar argument

@lukeis lukeis closed this as completed Aug 4, 2016
@mehmetg
Copy link
Author

mehmetg commented Aug 4, 2016

Thank you. Oddly enough 2.53.1 was perfectly fine with it.

@lukeis
Copy link
Member

lukeis commented Aug 4, 2016

Not too odd ;) we changed the command line argument parser to use Jcommander instead of maintaining our own. The old one did extra by accepting system property flags and then setting them with extra Java code. We have no interest in maintaining a command line parser in selenium.

@mehmetg
Copy link
Author

mehmetg commented Aug 4, 2016

Ah makes sense. Thank you for the explanation. 😄

@GaneshBalasubramanian15

java -jar /selenium-server-standalone-3.0.0-beta4.jar -port 5555
-Dwebdriver.gecko.driver=C:\Selenium3\geckodriver
i cant start this batch file with the above content and unable to debug.
any suggestions guys?

@lukeis
Copy link
Member

lukeis commented Oct 10, 2016

@GaneshBalasubramanian15 -D arguments in the command line should come before the '-jar'

@fayizkc
Copy link

fayizkc commented Oct 11, 2016

Hi Lukeis,
Can you please assist us to re structure the below code to run Selenium Grid in Selenium 3.0.0-beta4
java -jar selenium-server-standalone-3.0.0-beta4.jar -role webdriver -hub http://%$HubSystemName%:4444/grid/register -port 5566 -browser browserName="chrome", -Dwebdriver.chrome.driver=chromedriver.exe -browser browserName="ie", -Dwebdriver.ie.driver=IEDriverServer.exe

@ghost
Copy link

ghost commented Oct 12, 2016

I would love to know how this line should be structured under the new invocation rules:
java -jar selenium-server-standalone-3.0.0-beta3.jar -host 192.168.63.178 -port 4444

Currently that throws an error:
Exception in thread "main" com.beust.jcommander.ParameterException: Unknown option: -host

@lukeis
Copy link
Member

lukeis commented Oct 12, 2016

@marcbaas -host is only available when run with -role hub or -role node.

@fayizkc move all your -D... command line parameters before the -jar as i said before.... java -Dwebdriver....=... -Dwebdriver....=... -jar selenium-server....

@GaneshBalasubramanian15
Copy link

hello guys, hope ye all well, Im having this issue when i dont have the grid set up. this is the single batch file configured for all the browsers

java -Dwebdriver.gecko.driver="geckodriver.exe" -jar selenium-server-standalone-2.53.1.jar -port 5555 -Dwebdriver.ie.driver="IEDriverServer2_53.exe" -Dwebdriver.chrome.driver="chromedriver2_25.exe" -debug

The service is up, but when i run the selenium im getting this error for latest FF 49.0.1

Error
org.openqa.selenium.WebDriverException: Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms. Firefox console output:

any suggestions please?

@ddavison
Copy link
Member

ddavison commented Nov 3, 2016

@GaneshBalasubramanian15 , @lukeis gave the solution many times. please move your -D arguments before your -jar option. feel free to pop into #selenium irc on freenode if you need any help.

locking conversation.

@SeleniumHQ SeleniumHQ locked and limited conversation to collaborators Nov 3, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants