A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-April/064454.html below:

[Python-Dev] Dropping __init__.py requirement for subpackages

[Python-Dev] Dropping __init__.py requirement for subpackagesPhillip J. Eby pje at telecommunity.com
Thu Apr 27 02:05:16 CEST 2006
At 04:57 PM 4/26/2006 -0700, Guido van Rossum wrote:
>On 4/26/06, Delaney, Timothy (Tim) <tdelaney at avaya.com> wrote:
> > Possibly. Perhaps it would be useful to have `is_package(dirname)`,
> > `is_rootpackage(dirname)` and `is_subpackage(dirname)` functions
> > somewhere (pkgutils?).
>
>YAGNI. Also note that not all modules or packages are represented by
>pathnames -- they could live in zip files, or be accessed via whatever
>other magic an import handler users.

FYI, pkgutil in 2.5 has utilities to walk a package tree, starting from 
sys.path or a package __path__, and it's PEP 302 compliant.  pydoc now uses 
this in place of directory inspection, so that documenting zipped packages 
works correctly.

These functions aren't documented yet, though, and probably won't be until 
next week at the earliest.

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4