Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

tfpt unshelve migrate showing "An item with the same key has already been added."

I am follwing the example here Branch from local workspace because I have the same scenario.

Shelveset details dialog appear, after clicking unshelve it showing "An item with the same key has already been added."

Any advice please?

like image 689
NetZeroSaw Avatar asked Jul 24 '13 02:07

NetZeroSaw


3 Answers

As others have indicated in the comments, undoing changes from the main branch (presumably the SOURCE branch for the shelveset you want to unshelve), should fix the issue, allowing you to continue with the merge behavior.

like image 55
JoeBrockhaus Avatar answered Nov 10 '22 05:11

JoeBrockhaus


I had a very similar issue to yourself and after trying a lot of things I discovered it was some pending changes we had been excluded and were easy to miss, that caused the issue.

I've written up how to trouble shoot it against the following question:
TFS 2012 Unshelve to different branch -> An item with the same key has already been added

like image 5
Ralph Willgoss Avatar answered Nov 10 '22 05:11

Ralph Willgoss


In my case, my source and my target branch were both fully checked in. The problem was the root Team Project had other Visual Studio projects beneath it with pending changes (pending adds). There can be no pending changes in the entire TFS Team Project, not just the involved project branches.

like image 1
xr280xr Avatar answered Nov 10 '22 06:11

xr280xr