The check for broken symlinks introduced in dbc6c74d0 "git-svn: handle empty files marked as symlinks in SVN" changed git-svn fetch behavior for a real-life repository I need to access. It doesn't have broken symlinks. The repository had a branch deleted and recreated off of a different branch point. The new branch point has empty files not in the original branch point. It seems the symlink check _mark_empty_symlinks fetches the wrong SVN revision of the empty files in this special case. git-svn fetch stops with an error like Filesystem has no item: File not found: revision 4, path '/branches/branch-c/b1' at git-svn line 3288 Which is true, there is no such file, but in my case the empty file b1 is in revision 6 (new branch-c copied from branch-b@r5 where the original branch-c was deleted), not revision 4 (original branch-c copied from trunk in r4). I used the following shell script to produce a test repository that displays the symptom: #!/bin/bash SVNREPO=file:///$PWD/test.db svnadmin create test.db svn co $SVNREPO testreposvn cd testreposvn mkdir trunk branches svn add trunk branches svn ci -m "init standard layout" svn cp trunk branches/branch-b svn ci -m 'branch-b off trunk' touch branches/branch-b/b1 svn add branches/branch-b/b1 svn ci -m 'add empty file b1' svn cp -m 'branch-c' $SVNREPO/{trunk,branches/branch-c} svn del -m 'oops, wrong branchpoint' $SVNREPO/branches/branch-c svn cp -m 'branch-c off of branch-b' $SVNREPO/branches/{branch-b,branch-c} ---- This leaves the svn repository in ./test.db, svn working copy in ./testreposvn. And the problem: $ git init -s file:///$PWD/test.db testrepogit Initialized empty Git repository in /tmp/test/testrepogit/.git/ $ cd testrepogit $ git --version git version 1.6.2.rc0 $ git svn fetch r1 = ff1aea02906c970caa49055db564158d6911a512 (trunk) Found possible branch point: file:////tmp/test/test.db/trunk => file:////tmp/test/test.db/branches/branch-b, 1 Found branch parent: (branch-b) ff1aea02906c970caa49055db564158d6911a512 Following parent with do_switch Successfully followed parent r2 = d0f256cbf64dc1e49597e54a55538758ca70d65f (branch-b) A b1 r3 = 48d511b172a95a609d5e10f1275664e6b4ca4e62 (branch-b) Found possible branch point: file:////tmp/test/test.db/trunk => file:////tmp/test/test.db/branches/branch-c, 3 Found branch parent: (branch-c) ff1aea02906c970caa49055db564158d6911a512 Following parent with do_switch Successfully followed parent r4 = 57923c03b201b2dbbb9d52b81e198a1a78b9de44 (branch-c) Found possible branch point: file:////tmp/test/test.db/branches/branch-b => file:////tmp/test/test.db/branches/branch-c, 5 Found branch parent: (branch-c) 48d511b172a95a609d5e10f1275664e6b4ca4e62 Index mismatch: 934e48f4addc4882a9b7b99615348569d531c873 != 4b825dc642cb6eb9a060e54bf8d69288fbee4904 rereading 48d511b172a95a609d5e10f1275664e6b4ca4e62 Following parent with do_switch Filesystem has no item: File not found: revision 4, path '/branches/branch-c/b1' at git-svn line 3288 ---- Breaking out of _mark_empty_symlinks() before SVN access makes the git-svn fetch complete without errors but does record the original branch-c as parent which I did not expect but it kind of makes sense. I tried to figure out where the revision to fetch in _mark_empty_symlinks() comes from but eventually gave up as I am not that fluent in perl. Anton -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html