schacon / hg-git

mercurial to git bridge, pushed to directly from the hg-git plugin in Hg
GNU General Public License v2.0
620 stars 72 forks source link

"No module named ignore" #308

Closed bcmills closed 8 years ago

bcmills commented 8 years ago

After upgrading the local packages on my Debian machine, hg-git no longer works.

I'm using the Debian Python package, but hg-git installed via easy_install:

bryan@brahms:~$ hg pull
*** failed to import extension hggit: No module named ignore
** unknown exception encountered, please report by visiting
** http://mercurial.selenic.com/wiki/BugTracker
** Python 2.7.10 (default, Sep 13 2015, 20:30:50) [GCC 5.2.1 20150911]
** Mercurial Distributed SCM (version 3.5.2)
** Extensions loaded: convert
Traceback (most recent call last):
  File "/usr/bin/hg", line 43, in <module>
    mercurial.dispatch.run()
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 30, in run
    sys.exit((dispatch(request(sys.argv[1:])) or 0) & 255)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 92, in dispatch
    ret = _runcatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 163, in _runcatch
    return _dispatch(req)
  File "/usr/lib/python2.7/dist-packages/mercurial/dispatch.py", line 862, in _dispatch
    repo = hg.repository(ui, path=path)
  File "/usr/lib/python2.7/dist-packages/mercurial/hg.py", line 136, in repository
    peer = _peerorrepo(ui, path, create)
  File "/usr/lib/python2.7/dist-packages/mercurial/hg.py", line 123, in _peerorrepo
    obj = _peerlookup(path).instance(ui, path, create)
  File "/usr/lib/python2.7/dist-packages/mercurial/hg.py", line 93, in _peerlookup
    return thing(path)
  File "/usr/local/lib/python2.7/dist-packages/hg_git-0.8.1-py2.7.egg/hggit/__init__.py", line 84, in _local
    p = urlcls(path).localpath()
TypeError: 'NoneType' object is not callable
bryan@brahms:~✘ sudo easy_install hg-git
Searching for hg-git
Best match: hg-git 0.8.1
Processing hg_git-0.8.1-py2.7.egg
hg-git 0.8.1 is already the active version in easy-install.pth

Using /usr/local/lib/python2.7/dist-packages/hg_git-0.8.1-py2.7.egg
Processing dependencies for hg-git
Finished processing dependencies for hg-git
bcmills commented 8 years ago

This appears to be https://bitbucket.org/durin42/hg-git/issues/157/hg-git-081-doesnt-work-under-mercurial-35

ches commented 8 years ago

AFAICT this is already fixed in hg-git 0.8.2, I had this issue and upgrading fixed it. 0.8.2 is released on PyPi, not sure why easy_install wasn't giving it to you but you may need to add the -U flag to get it to try to upgrade:

$ sudo easy_install -U hg-git

Of course, pip is usually a more pleasant experience overall :smile:

durin42 commented 8 years ago

Yep, this is fixed by 0.8.2.

Also, prefer the bitbucket issue tracker to this one.