nwchemgit / nwchem

NWChem: Open Source High-Performance Computational Chemistry
http://nwchemgit.github.io
Other
507 stars 161 forks source link

Exits ungracefully when called without arguments #68

Open yurivict opened 6 years ago

yurivict commented 6 years ago

It should instead print the help message about how to invoke it.

$ nwchem 
  Unable to open nwchem.nw --- appending .nw
 ------------------------------------------------------------------------
 nwchem: failed to open the input file                   0
 ------------------------------------------------------------------------
 ------------------------------------------------------------------------
  current input line : 
     0: 
 ------------------------------------------------------------------------
 ------------------------------------------------------------------------
 There is an error in the input file
 ------------------------------------------------------------------------
 For more information see the NWChem manual at http://www.nwchem-sw.org/index.php/NWChem_Documentation

 For further details see manual section:                                                                                                                                                                                                                                                                
0:nwchem: failed to open the input file:Received an Error in Communication
application called MPI_Abort(comm=0x84000000, -1) - process 0
[unset]: write_line error; fd=-1 buf=:cmd=abort exitcode=-1
:
system msg for write_line failure : Bad file descriptor
jeffhammond commented 6 years ago

In 25 years, nobody has complained about this before but I’ll push a fix and maybe some extra goodness like support for --help and --version.

jeffhammond commented 5 years ago

https://github.com/jeffhammond/nwchem/tree/nwchem-print-version-help is WIP to resolve this issue.