Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

git svn fetch failed (on svn tagging commit) #99

Open
przemoc opened this issue Dec 2, 2012 · 9 comments
Open

git svn fetch failed (on svn tagging commit) #99

przemoc opened this issue Dec 2, 2012 · 9 comments

Comments

@przemoc
Copy link

przemoc commented Dec 2, 2012

I'm trying to rebase my vapoursynth svn2git repo (that was initiated with svn2git -v --revision 2 http://vapoursynth.googlecode.com/svn/ command some time ago), but git svn fetch is failing on the svn commit performing tagging. (Same thing happens if you want to run svn2git from scratch.)

$ svn2git --rebase --verbose
Running command: git status --porcelain --untracked-files=no
Running command: git branch -l --no-color
* master
Running command: git branch -r --no-color
  repo.or.cz/master
  svn/trunk
Running command: git svn fetch
Found possible branch point: http://vapoursynth.googlecode.com/svn/trunk => http://vapoursynth.googlecode.com/svn/tags/R15, 331
Use of uninitialized value $u in substitution (s///) at /usr/share/perl5/Git/SVN.pm line 106.
Use of uninitialized value $u in concatenation (.) or string at /usr/share/perl5/Git/SVN.pm line 106.
refs/remotes/svn/trunk: 'http://vapoursynth.googlecode.com/svn' not found in ''

command failed:
2>&1 git svn fetch

I upgraded to git 1.8.0 (from debian unstable repository), but it didn't help.

The referenced part of SVN.pm is below

 89 sub resolve_local_globs {
 90         my ($url, $fetch, $glob_spec) = @_;
 91         return unless defined $glob_spec;
 92         my $ref = $glob_spec->{ref};
 93         my $path = $glob_spec->{path};
 94         foreach (command(qw#for-each-ref --format=%(refname) refs/#)) {
 95                 next unless m#^$ref->{regex}$#;
 96                 my $p = $1;
 97                 my $pathname = desanitize_refname($path->full_path($p));
 98                 my $refname = desanitize_refname($ref->full_path($p));
 99                 if (my $existing = $fetch->{$pathname}) {
100                         if ($existing ne $refname) {
101                                 die "Refspec conflict:\n",
102                                     "existing: $existing\n",
103                                     " globbed: $refname\n";
104                         }
105                         my $u = (::cmt_metadata("$refname"))[0];
106                         $u =~ s!^\Q$url\E(/|$)!! or die
107                           "$refname: '$url' not found in '$u'\n";
108                         if ($pathname ne $u) {
109                                 warn "W: Refspec glob conflict ",
110                                      "(ref: $refname):\n",
111                                      "expected path: $pathname\n",
112                                      "    real path: $u\n",
113                                      "Continuing ahead with $u\n";
114                                 next;
115                         }
116                 } else {
117                         $fetch->{$pathname} = $refname;
118                 }
119         }
120 }

I don't see anything special in r332. Any ideas what's wrong and how it can be fixed? It's definitely not about quoting apostrophes or quotation marks, as they aren't there.

@rnc
Copy link

rnc commented Dec 20, 2012

I'm also seeing that running it on https://xmappr.googlecode.com/svn/trunk (using Fedora F18 beta and git 1.8.0.2):

r170 = 92d4ae355533f81ecc80e04352f7b40e65f1e6e3 (refs/remotes/svn/trunk)
Found possible branch point: https://xmappr.googlecode.com/svn/trunk => https://xmappr.googlecode.com/svn/tags/0.9.0, 170
Use of uninitialized value $u in substitution (s///) at /usr/share/perl5/vendor_perl/Git/SVN.pm line 106.
Use of uninitialized value $u in concatenation (.) or string at /usr/share/perl5/vendor_perl/Git/SVN.pm line 106.
refs/remotes/svn/trunk: 'https://xmappr.googlecode.com/svn' not found in ''

command failed:
2>&1 git svn fetch 

@snowyu
Copy link

snowyu commented Feb 20, 2013

It's git-svn bug.

@TravisTheTechie
Copy link

Given this error, I followed the advice from http://stackoverflow.com/questions/3009738/what-does-this-svn2git-error-mean/4434188#4434188 and removed the duplicate entries under the remotes svn section in my .git/config. svn2git --rebase worked like a charm after that.

@amedee
Copy link

amedee commented Dec 18, 2014

Given that this is a git-svn bug, where does one report the bug so that it gets fixed? I'm getting tired of removing duplicate entries every couple of minutes and I have a several gigabyte SVN repo to process, with almost 15 years of commits.

@amedee
Copy link

amedee commented Dec 18, 2014

This bug was first noticed 2 years ago, it was confirmed to be a git-svn bug, and nothing has been done since. So I decided to take action. I have created a bug report for Git (git-svn) at Ubuntu Launchpad: https://bugs.launchpad.net/ubuntu/+source/git/+bug/1403767

@nirvdrum
Copy link
Owner

Thanks @amedee.

@trash-80
Copy link

This issue seems to happen because of the password issue. I ran into this issue after finally fixing the password issue mentioned in #59 and #195. Removing all lines containing tags and branches (not just the duplicates) from .git/config allowed me to continue.

@sytkov
Copy link

sytkov commented May 13, 2016

Thank you, @the-real-trash80 . Removal of svn remotes section in .git/config worked for me too.

@jekriske-lilly
Copy link

Will this be automatic anytime soon?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants