git-svn clone fails unexpectedly

I run the following:

git svn clone --stdlayout --no-metadata -A users.txt -r 3760:4662 svn:// S4-Geocoding-SVN.git

It begins running and runs fine for a while, then bombs:

  • Serving directory from webserver if its also GIT repo
  • best way to export Eclipse project to GitHub
  • Error when cloning git “shallow” repository
  • Calling Groovy script as a pre-commit hook on my subrepository using smartgit broken
  • What are the advantages/disadvantages of Git's snapshot-based approach in practice compared to the traditional VCSs?
  • gcloud init fails for invalid username/password
  • ...
            M       S4.Geocoding.Client/App.xaml.cs
            M       S4.Geocoding.Client/MainPage.xaml.cs
            M       S4.Geocoding.Client/CodingPage.xaml
            M       S4.Geocoding.Client/CodingPage.xaml.cs
    r4163 = 498dad8ce3730390393fc13b183fdbbff7108e6b (refs/remotes/trunk)
            M       S4.Geocoding.Client/CodingPage.xaml.cs
    r4164 = 728b706b27d60d91659c144c3fac98cdbd1b09b2 (refs/remotes/trunk)
    Found possible branch point: svn:// => svn://, 4160
    Use of uninitialized value $u in substitution (s///) at /usr/libexec/git-core/git-svn line 1728.
    Use of uninitialized value $u in concatenation (.) or string at /usr/libexec/git-core/git-svn line 1728.
    refs/remotes/trunk: 'svn://' not found in ''

    What could be going on? I don’t know where to start to troubleshoot this.

  • Git - Mastering Terminology
  • Can GIT, Mercurial, SVN, or other version control tools work well when project tree has binary files?
  • git push folder contaning large file
  • Git: removing a file from being versioned, but not deleting it
  • using git pull/push via sftp-only connection
  • Why, in some situation does “git checkout origin/branch” result in “detached at <SHA>” instead of “detached at origin/master”?
  • 2 Solutions collect form web for “git-svn clone fails unexpectedly”

    As me_and suggests, this is probably a Git bug. After poking around the source code, it appeared that the problem was related to metadata. I was able to work around it by removing the --no-metadata flag.

    As illustrated here or here, passing a bad trunk (becuse of a non-standard svn structure) will cause this error.

    Git 2.9 will be less verbose (will die quicker).
    See commit 523a33c (07 May 2016) by Christian Couder (chriscool).
    (Merged by Eric Wong — ele828 — in commit 523a33c, 08 May 2016)

    Git/SVN: die when there is no commit metadata

    When passing a bad --trunk option to git svn clone, like for example the same URL that we are cloning.

    Let’s fix that by just die()ing when we have an uninitialized value because we cannot get commit metadata from a ref.

    That avoids all the additional error messages like:

    Found possible branch point...
    Use of uninitialized value $u in substitution (s///) at...
    Git Baby is a git and github fan, let's start git clone.