demandimport error - configparser module not found with Mercurial 2.5

Issue #22 resolved
Harald Klimach
created an issue

I am not sure, if this is the right place to report it, and if the problem is not due to my setup, but something is strange.

I freshly installed Mercurial 2.5 and after testing it worked, added the keyring extension, which caused a failure when attempting to clone with an error complaining about configparser module not found. I am on Python 2.7.3, and the module is named ConfigParser, but the keyring extension implements as py27compat module that should deal with it. However, due to Mercurials module this does not seem to work properly here.

Putting 'configparser' into the ignore list of resolved the issue. I have no idea, if this is the correct thing to do, though.

Comments (9)

  1. Jason R. Coombs

    Yes, in Keyring 1.1, a substantial refactoring took place which was intended to be backward compatible (and is backward compatible in the published API), but mercurial_keyring does some special tricks with the demandimporter (keyring changelog). I believe the proposed fix is correct.

    Additionally, there may be issues with other try/except import blocks in py25compat. Please consider those when updating the ignore list.

  2. Gurce Isikyildiz

    I'm having this same problem on an Ubuntu pc, using python 2.7.

    I'd like to upgrade to 0.5.4 for the fix, but each time I type "easy_install --upgrade mercurial_keyring", it tells me:

    Searching for mercurial-keyring
    Best match: mercurial-keyring 0.5.3
    Processing mercurial_keyring-0.5.3-py2.7.egg
    mercurial-keyring 0.5.3 is already the active version in easy-install.pth
    Using /usr/local/lib/python2.7/site-packages/mercurial_keyring-0.5.3-py2.7.egg
    Processing dependencies for mercurial-keyring
    Finished processing dependencies for mercurial-keyring

    It thinks 0.5.3 is already the latest and is installed. How come easy_install can't see your newer 0.5.4?

  3. Log in to comment