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

Selenium Server Standalone outputs to STDERR instead of STDOUT #7957

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

Selenium Server Standalone outputs to STDERR instead of STDOUT #7957

lukeis opened this issue Mar 4, 2016 · 6 comments

Comments

@lukeis
Copy link
Member

lukeis commented Mar 4, 2016

Originally reported on Google Code with ID 7957

The latest version of selenium-server standalone (2.43.0) outputs its startup messages
to STDERR. As of version 2.39.0 (at a minimum), messages were sent to STDOUT

To reproduce:

1) Start selenium, redirecting stderr to a file:

selenium-server 2> errors.txt

Selenium 2.43.0 will produce output in errors.txt, while 2.39.0 will not.

This occurs for me on MacOS Mavericks (10.9.4), running Java 1.7.0_25.

Thanks!

Reported by tommyfisher on 2014-09-24 21:36:50

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

And what's the problem?

Reported by barancev on 2014-09-25 05:01:02

  • Status changed: NeedsClarification

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

The problem I had was with another program which is waiting for selenium to complete
its startup process, and was reading from stdout to determine that it had. 

Although the program could be modified to read from standard error as well, I'd argue
that it's unexpected that selenium's startup messages, none of which are errors, are
sent to standard error instead of standard out.

Reported by tommyfisher on 2014-09-25 05:13:58

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

There are no special "startup messages", it is just a part of the log. Selenium server
is a server, and for this reason it should not write to stdout. Nobody expects e.g.
Apache web server to write something to stdout.

Why older versions wrote something to the stdout? Because a bug :) And it was fixed.

By the way, instead of watching the log your program would better poll the ability
to set network connection to the selenium server.

Reported by barancev on 2014-09-25 05:25:00

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

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

Thanks, good point regarding apache. And thank you for the suggestion, I will use polling
instead.

Reported by tommyfisher on 2014-09-25 16:18:09

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

While I do understand that you do not want to write to stdout because it's a server,
what's the point of writing INFO messages to ERROR output?

You better not write anything at all in this case. Even if it's not a good decision.

Please I am a UNIX noob, do you have a reference page stating that no server should
write to stdout? Thanks.

Reported by wouaren on 2014-12-03 11:36:35

@lukeis
Copy link
Member Author

lukeis commented Mar 4, 2016

Reported by luke.semerau on 2015-09-17 18:24:37

  • 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