cvs2hg MemoryError

Greg Ward greg-hg at gerg.ca
Wed Sep 2 15:48:34 CDT 2009


On Wed, Sep 2, 2009 at 3:14 PM, David I.<yigyw4d02 at sneakemail.com> wrote:
> I am trying to run cvs2hg using the download: "cvs2svn-bd8aed34af44" from
> http://vc.gerg.ca/hg/cvs2svn/.
>
> cvs2svn works on this repo, but cvs2hg gets a memory error. How can I fix
> this?
>
> Traceback (most recent call last):
>   File "../cvs2svn2/cvs2hg", line 87, in <module>
>     hg_main(os.path.basename(sys.argv[0]), sys.argv[1:])
[...]
>   File "/home/imat/lib/python/mercurial/filelog.py", line 13, in __init__
>     "/".join(("data", path + ".i")))
>   File "/home/imat/lib/python/mercurial/revlog.py", line 442, in __init__
>     i = f.read(_prereadsize)
> MemoryError

I have seen similar errors myself and am unable to reliably reproduce
them.  Workaround: run only the output pass, e.g.

  cvs2hg [...other args...] --pass 16

So far, that has worked for me every time.  No idea why.  Updating
README.cvs2hg now...

> Not sure if this is related, but I get these warnings when I start cvs2hg:
>
> /home/imat/lib/python/mercurial/context.py:10: RuntimeWarning: Python C API
> version mismatch for module bdiff: This Python has API version 1013, module
> bdiff has version 1012.

Unrelated.  That just means you're running cvs2hg with a different
version of Python than was used to build Mercurial.  That's a bit
dodgy, but there are definitely worse things you can do on a computer.
 ;-)

Greg



More information about the Mercurial mailing list