Fix errors from BitBucket submitted hook with too many logins.

Review Request #12019 — Created Jan. 28, 2022 and submitted

Information

Review Board
release-4.0.x

Reviewers

When a BitBucket repository is configured with an account with an
incorrect password, at some point BitBucket will lock the account and
start returning 403s instead of 401s. Because our check for
authorization-related errors was only checking for 401, the submitted
hook would end up with uncaught exceptions, triggering e-mails to the
admins.

This change adds a check for the error message that BitBucket returns in
this case to handle the error correctly.

Ran unit tests.

Summary ID
Fix erors from BitBucket submitted hook with too many logins.
When a BitBucket repository is configured with an account with an incorrect password, at some point BitBucket will lock the account and start returning 403s instead of 401s. Because our check for authorization-related errors was only checking for 401, the submitted hook would end up with uncaught exceptions, triggering e-mails to the admins. This change adds a check for the error message that BitBucket returns in this case to handle the error correctly. Testing Done: Ran unit tests.
e81365ea0efb6428135385c597febf12abd66dea
Description From Last Updated

Typo in the summary: "erors"

chipx86chipx86

E501 line too long (83 > 79 characters)

reviewbotreviewbot
Checks run (1 failed, 1 succeeded)
flake8 failed.
JSHint passed.

flake8

david
chipx86
  1. 
      
  2. Typo in the summary: "erors"

  3. 
      
david
david
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-4.0.x (b096557)
Loading...