Skip to content
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

fix: report SAML issue as fatal #1148

Merged
merged 2 commits into from
Jun 3, 2020
Merged

fix: report SAML issue as fatal #1148

merged 2 commits into from
Jun 3, 2020

Conversation

sileht
Copy link
Member

@sileht sileht commented Jun 2, 2020

Currently this is catched as AuthentificationFailure making Mergify
retrying for ever. This change mark the SAML message as fatal. So
the error message coming from Github is reported on the PullRequest.

Related #1145
Fixes MERGIFY-ENGINE-1MG

Currently this is catched as AuthentificationFailure making Mergify
retrying for ever. This change mark the SAML message as fatal. So
the error message coming from Github is reported on the PullRequest.

Related #1145
Fixes MERGIFY-ENGINE-1MG
@mergify mergify bot requested a review from a team June 2, 2020 07:31
b"Protected branch update failed": BranchUpdateFailure,
b"Couldn't find remote ref": BranchUpdateFailure,
}
GIT_MESSAGE_TO_EXCEPTION = collections.OrderedDict(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does this need to be ordered?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SAML error also match 'The requested URL returned error, 403'. So first match first raise.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, that could have been great to have a bunch of unit test around these actually, so we're sure we don't break those.

@mergify mergify bot requested a review from a team June 2, 2020 09:11
Copy link
Member

@jd jd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm approving nevertheless, but if you have the error message around, we might want to add some tests.

b"Protected branch update failed": BranchUpdateFailure,
b"Couldn't find remote ref": BranchUpdateFailure,
}
GIT_MESSAGE_TO_EXCEPTION = collections.OrderedDict(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, that could have been great to have a bunch of unit test around these actually, so we're sure we don't break those.

@mergify mergify bot merged commit 6238665 into Mergifyio:master Jun 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants