[docs] [issue30535] Explicitly note that meta_path is not empty
Nick Coghlan
report at bugs.python.org
Sat Jun 3 01:30:44 EDT 2017
Nick Coghlan added the comment:
s/Warn/Explicitly note/ in the issue title :)
I think this is actually both important enough and subtle enough to warrant a ".. note::" callout in the docs.
In Python 3, it would say to use `sys.meta_path.insert(0, finder)` if you want your finder to take precedence over the default search locations, and `sys.meta_path.append(finder)` if you only want it handle cases that aren't already handled by the default machine.
In Python 2, it would say that custom finders on `sys.meta_path` will always take precedence over the default machinery, and if you want to do otherwise, you'll need to use `importlib2` and install its loaders into `sys.meta_path` ahead of your own.
----------
title: Warn that meta_path is not empty -> Explicitly note that meta_path is not empty
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue30535>
_______________________________________
More information about the docs
mailing list