You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There's problem in atlassian.bitbucket.cloud.base.BitbucketCloudBase:raise_for_status() where it fails while constructing error message, causing real error to be hidden. This is the error I got:
Traceback (most recent call last):
File "/home/chewbo/jenkins/jenkins-repos/venv/lib/python3.9/site-packages/atlassian/bitbucket/cloud/base.py", line 116, in raise_for_status
error_msg += "\n" + e["detail"]
TypeError: can only concatenate str (not "dict") to str
My solution was simple, just use string interpolation:
# error_msg += "\n" + e["detail"] # from this
error_msg = f"{error_msg}\n{e['detail']}" # to this
After that I finally got the real error:
requests.exceptions.HTTPError: Your credentials lack one or more required privilege scopes.
{'required': ['pullrequest'], 'granted': ['webhook', 'repository:admin', 'repository:write', 'project', 'team']}
This can be reproduce by trying to create webhook with pullrequest:fulfilled event but without pullrequest access.
The text was updated successfully, but these errors were encountered:
There's problem in
atlassian.bitbucket.cloud.base.BitbucketCloudBase:raise_for_status()
where it fails while constructing error message, causing real error to be hidden. This is the error I got:My solution was simple, just use string interpolation:
After that I finally got the real error:
This can be reproduce by trying to create webhook with
pullrequest:fulfilled
event but withoutpullrequest
access.The text was updated successfully, but these errors were encountered: