Skip to content

Commit

Permalink
Add missing return of exit code
Browse files Browse the repository at this point in the history
Otherwise return_results is executed twice
  • Loading branch information
janssenhenning committed Jul 4, 2022
1 parent 7bc84a8 commit db0d847
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions aiida_fleur/workflows/hubbard1.py
Original file line number Diff line number Diff line change
Expand Up @@ -290,13 +290,15 @@ def inspect_hubbard1_calculation(self):
error = ('ERROR: Hubbard1 SCF workflow was not successful')
self.ctx.successful = False
self.control_end_wc(error)
return self.exit_codes.ERROR_HUBBARD1_CALCULATION_FAILED

try:
self.ctx.hubbard1.outputs.output_scf_wc_para
except NotExistent:
error = ('ERROR: Hubbard1 SCF workflow failed, no output node')
self.ctx.successful = False
self.control_end_wc(error)
return self.exit_codes.ERROR_HUBBARD1_CALCULATION_FAILED

def return_results(self):
"""
Expand Down

0 comments on commit db0d847

Please sign in to comment.