git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: svn clone Checksum mismatch question

From
EWEric Wong <normalperson@yhbt.net>
Date
Mar 29, 2009, 06:08 UTC
Message-ID
<20090329060858.GB15773@dcvr.yhbt.net>
In-Reply-To
<83dfc36c0903270418q59a81290xcb8043b8c037be18@mail.gmail.com>
Anton Gyllenberg <anton@iki.fi> wrote:
> I hope I didn't hijack the thread with an unrelated issue.

No worries if you did. You helped me find a stupid bug in git-svn that's been there for 3 years. I couldn't help the original poster at all since he was working on a private repo and I can't support git-svn under Windows.

Show 24 quoted lines
> 2009/3/26 Anton Gyllenberg <anton@iki.fi>:
> > I don't know if this is the same issue, but the I get a similar error
> > on the public twisted-python repository on both windows and linux,
> > with several different versions and plenty of free disk space. As this
> > is a publicly accessible repository it should be easy to reproduce:
> >
> > git svn init -s svn://svn.twistedmatrix.com/svn/Twisted twisted
> > cd twisted
> > git svn fetch -r 13611:HEAD
> >
> > This ultimately dies with the following error:
> > W: +empty_dir: trunk/doc/core/howto/listings/finger/finger
> > r13612 = f6d995ac255e3dfa08a517a6e72fbcfe63feaaa0 (trunk)
> > Checksum mismatch:
> > branches/foom/--omg-optimized/twisted/internet/cdefer/cdefer.pyx
> > 264b0c5f7b3a00d401d1a5dcce67a3734f0eede3
> > expected: c7ccddd195f132926e20bab573da7ef3
> >     got: f006323ff4714ca52c0228ce6390d415
> 
> is branches/foom/--omg-optimized (like with the branch name being
> foom/--omg-optimized), not just branches/foom. Is think git-svn relies
> on the standard layout being branches directly under the branches/
> directory, but I don't see how this would get the paths mixed up like
> this.

Root problem: I misused "git ls-tree" for 3 years and nobody noticed. At least I'm glad the checksum verification every step of the way caught this bug and prevented propagating it into repository corruption.

Show 7 quoted lines
> Looking at what was done around this commit one finds odd stuff, like
> deleting directories in trunk and then copying from a previous
> revision of trunk to under the branch:
> http://twistedmatrix.com/trac/changeset/13611
> 
> I created a local test svn repository and tried to do something
> similar but git-svn had no problem with my test.
I was fooled by the weird copy sequences, too.
> This is issue is not critical for me in any way but if somebody wants
> to look into it I am happy to help out.

I guess few folks in the UNIX world are crazy enough to make pathnames prefixed with dashes :) But I do wonder how/if many repositories out there failed and nobody bothered to report it...

Patch in reply
-- 
Eric Wong
Previous: Anton GyllenbergNext: Eric Wong
Message 9 of 28 in “svn clone Checksum mismatch question”
  1. Gilbert LiddellMar 26, 2009
  2. Björn SteinbrinkMar 26, 2009
  3. Gilbert LiddellMar 26, 2009
  4. Sverre RabbelierMar 26, 2009
  5. Gilbert LiddellMar 26, 2009
  6. Johannes SchindelinMar 26, 2009
  7. Anton GyllenbergMar 26, 2009
  8. Anton GyllenbergMar 27, 2009
  9. Eric WongMar 29, 2009
  10. git-svn: fix ls-tree usage with dash-prefixed pathsEric Wong, Mar 29, 2009
  11. Junio C HamanoMar 29, 2009
  12. Eric WongMar 29, 2009
  13. Junio C HamanoMar 30, 2009
  14. Eric WongMar 30, 2009
  15. Junio C HamanoMar 30, 2009
  16. Eric WongMar 30, 2009
  17. Björn SteinbrinkMar 31, 2009
  18. Björn SteinbrinkMar 31, 2009
  19. Björn SteinbrinkMar 31, 2009
  20. tree_entry_interesting: Only recurse when the pathspec is a leading path componentBjörn Steinbrink, Mar 31, 2009
  21. Junio C HamanoApr 2, 2009
  22. match_tree_entry(): a pathspec only matches at directory boundariesJunio C Hamano, Apr 2, 2009
  23. Linus TorvaldsApr 2, 2009
  24. Björn SteinbrinkApr 2, 2009
  25. Junio C HamanoApr 3, 2009
  26. Björn SteinbrinkMar 30, 2009
  27. Anton GyllenbergMar 30, 2009
  28. Peter HarrisMar 26, 2009

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.