Module lazily
Lazily import pycocoa
modules and attributes, based on lazy_import from Brett Cannon's modutil.
Lazy import
is supported only for Python 3.7+ and is enabled by default in PyCocoa
20.01.30 and later.
To disable lazy import
, set environment variable
PYCOCOA_LAZY_IMPORT
to 0
or an empty string.
Use 2
or higher to print a message for each lazily imported
module and attribute, similar to environment variable
PYTHONVERBOSE
showing imports. Using 3
or
higher also shows the importing file name and line number.
Note:
Lazy import
applies only to top-level modules of
pycocoa
. A lazy import
of a top-level
module also loads all sub-modules imported by that top-level
module.
Version:
25.01.16
|
LazyImportError
Lazy import is not supported, disabled or failed some other way.
|
|
isLazy = None
Lazy import setting (int 0, 1, 2 or 3+) from environment
variable PYCOCOA_LAZY_IMPORT , or None if
lazy import is not supported or not enabled, or
False if initializing lazy import failed.
|