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

git-svn dcommits messages not in UTF-8 charset to mod_dav_svn?

From
MAMatthias Andree <matthias.andree@gmx.de>
Date
May 27, 2009, 16:16 UTC
Message-ID
<op.uuljhmmg1e62zd@balu.cs.uni-paderborn.de>
Greetings,

I had tried to use git cvsimport and git svn to transfer a CVS repository (I have access to it) to an SVN repository (where I don't have access to the repo, so I cannot use cvs2svn or similar).

The problem is that the CVS repo had non-UTF-8 commit log messages, and I didn't bother to convert them to UTF-8. However, SVN insists on encoding filenames and log messages in UTF-8.

"git svn dcommit" (which uses the SVN Perl bindings under the hood) happily committed such a non-UTF-8 message and br0ke the repo. The actual reason is that the SVN server (https://...) is now wedged, as in:

$ svn log -r130 svn: REPORT of '/repos/!svn/bc/130': 200 OK (https://svn-serv...de)

$ svn --xml log -r130 2>/dev/null [stdout:] <?xml version="1.0"?> <log> [stderr:] svn: REPORT of '/repos/!svn/bc/130': 200 OK (https://svn-serv...de)

$ svn propget --revprop svn:log -r130 https://svn-serv...de/path/ aktuelle version (disclaimer) kopf und fu?\223zeilen etc.

While mod_dav_svn arguably shouldn't accept b0rked messages, git-svn shouldn't attempt to commit them either. It seems that the svn command line utilities validate the message format by themselves, and apparently the svn server module (likely mod_dav_svn - or are there others?) does not.

So, could a) git-svn be modified to refuse dcommiting non-UTF-8 messages? b) mod_dav_svn be modified to refuse commits/propedits/propsets with non-UTF-8 messages?

I'm sorry to say I don't have information how the SVN server is configured and which version it's running.

Thanks.
-- 
Matthias Andree
Next: Eric Wong
Message 1 of 7 in “git-svn dcommits messages not in UTF-8 charset to mod_dav_svn?”
  1. Matthias AndreeMay 27, 2009
  2. Eric WongMay 28, 2009
  3. git-svn: refuse to dcommit non-UTF-8 messagesEric Wong, May 28, 2009
  4. Junio C HamanoMay 29, 2009
  5. Junio C HamanoMay 29, 2009
  6. Brandon CaseyMay 29, 2009
  7. t9139 uses ancient, backwards-compatible iconv namesEric Wong, May 30, 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.