def enable(blacklist=None):
"""Enable global module dependency tracking.
A blacklist can be specified to exclude specific modules (and their import
hierachies) from the reloading process. The blacklist can be any iterable
listing the fully-qualified names of modules that should be ignored. Note
that blacklisted modules will still appear in the dependency graph; they
will just not be reloaded.
"""
global _blacklist
builtins.__import__ = _import
if blacklist is not None:
_blacklist = frozenset(blacklist)
评论列表
文章目录