<div dir="ltr"><div>in cvs2svn option file :</div>
<div>&nbsp;</div>
<div># You might want to be especially strict when converting filenames to<br># unicode (e.g., maybe not specify a fallback_encoding).<br>ctx.cvs_filename_decoder = CVSTextDecoder(<br>&nbsp;&nbsp;&nbsp; [<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &#39;latin1&#39;,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; #&#39;utf8&#39;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; #&#39;ascii&#39;,<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ],<br>&nbsp;&nbsp;&nbsp; fallback_encoding=&#39;ascii&#39;<br>&nbsp;&nbsp;&nbsp; )<br><br></div>
<div>I&#39;ve added the ppa repositiory for ubuntu apt-get and update to <a href="http://1.7.0.1">1.7.0.1</a> and will try again.</div>
<div>Thomas</div>
<div>&nbsp;</div>
<div class="gmail_quote">On Tue, Oct 7, 2008 at 17:22, Jelmer Vernooij <span dir="ltr">&lt;<a href="mailto:jelmer@samba.org">jelmer@samba.org</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Am Dienstag, den 07.10.2008, 17:03 +0200 schrieb Thomas Manson:<br>
<div class="Ih2E3d">&gt; Hi Michael,<br>&gt;<br>&gt; &nbsp; I&#39;ve checkout the trunk version (the version on ubuntu hardy heron<br>&gt; is quite old : 2.0.1)<br>&gt; &nbsp; succeed in cvs2svn conversion,<br>&gt;<br>&gt; &nbsp;unfortunately it crashes in the same way that bzr cvsps-import<br>
&gt; does :<br>&gt;<br>&gt;<br>&gt; thomas@home:~/temp/bzr$<br>&gt; cat ../cvs2svn-tmp/git-blob.dat &nbsp;../cvs2svn-tmp/git-dump.dat | &nbsp;bzr<br>&gt; fast-import -<br>&gt; bzr: ERROR: exceptions.UnicodeDecodeError: &#39;utf8&#39; codec can&#39;t decode<br>
&gt; bytes in position 43-45: invalid data<br></div>The problem seems to be that one of the characters in your CVS<br>repository is not valid as UTF8 character. Did you specify the locale in<br>which the filenames are encoded explicitly somehow?<br>
<br>Git does not have this problem, since it does not interpret any of the<br>filenames you store in it. This has advantages (conversion can&#39;t fail<br>since you&#39;re not doing conversion at at all), but it also has<br>
disadvantages - checking out the repository on hosts with a different<br>encoding breaks the filenames.<br><br>Cheers,<br><br>Jelmer<br>
<div>
<div></div>
<div class="Wj3C7c"><br>&gt; Traceback (most recent call last):<br>&gt; &nbsp; File &quot;/usr/lib/python2.5/site-packages/bzrlib/commands.py&quot;, line<br>&gt; 834, in run_bzr_catch_errors<br>&gt; &nbsp; &nbsp; return run_bzr(argv)<br>
&gt; &nbsp; File &quot;/usr/lib/python2.5/site-packages/bzrlib/commands.py&quot;, line<br>&gt; 790, in run_bzr<br>&gt; &nbsp; &nbsp; ret = run(*run_argv)<br>&gt; &nbsp; File &quot;/usr/lib/python2.5/site-packages/bzrlib/commands.py&quot;, line<br>
&gt; 492, in run_argv_aliases<br>&gt; &nbsp; &nbsp; return self.run(**all_cmd_args)<br>&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/__init__.py&quot;, line<br>&gt; 199, in run<br>&gt; &nbsp; &nbsp; params, verbose)<br>&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/__init__.py&quot;, line 77,<br>
&gt; in _run<br>&gt; &nbsp; &nbsp; return proc.process(p.iter_commands)<br>&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/processor.py&quot;, line<br>&gt; 83, in process<br>&gt; &nbsp; &nbsp; self._process(command_iter)<br>&gt; &nbsp; File<br>
&gt; &quot;/home/thomas/.bazaar/plugins/fastimport/processors/generic_processor.py&quot;, line 317, in _process<br>&gt; &nbsp; &nbsp; processor.ImportProcessor._process(self, command_iter)<br>&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/processor.py&quot;, line<br>
&gt; 105, in _process<br>&gt; &nbsp; &nbsp; handler(self, cmd)<br>&gt; &nbsp; File<br>&gt; &quot;/home/thomas/.bazaar/plugins/fastimport/processors/generic_processor.py&quot;, line 486, in commit_handler<br>&gt; &nbsp; &nbsp; handler.process()<br>
&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/processor.py&quot;, line<br>&gt; 164, in process<br>&gt; &nbsp; &nbsp; for fc in self.command.file_iter():<br>&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/parser.py&quot;, line 312,<br>
&gt; in iter_file_commands<br>&gt; &nbsp; &nbsp; yield self._parse_file_modify(line[2:])<br>&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/parser.py&quot;, line 365,<br>&gt; in _parse_file_modify<br>&gt; &nbsp; &nbsp; path = self._path(params[2])<br>
&gt; &nbsp; File &quot;/home/thomas/.bazaar/plugins/fastimport/parser.py&quot;, line 493,<br>&gt; in _path<br>&gt; &nbsp; &nbsp; return s.decode(&#39;utf_8&#39;)<br>&gt; &nbsp; File &quot;/usr/lib/python2.5/encodings/utf_8.py&quot;, line 16, in decode<br>
&gt; &nbsp; &nbsp; return codecs.utf_8_decode(input, errors, True)<br>&gt; UnicodeDecodeError: &#39;utf8&#39; codec can&#39;t decode bytes in position 43-45:<br>&gt; invalid data<br>&gt; bzr 1.3.1 on python 2.5.2.final.0 (linux2)<br>
&gt; arguments: [&#39;/usr/bin/bzr&#39;, &#39;fast-import&#39;, &#39;-&#39;]<br>&gt; encoding: &#39;UTF-8&#39;, fsenc: &#39;UTF-8&#39;, lang: &#39;en_US.UTF-8&#39;<br>&gt; plugins:<br>&gt;<br>&gt; bzrtools &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; /usr/lib/python2.5/site-packages/bzrlib/plugins/bzrtools [1.3.0]<br>
&gt; &nbsp; cvsps_import &nbsp; &nbsp; &nbsp; &nbsp; /home/thomas/.bazaar/plugins/cvsps_import<br>&gt; [unknown]<br>&gt; &nbsp; fastimport &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; /home/thomas/.bazaar/plugins/fastimport<br>&gt; [unknown]<br>&gt;<br>&gt; launchpad &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;/usr/lib/python2.5/site-packages/bzrlib/plugins/launchpad [unknown]<br>
&gt; *** Bazaar has encountered an internal error.<br>&gt; &nbsp; &nbsp; Please report a bug at <a href="https://bugs.launchpad.net/bzr/+filebug" target="_blank">https://bugs.launchpad.net/bzr/+filebug</a><br>&gt; &nbsp; &nbsp; including this traceback, and a description of what you<br>
&gt; &nbsp; &nbsp; were doing when the error occurred.<br>&gt;<br>&gt;<br>&gt; I don&#39;t think it&#39;s related to cvs2svn or cvsps as it fails in both<br>&gt; cases.<br>&gt; It should be a bzr bug.<br>&gt;<br>&gt; I&#39;ve successfully converted my project to git repository format with<br>
&gt; these set of command :<br>&gt;<br>&gt; export CVSROOT=/home/thomas/temp/cvs2git/cvs/files<br>&gt;<br>&gt; git cvsimport -C /home/thomas/temp/cvs2gitOutput/crf-irp<br>&gt; crf-irp<br>&gt; git cvsimport -C /home/thomas/temp/cvs2gitOutput/crf-irp-model<br>
&gt; crf-irp-model<br>&gt; git cvsimport -C /home/thomas/temp/cvs2gitOutput/crf-irp-monitor<br>&gt; crf-irp-monitor<br>&gt; git cvsimport -C /home/thomas/temp/cvs2gitOutput/crf-irp-portail<br>&gt; crf-irp-portail<br>&gt; git cvsimport -C /home/thomas/temp/cvs2gitOutput/crf-irp-utilities<br>
&gt; crf-irp-utilities<br>&gt;<br>&gt;<br>&gt; Is it possible to convert the git version of my sources to bzr ? maybe<br>&gt; it would be successfull.<br>&gt;<br>&gt;<br>&gt; Thomas.<br>&gt;<br>&gt;<br>&gt;<br>&gt;<br>&gt; On Tue, Oct 7, 2008 at 12:41, Michael Haggerty &lt;<a href="mailto:mhagger@alum.mit.edu">mhagger@alum.mit.edu</a>&gt;<br>
&gt; wrote:<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; Jelmer Vernooij wrote:<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; &gt; Am Dienstag, den 07.10.2008, 00:01 +0200 schrieb Thomas<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; Manson:<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; &gt;&gt; I&#39;ve look to it... but didn&#39;t tryed yet...<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &gt;&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; &gt;&gt; It really misses straightforward howto (for all tools<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; except bzr<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; &gt;&gt; cvsimport)<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; &gt; cvsps-import should be the best solution here, we should<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; just fixing<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; &gt; that imho. What&#39;s blocking you from using it?<br>&gt;<br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; No conversion tool that is based on cvsps will be able to do a<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; truly<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; reliable job of migrating from CVS. &nbsp;cvsps, which was written<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; for<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; another purpose, simply is not robust enough and does not emit<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; enough<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; information for a complete conversion. &nbsp;I gave many concrete<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; examples of<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; its shortcomings on the Mercurial mailing list [1].<br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; Deducing a project&#39;s history from CVS&#39;s incomplete records is<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; a very<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; tricky thing; cvs2svn&#39;s feature list [2] will give you an idea<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; of the<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; kinds of things an industrial-strength converter needs to<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; handle.<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; cvs2svn deduces the CVS changesets itself, using a much more<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; robust<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; algorithm than that used by cvsps. &nbsp;(The main disadvantage of<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; cvs2svn is<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; that it can only be used for one-time conversions, not for<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; tracking a<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; live CVS repository incrementally.)<br>
&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; cvs2svn/cvs2git can create output in git-fast-import format<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; [3], which<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; should also be readable by the bzr fast-import tool. &nbsp;It<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; hasn&#39;t gotten<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; much testing in &quot;cvs2bzr&quot; mode, but given that 90% of the job<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; is<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; inferring CVS&#39;s history, it should not be too much work to fix<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; any<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; problems in the &quot;2bzr&quot; part. &nbsp;Therefore, any feedback would be<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; much<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; appreciated.<br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; (By the way, if you want to use cvs2svn to convert to bzr, I<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; suggest<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; that you use the trunk version of cvs2svn, which has several<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; improvements compared to release <a href="http://2.1.1./" target="_blank">2.1.1.</a>)<br>
&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; Michael<br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; [1]<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; <a href="http://selenic.com/pipermail/mercurial-devel/2008-February/004975.html" target="_blank">http://selenic.com/pipermail/mercurial-devel/2008-February/004975.html</a><br>
&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; [2] <a href="http://cvs2svn.tigris.org/features.html" target="_blank">http://cvs2svn.tigris.org/features.html</a><br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp; &nbsp; [3] <a href="http://cvs2svn.tigris.org/cvs2git.html" target="_blank">http://cvs2svn.tigris.org/cvs2git.html</a><br>
&gt;<br><br></div></div><font color="#888888">--<br>Jelmer Vernooij &lt;<a href="mailto:jelmer@samba.org">jelmer@samba.org</a>&gt; - <a href="http://samba.org/~jelmer/" target="_blank">http://samba.org/~jelmer/</a><br>Jabber: <a href="mailto:jelmer@jabber.fsfe.org">jelmer@jabber.fsfe.org</a><br>
<br></font></blockquote></div><br></div>