Qiskit / qiskit-addon-dice-solver

An eigensolver used to scale up SQD chemistry workflows past 30 orbitals
https://qiskit.github.io/qiskit-addon-dice-solver
Apache License 2.0
18 stars 2 forks source link

Ensure a DiceExecutionError is raised when Dice fails #26

Closed caleb-johnson closed 1 month ago

caleb-johnson commented 1 month ago

The current logic only raises a DiceExecutionError when subprocess.run fails to execute. This isn't the right logic since subprocess.run will successfully execute even if the underlying process returns a non-zero return code. This PR checks the returncode explicitly and raises a DiceExecutionError alerting users to the failure of the Dice command line application and pointing them to the logfile.