Skip to content
This repository has been archived by the owner on Nov 29, 2018. It is now read-only.

PhantomJSDriverService fails to start on Windows (has patch) #7514

Closed
lukeis opened this issue Mar 4, 2016 · 8 comments
Closed

PhantomJSDriverService fails to start on Windows (has patch) #7514

lukeis opened this issue Mar 4, 2016 · 8 comments

Comments

@lukeis
Copy link
Member

lukeis commented Mar 4, 2016

Originally reported on Google Code with ID 7514

When running phantomjs driver on Windows, PhantomJSDriverService erronously selects
a blank extension instead of .cmd. This leads to an silent error since DriverService.start
fails to print out any exception from the CommandLine process.

Suggested fix:
1. DriverService.start checks for error and prints it out errors from the command line
process (optional)
2. org.openqa.selenium.os.ExecutableFinder.ENDINGS replace "" with ".cmd" on Windows

Workaround:
* Specify desiredCapabilities phantomjs.binary.path when running Selenium

How to reproduce:
* Run selenium with browserName: phantomjs on Windows. When running with debug output,
Selenium will print lines like "16:18:17.787 DEBUG - Polling http://localhost:37991/status"
and then exit

Reported by jhannes on 2014-06-18 14:18:39


- _Attachment: [selenium-phantomjs-windows.patch](https://storage.googleapis.com/google-code-attachments/selenium/issue-7514/comment-0/selenium-phantomjs-windows.patch)_
@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

Reported by barancev on 2014-06-23 21:01:19

  • Labels added: Browser-PhantomJS, OpSys-Windows

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

The "official" PhantomJS executable file is phantomjs.exe , what .cmd file do you mean?

Reported by barancev on 2014-06-23 21:33:29

  • Status changed: NeedsClarification

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

Context: Installed Selenium and PhantomJs using npm (npm install selenium-standalone
phantomjs). Selenium standalone (under NodeJs) adds node_modules/.bin to PATH, PhantomJs
adds node_modules/.bin/phantomjs.cmd AND node_modules/.bin/phantomjs (for Unix).

An example project here: https://github.com/jhannes/wtddjs

At any rate:

* It's bad that failing to create a process fails silently
* It's seems a mistake for Windows to search for executable without extension
* On Windows, .cmd should be a possible extension

Reported by jhannes on 2014-06-24 08:33:49

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

Reported by barancev on 2014-06-24 09:26:01

  • Status changed: Accepted
  • Labels removed: Status-Untriaged

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

Have you signed the CLA http://goo.gl/qC50R ?

Reported by barancev on 2014-06-25 20:19:04

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

I have signed now with email address johannes@brodwall.com

Reported by jhannes on 2014-06-25 21:32:30

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

This issue was closed by revision 203090ccc0fa.

Reported by barancev on 2014-06-28 19:36:09

  • Status changed: Fixed

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

Reported by luke.semerau on 2015-09-17 18:22:35

  • Labels added: Restrict-AddIssueComment-Commit

@lukeis lukeis closed this as completed Mar 4, 2016
@SeleniumHQ SeleniumHQ locked and limited conversation to collaborators Mar 4, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant