Add better error message when Java is not installed to the launch script
open | Created 2019-06-10 | Last updated 2019-06-26| Posted by jamesemery | See in Github

CLI bug

Recently I was setting up GATK to run in a VM and I had forgotten to install Java8 onto the machine. When I tried to run GATK from the launch script I ran into the following error:

Using GATK jar /home/emeryj/gatk-
    java -Dsamjdk.use_async_io_read_samtools=false -Dsamjdk.use_async_io_write_samtools=true -Dsamjdk.use_async_io_write_tribble=false -Dsamjdk.compression_level=2 -jar /home/emeryj/gatk- -help
Traceback (most recent call last):
  File "./gatk", line 479, in <module>
  File "./gatk", line 152, in main
    runGATK(sparkRunner, sparkSubmitCommand, dryRun, gatkArgs, sparkArgs, javaOptions)
  File "./gatk", line 328, in runGATK
    runCommand(cmd, dryrun)
  File "./gatk", line 384, in runCommand
    check_call(cmd, env=gatk_env)
  File "/usr/lib/python2.7/", line 181, in check_call
    retcode = call(*popenargs, **kwargs)
  File "/usr/lib/python2.7/", line 168, in call
    return Popen(*popenargs, **kwargs).wait()
  File "/usr/lib/python2.7/", line 390, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/", line 1024, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory

This should perhaps be made a little bit clearer for users as this isn't particularly helpful.

Return to top