`gh pr create --reviewer` fails with @org/team format after v2.88.0 (requestReviewsByLogin regression) · Issue #13060 · cli/cli · GitHub
Skip to content

gh pr create --reviewer fails with @org/team format after v2.88.0 (requestReviewsByLogin regression) #13060

Description

@mattbowolick

Describe the bug

After upgrading to v2.88.0, passing a team reviewer with an @-prefixed slug (e.g. --reviewer "@myorg/my-team") to gh pr create fails with a GraphQL error:

$ gh pr create --reviewer "@myorg/my-team" --title "Test" --body "Test"

https://github.com/org/repo/pull/123

pull request update failed: GraphQL: Could not resolve team with slug '@org/my-team'. (requestReviewsByLogin)

Prior to v2.88.0 this worked correctly. A potential regression was introduced by the switch to login-based reviewer requests in #12627 ? Which now passes reviewer strings verbatim to the requestReviewsByLogin mutation, which does not accept the @ prefix on team slugs.

A number of our CI jobs started to fail after Github Actions auto started using the latest version, we've correct to use no prefix, but this breaking change I assume is a regression and with/without @ prefix should still be supported.

Affected version

gh version 2.89.0 (2026-03-26)
https://github.com/cli/cli/releases/tag/v2.89.0

Steps to reproduce the behavior

  1. Run gh pr create --reviewer "@myorg/my-team" --title "Test" --body "Test"
  2. Observe output after PR creation
  3. See error: pull request update failed: GraphQL: Could not resolve team with slug '@myorg/my-team'. (requestReviewsByLogin)

Expected vs actual behavior

Expected: --reviewer "@myorg/my-team" requests a review from the team, consistent with behaviour in ≤v2.87.3 where the @ prefix was tolerated.

Actual: The PR is created successfully but the reviewer request fails. The @ prefix is passed verbatim to requestReviewsByLogin as teamSlugs: ["@myorg/my-team"], which GitHub cannot resolve. The workaround is --reviewer "myorg/my-team".

Logs

 $ GH_DEBUG=api gh pr create --title "Test PR" --body "testing" --reviewer "@myorg/my-team"

  > User-Agent: GitHub CLI 2.89.0

  mutation RequestReviewsByLogin($input:RequestReviewsByLoginInput!)
  variables: {"teamSlugs":["@myorg/my-team"],"userLogins":[],"botLogins":[],"union":true}

  {
    "data": { "requestReviewsByLogin": null },
    "errors": [
      {
        "type": "NOT_FOUND",
        "message": "Could not resolve team with slug '@myorg/my-team'."
      }
    ]
  }

  pull request update failed: GraphQL: Could not resolve team with slug '@myorg/my-team'.
  (requestReviewsByLogin)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggh-prrelating to the gh pr commandplatformProblems with the GitHub platform rather than the CLI clientpriority-3Affects a small number of users or is largely cosmetic

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions