crash in hgk on fedora f12

Dirkjan Ochtman dirkjan at ochtman.nl
Mon Sep 28 06:06:49 CDT 2009


On Mon, Sep 28, 2009 at 12:06, Neal Becker <ndbecker2 at gmail.com> wrote:
> Here's the trace:
>
> Traceback (most recent call last):
>  File "/usr/lib64/python2.6/site-packages/hgext/hgk.py", line 37, in
> <module>
>    from mercurial import commands, util, patch, revlog, cmdutil
>  File "/usr/lib64/python2.6/site-packages/mercurial/commands.py", line 11,
> in <module>
>    import os, re, sys, subprocess, difflib, time
>  File "/usr/lib64/python2.6/difflib.py", line 36, in <module>
>    from collections import namedtuple as _namedtuple
>  File "/usr/lib64/python2.6/collections.py", line 10, in <module>
>    from keyword import iskeyword as _iskeyword
>  File "/usr/lib64/python2.6/site-packages/hgext/keyword.py", line 77, in
> <module>
>    from mercurial import commands, cmdutil, dispatch, filelog, revlog,
> extensions
>  File "/usr/lib64/python2.6/site-packages/mercurial/cmdutil.py", line 11,
> in <module>
>    import mdiff, bdiff, util, templater, patch, error, encoding
>  File "/usr/lib64/python2.6/site-packages/mercurial/templater.py", line 10,
> in <module>
>    import util, config, templatefilters
>  File "/usr/lib64/python2.6/site-packages/mercurial/templatefilters.py",
> line 8, in <module>
>    import cgi, re, os, time, urllib, textwrap
>  File "/usr/lib64/python2.6/cgi.py", line 40, in <module>
>    import urllib
>  File "/usr/lib64/python2.6/urllib.py", line 30, in <module>
>    from urlparse import urljoin as basejoin
>  File "/usr/lib64/python2.6/urlparse.py", line 84, in <module>
>    from collections import namedtuple
> ImportError: cannot import name namedtuple

That's pretty weird, but it doesn't appear to be Mercurial's bug. We
import urllib, which is certainly available from Python 2.6 (which
seems to be used here), and from there on we don't really care. The
really weird part is that 2.6's collections module should have
namedtuple just fine (and it does on my boxes). Might be some garbage
in the PYTHONPATH?

Cheers,

Dirkjan



More information about the Mercurial-devel mailing list