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 ronaldoussoren
Recipients brett.cannon, eric.snow, ncoghlan, ronaldoussoren
Date 2013-12-01.14:11:34
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1385907094.98.0.564664253092.issue19851@psf.upfronthosting.co.za>
In-reply-to
Content
To reproduce:

* create a package with the following structure:

    pkg/
      __init__.py
      _sub.py

* __init__.py contains:

   from pkg._sub import *

* the contents of _sub.py is not important

* in a python shell do:

>>> import pkg._sub as s
>>> import imp
>>> imp.reload(s)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/imp.py", line 297, in reload
    return importlib.reload(module)
  File "/Library/Frameworks/Python.framework/Versions/3.4/lib/python3.4/importlib/__init__.py", line 123, in reload
    raise ImportError(_bootstrap._ERR_MSG.format(name), name=name)
ImportError: No module named 'pkg._sub'
>>> 

In earlier python versions this reloaded the pkg._sub module.  Importing _sub from __init__ doesn't seem to be important.
History
Date User Action Args
2013-12-01 14:11:35ronaldoussorensetrecipients: + ronaldoussoren, brett.cannon, ncoghlan, eric.snow
2013-12-01 14:11:34ronaldoussorensetmessageid: <1385907094.98.0.564664253092.issue19851@psf.upfronthosting.co.za>
2013-12-01 14:11:34ronaldoussorenlinkissue19851 messages
2013-12-01 14:11:34ronaldoussorencreate