[issue12703] Improve error reporting for packaging.util.resolve_name

Rémy HUBSCHER report at bugs.python.org
Sun Aug 21 11:29:00 CEST 2011


Rémy HUBSCHER <remy.hubscher at ionyse.com> added the comment:

It is exactly what explained Alexis.

The __import__ can failed in two case :

 - The module doesn't exist
 - There is a error in the module

With the previous behaviour, even if the module exist, the message was that it doesn't exists. And it was then not fast forward to guess where was the error.

With this new behaviour, if there is an __import__ error and the module file actually exists, then we raise the real exception problem from the module that we try to import.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue12703>
_______________________________________


More information about the Python-bugs-list mailing list