Tuesday, 18 June 2013

TFS 2012 - Invalid Changesets appearing in the list of merges

I encountered this problem of getting unnecessary changesets in the merge list after branching using TFS 2012, so thought to blog about it.

I took a branch out of our main development branch, using the option "latest version". Immediately after the branch had been taken, I attempted to merge from the source branch to the newly created branch with the option of "selected changesets to merge". 

Since, nothing had been checked-in in the source branch, you would expect that the list is empty. However, I could see quite a few pending changes in there. Confused and somewhat unsure of what happened there, I did a folder comparison between the source and target branches and the files were in fact the same, so no concerns as far as branching goes.

This is actually a known issue in TFS 2012 and has been fixed in TFS 2012 Update 2. The issue was that if the source branch contains a file such that the file has had a case only rename (e.g. it has been changed from file.txt to File.txt), any changesets containing that particular file will still be shown in the list of pending merges.


As, I said the issue has been fixed in TFS 2012 Update 2, so your solution is to upgrade to TFS 2012 Update 2.