Re: Proposal for a lazy-loading finder

Nick Coghlan <[email protected]> Sun, 9 Jul 2017 17:14:08 +1000
Newsgroups gmane.comp.python.import
Message-ID <CADiSq7dg331pF0vwefH5mS7bSLe+kqDCB8WT6_4VHTRKk6MJ_g@mail.gmail.com>
On 9 July 2017 at 17:02, Nick Coghlan <[email protected]> wrote:
> The technical approach seems sound, but from a naming perspective I'd
> suggest going with the more self-explanatory "ensure_lazy" and
> "ensure_eager" rather than "whitelist" and "blacklist".

One minor technical nit that I missed on first reading: rather than
rebinding sys.path_hooks and sys.path_importer_cache when activating
lazy loading, I'd suggest modifying them in-place via slice assignment
and dict.update.

Cheers,
Nick.

-- 
Nick Coghlan   |   [email protected]   |   Brisbane, Australia