-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
raise exceptions when PR creation fails #8013
Conversation
return if branch_exists?(branch_name) && unmerged_pull_request_exists? | ||
return if require_up_to_date_base? && !base_commit_is_up_to_date? | ||
raise "Unmerged PR exists" if branch_exists?(branch_name) && unmerged_pull_request_exists? | ||
raise "Base commit is not up to date" if require_up_to_date_base? && !base_commit_is_up_to_date? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[newbie q] will these errors get surfaced to the user or will they be currently visible in the logs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These will be in the logs, but there is another effort to show the errors to the users as well.
We sometimes see reports of PRs failing to create, but the logs have no information in them. I suspect part of this is due to these errors that are being swallowed up as expected.
So I've removed that and replaces a few blank
return
s withraise
so we can see when those cases are happening.