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

Fails to find version when JAVA_TOOL_OPTIONS is set #138

Open
nh13 opened this issue Jul 20, 2022 · 0 comments
Open

Fails to find version when JAVA_TOOL_OPTIONS is set #138

nh13 opened this issue Jul 20, 2022 · 0 comments

Comments

@nh13
Copy link

nh13 commented Jul 20, 2022

For example, if we set the JAVA_TOOL_OPTIONS environment variable

export JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF8

then the first line is not the version:

$ java -version                                
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF8
openjdk version "1.8.0_322"
OpenJDK Runtime Environment (Zulu 8.60.0.21-CA-macos-aarch64) (build 1.8.0_322-b06)
OpenJDK 64-Bit Server VM (Zulu 8.60.0.21-CA-macos-aarch64) (build 25.322-b06, mixed mode)

The getActualJavaVersion looks only at the first line (see here).

Ideally, it would skip over leading lines that start with Picked up. Related to nextflow-io/nextflow#1716

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant