Skip to content

Commit

Permalink
Only read more detailed json status codes for bugzilla - not HTTP status
Browse files Browse the repository at this point in the history
  • Loading branch information
root committed Nov 7, 2023
1 parent f7027b0 commit d30403f
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions openqa_bugfetcher/issues/bugzilla_issue.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,6 @@ def rest_get_bug(issue_id):
return requests.get(url, params=get_params, timeout=10)

req = rest_get_bug(issue_id)
assert req.status_code != 401, "Wrong auth for Bugzilla"
assert req.status_code != 403, "Insufficient permission to access this bug (or the API at all)"
assert req.ok, f"Server Status != 2xx: {req.text!r}"
data = req.json()
assert data, "Empty JSON Object"
if data.get("error"):
Expand Down

0 comments on commit d30403f

Please sign in to comment.