This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author scoder
Recipients scoder
Date 2012-11-03.13:20:21
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1351948821.5.0.882170021897.issue16393@psf.upfronthosting.co.za>
In-reply-to
Content
My guess is that line 454 in pkgutil.py should pass "pkg_name" into the import_module() function, not "pkg". I get the following error when compiling it with Cython:

Error compiling Cython file:
------------------------------------------------------------
...
        msg = "Relative module name {!r} not supported".format(fullname)
        raise ImportError(msg)
    if '.' in fullname:
        # Get the containing package's __path__
        pkg_name = fullname.rpartition(".")[0]
        pkg = importlib.import_module(pkg)
                                        ^
------------------------------------------------------------
pkgutil.py:454:41: local variable 'pkg' referenced before assignment
History
Date User Action Args
2012-11-03 13:20:21scodersetrecipients: + scoder
2012-11-03 13:20:21scodersetmessageid: <1351948821.5.0.882170021897.issue16393@psf.upfronthosting.co.za>
2012-11-03 13:20:21scoderlinkissue16393 messages
2012-11-03 13:20:21scodercreate