Skip to content

branch_get_upstream() doesn't work for local branch that has been pushed to remote #457

Open
@yli110-stat697

Description

@yli110-stat697

Hi,

I come across this observation that if I have a local branch, even though I have pushed it to remote on github using git command line, the branch_get_upstream() still doesn't work.
To replicate this issue, I forked your repo and pushed a test branch with dummy commit. Below are my findings

Screen Shot 2023-07-03 at 9 57 23 AM Screen Shot 2023-07-03 at 9 58 03 AM

you can see that calling branches() I can clearly see one local branch test and one remote branch test, but branch_get_upstream() returned NULL.

Note: you cannot replicate this issue if you cloned a repo and checked out a remote branch, you have to create a local and then push to remote in terminial.

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