-
Type:
Bug
-
Resolution: Timed out
-
Priority:
Low
-
Component/s: Pull Request - Reviewers
-
1
-
Severity 3 - Minor
-
4
This issue was raised as the original bug was closed. This should be the ticket to track the impact on the original issue going forward
Issue Summary
- When a user is removed from a workspace, if the user was listed as a default reviewer for any repository, the default-reviewers endpoint still returns that user, even though they no longer have access to the workspace;
Steps to Reproduce
- Add a user to your workspace;
- Add the user as default reviewer for any repository;
- Remove the user through the workspace's settings > User directory
- Use the default-reviewers API endpoint for that repository;
Expected Results
- The user should not be listed as a default reviewer anymore;
Actual Results
- The user appears in the list of repository default reviewers through the API;
- Furthermore, if you try to edit a file and commit it through the UI, creating a Pull Request, the user will be added as a reviewer, causing an issue while trying to create the PR.
The below exception is thrown in the network tab of the Developer Panel:
{
"type": "error",
"error": {
"message": "reviewers: John Doe is not a member of this workspace and cannot be added to this pull request",
"fields": {
"reviewers": [
"John Doe is not a member of this workspace and cannot be added to this pull request"
]
}
}
}
Workaround
- Use the Delete Default Reviewer Endpoint to remove that user from the list of default reviewer;
$ Curl -X DELETE -u <username>:<password> "https://api.bitbucket.org/2.0/repositories/<workspace>/<repo>/default-reviewers/%7B<UUID>%7D"
- has a derivative of
-
BCLOUD-23445 Adding an ineligible user as a reviewer on a pull request replaces the reviewer list with an error message
-
- Closed
-