[Fwd: Re: Error converting P4 repo to Mercurial]

Ron Gery rong at gamani.com
Wed Jul 15 05:59:46 UTC 2009


Attached are the output when -v was used (which looks the same to me as 
without the -v), the error (same as below) and the "p4 describe" for 
both the last successful changelist (3797) and the one immediately 
following (3798). As you can see from the log, the conversion started at 
changelist 3768 even though I specified no start or end numbers and was 
hoping to go back to 0 or at least somewhere in the 3000s.

I was ready to start mucking with the python code, but the closest thing 
I found to "hgext/convert/p4.py" was a file called p4.pyc located at 
that path in library.zip in the TortoiseHg install folder. I didn't find 
any raw python code. I am completely ignorant in the ways of Python and 
have no idea how hg is running off of the zip file, so if there is 
actually somewhere else on my machine where I should be looking, please 
let me know. What I did for the installation was download the TortoiseHg 
package and install it.

Thanks

ron

----- Original Message -----
*From:* Frank Kingswood <frank at kingswood-consulting.co.uk>
*To:* Ron Gery <rong at gamani.com>
*CC:* mercurial at selenic.com
*Sent:* 07/14/2009 8:05:28 AM -0700
*Subject:* Error converting P4 repo to Mercurial



Ron Gery wrote:
> I am new to Mercurial and know nothing about Python. I am running on 
> Windows XP with the P4 depot hosted on the local machine. I'm trying to 
> convert my P4 repo to Mercurial, and regardless of what variations I've 
> tried for specifying the source (local path, depot address, changelist 
> limitations), I soon get the following error message (about 20 
> changelists, ending with the most recent one, are shown preceding the 
> error):
> 
> ** unknown exception encountered, details follow
> ** report bug details to http://mercurial.selenic.com/bts/
> ** or mercurial at selenic.com
> ** Mercurial Distributed SCM (version 1.3)
> ** Extensions loaded: extdiff, convert
> Traceback (most recent call last):
>   File "hg", line 38, in <module>
>   File "mercurial\dispatch.pyc", line 16, in run
>   File "mercurial\dispatch.pyc", line 27, in dispatch
>   File "mercurial\dispatch.pyc", line 43, in _runcatch
>   File "mercurial\dispatch.pyc", line 449, in _dispatch
>   File "mercurial\dispatch.pyc", line 317, in runcommand
>   File "mercurial\dispatch.pyc", line 501, in _runcommand
>   File "mercurial\dispatch.pyc", line 454, in checkargs
>   File "mercurial\dispatch.pyc", line 448, in <lambda>
>   File "mercurial\util.pyc", line 370, in check
>   File "hgext\convert\__init__.pyc", line 232, in convert
>   File "hgext\convert\convcmd.pyc", line 369, in convert
>   File "hgext\convert\convcmd.pyc", line 54, in convertsource
>   File "hgext\convert\p4.pyc", line 51, in __init__
>   File "hgext\convert\p4.pyc", line 109, in _parse
> EOFError: EOF read where object expected
> 
> My invocation looked like:
> hg convert //depot/gmg/... e:\test
> 
> I would simply love to be able to bring my history with me as I move to 
> Mercurial, but I'm out of my scope (and available time) in trying to 
> track this problem down. Is the above something other people have run 
> into, or is this cause by some sort of corruption in my P4 repo?

Thanks for your report. Can you re-run with -v to get more detail on the 
conversion. In your conversion there was an error while executing a p4 
describe command on the changelist *following* the last one you'll see from 
the conversion with -v.
It would be very helpful if you could post or mail the output from
	p4 describe <nextchangelist>
where you should insert the number of the changelist following the last one 
that was successfully read.

Alternatively, and if you are happy to try, you could put a line (properly 
indented)
	print cmd
immediately before line 109 in hgext\convert\p4.py in your Mercurial 
installation. This will show the changelist that causes the issue.

Frank


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20090714/08ad2474/attachment-0001.html>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: verbose.log
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20090714/08ad2474/attachment-0003.log>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 3797.log
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20090714/08ad2474/attachment-0004.log>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 3798.log
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20090714/08ad2474/attachment-0005.log>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: errormessage.txt
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20090714/08ad2474/attachment-0009.txt>


More information about the Mercurial mailing list