Re: [Python-Dev] [Python-checkins] peps: Note that ImportError will no longer be raised due to a missing __init__.py

It's actually an ImportWarning, not Error (or at least that's what I meant on import-sig). If the module is eventually found then there is no error. On Thu, Apr 19, 2012 at 18:56, eric.smith <python-checkins@python.org>wrote:

On Thu, Apr 19, 2012 at 18:56, eric.smith wrote:
Given that there is no way to modify the __path__ of a namespace package (short of restarting python?), *should* it be an error if there is exactly one directory? Or is that just a case of "other tools out there, didn't happen to install them"? -jJ

On Wed, Apr 25, 2012 at 2:56 AM, Jim Jewett <jimjjewett@gmail.com> wrote:
Or you installed all of them into the same directory (as distro packages are likely to do). Also, a namespace package __path__ is still just a list - quite amenable to modification after creation. The only thing we're not currently promising in PEP 420 is a programmatic interface to redo the scan. Cheers, Nick. -- Nick Coghlan | ncoghlan@gmail.com | Brisbane, Australia

On Thu, Apr 19, 2012 at 18:56, eric.smith wrote:
Given that there is no way to modify the __path__ of a namespace package (short of restarting python?), *should* it be an error if there is exactly one directory? Or is that just a case of "other tools out there, didn't happen to install them"? -jJ

On Wed, Apr 25, 2012 at 2:56 AM, Jim Jewett <jimjjewett@gmail.com> wrote:
Or you installed all of them into the same directory (as distro packages are likely to do). Also, a namespace package __path__ is still just a list - quite amenable to modification after creation. The only thing we're not currently promising in PEP 420 is a programmatic interface to redo the scan. Cheers, Nick. -- Nick Coghlan | ncoghlan@gmail.com | Brisbane, Australia
participants (5)
-
Brett Cannon
-
Eric Smith
-
Eric V. Smith
-
Jim Jewett
-
Nick Coghlan