OpenFermion-Psi4
OpenFermion-Psi4 copied to clipboard
improve exception handling in run_psi4
When Psi4 is not installed an exception occurs because the file psi4 cannot be found. Cleanup of the process with process.kill() then generates another exception, because the variable process was not created.
This PR:
- Adds the generated exception to the warning message
- Wraps the
process.kill()in a try-except
@bsenjean