Skip to content

[Bug]: Bitbucket requestReviewers can only add workspace members from the first page of 50 #46163

Done

Description

@erdna84

Summary

On Bitbucket Cloud, pull_request_update with requestReviewers (MCP tool, also the reviewer picker) cannot request anyone who is not on the first page of 50 workspace members. It fails with No reviewer named <x> can be requested on this PR. for every identifier form: display name, nickname, {uuid} and account_id.

BitbucketPullRequestApi.listReviewerCandidates only calls GET /2.0/workspaces/{ws}/members?pagelen=50 and never follows next. Bitbucket has searchCandidates: false, so there is no host search fallback either (#22489 enabled host search only for GitHub and GitLab; #32624 only covered taking existing reviewers off).

Steps to reproduce

  1. Bitbucket Cloud workspace with more than 50 members (ours: 4351 members, 88 pages).
  2. Open PR, call pull_request_update with requestReviewers: ["<user beyond page 1>"], e.g. by {uuid} or account_id.
  3. Error: No reviewer named <x> can be requested on this PR.

Server trace shows only GET https://api.bitbucket.org/2.0/workspaces/<ws>/members?pagelen=50 → 200, no follow-up page, for each attempt. The token has workspace read scope (members call succeeds).

Expected

  • {uuid} / account_id: resolve directly (GET /2.0/users/{uuid}) and add to reviewers, no candidate list needed.
  • Names: search the host (e.g. members?q=user.display_name~"…" / nickname) instead of filtering page 1 only; or paginate via next.

Version

T3 Code (Beta) 0.1.13, macOS, Bitbucket Cloud.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions