Skip to content

Commit

Permalink
fix: error-handling
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinBernstorff committed Oct 24, 2023
1 parent 060bd4f commit c5f8997
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,11 @@ def lint(c: Context, auto_fix: bool = False):
def pr(c: Context, auto_fix: bool = True, create_pr: bool = True):
"""Run all checks and update the PR."""
if create_pr:
update_pr(c)
try:
update_pr(c)
except Exception as e:
print(f"{msg_type.FAIL} Could not update PR: {e}")
exit(1)
add_and_commit(c)
lint(c, auto_fix=auto_fix)
static_type_checks(c)
Expand Down

0 comments on commit c5f8997

Please sign in to comment.