E&S CVS Commit: PEAK - Fixes for lazy imports and whenImported(). Previously, a direct import of
pje at eby-sarna.com
pje at eby-sarna.com
Wed Dec 24 17:33:00 EST 2003
Module Name: PEAK
Committed By: pje
Date: Wed Dec 24 22:32:19 UTC 2003
Modified Files:
PEAK/src/peak/util: imports.py
Log Message:
Fixes for lazy imports and whenImported(). Previously, a direct import of
a lazily imported module whose parent package wasn't imported (lazily or
otherwise) could cause an error. Also, setting an attribute of a lazy
module didn't necessarily trigger the module to be imported. Finally,
whenImported() doesn't create lazy modules until the module's parent is
loaded (except for top-level packages). This reduces unnecessary clutter
in 'sys.modules', and avoids giving the impression that such modules are
actually present in the system until at least their parent package exists.
To view diffs of this commit, you can use the following URL(s):
http://cvs.eby-sarna.com/PEAK/src/peak/util/imports.py.diff?r1=1.14&r2=1.15
To generate a diff of this commit:
cvs rdiff -r1.14 -r1.15 PEAK/src/peak/util/imports.py
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
More information about the source-changes
mailing list