Eric V. Smith
eric at trueblade.com
Tue May 15 19:26:31 CEST 2012
I'm looking at fixing pkgutil.extend_path in order to support namespace
packages where some portions use PEP-420 and some use extend_path.
The first thing I notice is that there are no tests for
extend_path currently just examines the filesystem directly, which means
it doesn't support portions in zip files or other finder/loaders.
But if I understand PJE and others correctly, the idea is to modify
extend_path so it calls the path_hook finders instead of looking at the
filesystem (in order to find the other __path__ entries). This looks
like a change in functionality: previously only real filesystem packages
would be found. With this change it would include other finders (like
zip files). While it's a change, it would align well with importlib.
Personally I'm okay with this change.
There's the added issue of how to deal with .pkg files. Is only
supporting them from the filesystem okay? Or is it worth the hassle of
creating some finder API to access them?
More information about the Import-SIG