Skip to content

Commit

Permalink
PhabricatorAPI: raise exceptions on http errors (#202)
Browse files Browse the repository at this point in the history
  • Loading branch information
suhaibmujahid authored Jul 8, 2022
1 parent c092351 commit e8c19af
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libmozdata/phabricator.py
Original file line number Diff line number Diff line change
Expand Up @@ -655,10 +655,10 @@ def request(self, path, **payload):
self.url + path,
data=urlencode({"params": json.dumps(payload), "output": "json"}),
)
response.raise_for_status()

# Check response
data = response.json()
assert response.ok
assert "error_code" in data
ConduitError.raise_if_error(data)

Expand Down

0 comments on commit e8c19af

Please sign in to comment.