Skip to content

Commit

Permalink
Add exception chaining for Result validate exception
Browse files Browse the repository at this point in the history
  • Loading branch information
ubaumann committed Mar 20, 2024
1 parent 339cda3 commit 4339734
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nuts/helpers/result.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def validate(self) -> None:
f"An exception has occurred while executing nornir:\n"
f"{header}\n"
f"{self._result}"
)
) from self.exception
if self.failed:
raise NutsNornirError(f"Nornir execution has failed:\n" f"{self._result}")

Expand Down

0 comments on commit 4339734

Please sign in to comment.