Git Product home page Git Product logo

Comments (5)

spraints avatar spraints commented on May 22, 2024

Interesting find. I'm not sure what the best way to deal with this is. Querying all changesets would work. Would querying all changesets from the team project be good enough? I.e. is your clone a deep path into a project, as opposed to an entire team project?

Also, is the changeset that moved the directory reflected in the git history at all? You may be able to view it directly with "git show tfs/default/C####", using the #### of the changeset that moved the files out of the target directory.

from git-tfs.

fschwiet avatar fschwiet commented on May 22, 2024

I made changes to query all changesets. It will only git commit if the changeset affects the targetted tree.

It is very slow. I have to wait a bit to see if it works :)

from git-tfs.

fschwiet avatar fschwiet commented on May 22, 2024

It didn't work. :) I think there is a problem in the code.

Any thoughts on how best to debug git-tfs? Currently I flip to visual studio and attach to process as its running. This isn't sufficient when the problem occurs before I can attach the debugger.

After running the code, which you might review here: http://github.com/fschwiet/git-tfs/commit/a1e2707a89917e384e658bc70799c967292cc65c it ran for awhile then failed due to network connectivity loss. In the meantime only two changesets were picked up, it was still scanning through changeset history to get to changesets that affect the branch I was looking at.

Anyhow, after it failed, it looks like the problem is there is no HEAD branch. The results of git show-ref look wrong, can you verify this is not as expected?

$ git show-ref
c708dd0b8a05e107206f5ca08aaaf68ca40a617f refs/remotes/tfs/default
849b041c10adf4a03b72aa619657f2a15649989f refs/tags/tfs/default/C36060
c708dd0b8a05e107206f5ca08aaaf68ca40a617f refs/tags/tfs/default/C51191

I would expect to see a master branch and a head. Not sure how my changes could have caused this problem, maybe the network failure prevented them from being created.

thanks

from git-tfs.

spraints avatar spraints commented on May 22, 2024

I usually debug git-tfs by running it directly in VS. In the project properties debug panel, if you set the working directory and command line arguments, it should work. I sometimes have problems with git-tfs not being able to find git, which you can fix by setting the full path to git.cmd in [1]

It sounds like you ran into two problems: HEAD not existing and the fetch failing.

HEAD is initialized by clone after the fetch finishes. So if fetch failed after pulling two changesets, then I wouldn't expect HEAD or master to be set up right.

So the real problem is that fetch isn't working right. I wonder if the TFS client lib is expecting the HTTP connection to be open at [2], but if it's closed because of a timeout or other problem. Hopefully debugging will help you figure that out.

[1] http://github.com/spraints/git-tfs/blob/master/GitTfs/Core/GitHelpers.cs#L215

[2] http://github.com/fschwiet/git-tfs/commit/a1e2707a89917e384e658bc70799c967292cc65c#L7R155

from git-tfs.

spraints avatar spraints commented on May 22, 2024

I'm closing this because of inactivity.

However, if you're still running into this problem, I've added a 'verify' command (git tfs verify) that will check for differences between TFS and git.

Please reopen this if you're still having a problem.

from git-tfs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.