Question

when I run git tfs fetch there is no output. It doesn't seem to be pulling any new changesets from the tfs server. I then ran git tfs fetch -d and got the following output:

C:\projects\Infinity>git tfs fetch -d
Command run:git tfs fetch -d
No authors file used.
git-tfs version 0.19.2.0 (TFS client library 12.0.0.0 (MS)) (32-bit)
Fetching from TFS remote default
git command: Starting process: git log --no-color --pretty=medium refs/remotes/tfs/default --
git command time: [00:00:00.0330000] log --no-color --pretty=medium refs/remotes/tfs/default --
git command: Starting process: git log --no-color --pretty=medium refs/remotes/tfs/default..HEAD --
git command time: [00:00:00.0210000] log --no-color --pretty=medium refs/remotes/tfs/default..HEAD --
info: refs/remotes/tfs/default: Getting changesets from 60 to current ...
Cleaning...
CleanupWorkspaceDirectory: Could not find a part of the path 'C:\projects\Infinity\.git\tfs\default\workspace'.

the first thing that I'm not understanding is that the line ...Getting changesets from 60 to current ... The TFS repo is currently on changeset 59, and when I cloned the repo, it was on changeset 57. So on a fetch, I SHOULD be getting changesets 58 to current...

the second thing is the last error it gives me. Can anyone explain what is going on with the CleanupWorkspaceDirectory error?

EDIT:

One other thing I forgot to mention is that I have added another git remote to repository, and I have merged what's in refs/remotes/tfs/default with my branch that I have retrieved from the git repository. Not sure if that caused something in git-tfs to break...

Was it helpful?

Solution

the first thing that I'm not understanding is that the line ...Getting changesets from 60 to current ... The TFS repo is currently on changeset 59, and when I cloned the repo, it was on changeset 57. So on a fetch, I SHOULD be getting changesets 58 to current...

I don't have enough data to understand exaclty where your problem come from but I will try to give you enough understanding to let you solve it yourself...

The line Getting changesets from 60 to current ... tell you that in the 'default' remote, the last changeset found is the 59 and that git-tfs is asking to tfs the changesets from 60 to the last to see if there is changes in the 'default' remote path (for exemple $/project/trunk). If there is no changes in this tfs path, no commit will be created.

So your problem could come from 3 things :

  • changes have been made in your other tfs path (managed by your other tfs remote). Then you should either fetch from all your remote with git tfs fetch -all or checkout your other branch and use git tfs fetch -I (that automatically get the good remote) or git tfs fetch -i idOfYourOtherRemote (if you want to specify yourself the remote to use)
  • you have messed something with the git-tfs metadata that broke git-tfs (perhaps during your merge). Be sure that only commits created from tfs changeset contains metadata git-tfs-id:[http://server:8080/tfs/teamCollection/]$/.../;Cxxin the commit message. These metadata are important for git-tfs and should not be modified or added to normal commit not fetched from tfs.
  • (less probable) the commits from tfs has already been fetch by someone else in another git repository from where you have fetch. And the commits have been found already in your repository and not fetched again. But in this case, you should see them in the 'default' remote history...

One other thing I forgot to mention is that I have added another git remote to repository, and I have merged what's in refs/remotes/tfs/default with my branch that I have retrieved from the git repository. Not sure if that caused something in git-tfs to break..

perhaps. let's check your metadata...

the second thing is the last error it gives me. Can anyone explain what is going on with the CleanupWorkspaceDirectory error?

That's not a problem. During cleanup (after all the important work was done) , git-tfs try to delete the temporary workspace directory. Because you fetched no changesets, the directory is not created and can't be found.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top