Skip to content

gh pr create fails in v2.64.0 if the current branch doesn't have the upstream configured #10188

Closed

Description

@cmbrose

Describe the bug

There appears to be a regression in v2.64.0 where gh pr create will now fail to create the PR unless the upstream is available via git config (basically requiring the -u option of git push). The error is aborted: you must first push the current branch to a remote, or use the --head flag from here.

Note I've already started a PR to fix this here: #10177

Internal tracking issue: https://github.com/github/cli/issues/730

Steps to reproduce the behavior

  1. git checkout -B my-branch
  2. Make some edit and git commit it
  3. git push origin my-branch
  4. gh pr create ...

Expected vs actual behavior

Up to and including v2.63.2 these commands succeed. In v2.64.0 it will fail with the above error.

Activity

  1. added
    gh-prrelating to the gh pr command
    and removed on Jan 6, 2025
  2. jtmcg commented on Jan 6, 2025

    @jtmcg
    Contributor

    The PR is merged, so closing this. We expect the fix to go out in our next release, which should be v2.65.0

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

    bugSomething isn't workinggh-prrelating to the gh pr command

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions