Duplication of branch names

Hi folks,

Not sure if I am the only one afflicted by this, so here goes...

For some reason, in 3 out of the 5 repos I work agains, all branches double up.  The other 2 present as you'd expect.

The below is a normal display, showing a bunch of branches:

tab1.PNG

tab2.PNG

tab2.PNG

tab2.PNG

tab2.PNG

 

6 answers

I had the same issue but I fixed it :)

I noticed that `git branch -l` gave me an error message, but `git branch -r` worked ok.

The error message was:

$ git branch -l
fatal: missing object 791838d65fcfc7295dea5ebf2eae468d10f066bd for refs/heads/issue/BB#69_convert_everything_to_python

 

This branch has actually been merged.  Actually, a new branch may have been created, and then squashed, and then merged.  The branch is deleted (not in config file) but there was a still a referenced to it.

After manually deleting the reference in the console, displaying local branches now work and the the duplicated branches in ST disappeared :)

$ rm -rf refs/heads/issue/BB#69_convert_everything_to_python

:)

0 votes

Hi

We've not experienced that, is there anything significant about the repos that have the problem?

Is there any duplication of information about them in Sourcetree e.g. the same names etc

Trying to understadn the environment to see if we can reproduce it.

Thanks Michael,

Sorry for the messed-up posting, not sure why the one screenshot got pasted several times.

So, using v2.3.1.0 (latest) on Windows 7.

I have 4 Gitlab repos that I connect Sourcetree to.  The 4 repos are much the same: nothing about any one of them is inherently different to the other 3 in terms of credentials, git, etc. Certainly, they are all configured to connect to Sourcetree in the same way.

Of the 4, 1 behaves itself while the other 3 duplicate every local branch.

Some things that may be relevant:

(1) Have recently upgraded the Sourcetree.  Would have been 2 if not 3 versions behind.  But the duplication was already there.  I upgraded in the hope that it would make it go away.

(2) I culled a lot of old local branches from all 4 repos that were "clutter" as far as I was concerned.  That didn't help: whatever branches are left are duplicated.

(3) If I click on Branch, and pretend I want to delete a local branch, the list of branches I am offered has no duplication.  So, at least one part of the system "knows" that there really is only one version of each local branch.  See the screenshots below...

Capture1.PNG

vs

Capture2.PNG

So Sourcetree will run the following the get the branch information

>git branch --no-abbrev -v

I'm assuming if you run that in the terminal you do NOT see any duplication of branch names?

No such luck. I ran the command as given and still see the saem duplicated branch entries. Restarting Sourcetree doesn't help.

That's same, not saem...

Hi Michael,

Yes, you are spot on: running the command from the terminal returns no duplication.

It feels as though the UI (and only the UI - not the underlying git/repository mechanics) are affected.

Cheers,

-Neven.

OK, thanks for the info, we can investigate.

Just for the record, I am seeing this as well. I have 5 projects and 1 of them exhibits this behavior. The only difference between the ones that work correctly and this one that has duplicated branch names is I am using Visual Studio 2015 on the outlier, VS 2017 on the others.

I'm also getting this. I even tried to reinstall sourcetree but no luck

+1.  I am seeing this too.  Have been putting up with it for a while now hoping that an upgrade would fix it.  It's distracting and disconcerting.

I'm fairly certain it happened with a ST update, but can't tell you exactly which one.

My symptoms are similar to above, but not exactly the same.

I have branches called:

     * issue/BB#22_alarm_stuck_on

    * issue/BB#75_dst_rollover_unit_tests

    * bjs/python_experiments

    * bjs/wxglade_experiments

    * master

    * master-next

The branches that are in a "folder" (have forward slash in name) seem to be duplicated in the ST UI, however top-level branches (without forward slashes) are not duplicated.  e.g. `master` and `master-next`

Suggest an answer

Log in or Join to answer
Community showcase
Brian Ganninger
Published Jan 23, 2018 in Sourcetree

Tip from the team: workflow and keyboard shortcuts

Supported Platforms macOS Sourcetree has a lot to offer and, like many developer tools, finding and using it all can be a challenge, especially for a new user. Everyone might not love ...

261 views 0 3
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot