[issue27059] find_spec and find_loader ignore package/path argument

2016-05-24 Thread Brett Cannon
Brett Cannon added the comment: https://docs.python.org/3.6/library/importlib.html#examples has an Examples section that's new to the Python 3.6 docs which covers your use-case. -- ___ Python tracker _

[issue27059] find_spec and find_loader ignore package/path argument

2016-05-20 Thread Gerrit Ansmann
Gerrit Ansmann added the comment: > If you think the docs aren't clear enough then please feel free to submit a > patch to make them a bit clearer. I intend to do that. However, before I do so: Given that `find_loader` shall be superseded by `find_spec`, how would I use the latter to find the

[issue27059] find_spec and find_loader ignore package/path argument

2016-05-19 Thread Brett Cannon
Brett Cannon added the comment: So there are 2 problems with your example. One, importlib.util.find_spec() doesn't take a path argument but a package argument which is a package name and not a file system location (https://docs.python.org/3/library/importlib.html#importlib.util.find_spec). Tw

[issue27059] find_spec and find_loader ignore package/path argument

2016-05-19 Thread Gerrit Ansmann
New submission from Gerrit Ansmann: According to my understanding, the `package`/`path` argument of the `find_loader`/`find_spec` command should enable it to find modules in other directories than the current one. Instead, these arguments seem to be ignored and even changing the working direct