[issue10926] Some Invalid Relative Imports succeed in Py 3.0 & 3.1 [& correctly fail in 3.2rc1]
report at bugs.python.org
Mon Jan 17 16:16:45 CET 2011
Nick Coghlan <ncoghlan at gmail.com> added the comment:
Yeah, 7902 was a bug that tried to do an absolute import if an explicit relative import failed to find anything (i.e. it had inherited the old implicit relative import fallback, which was entirely inappropriate for the new use case).
Since the significant import in these examples should correctly be written as "from .. import Xpm", it should fail in 2.6.6 and 3.1.3 as well.
If you could confirm that at least 3.1.3 also gives the expected error message, we'll close this as a dupe of 7902.
Python tracker <report at bugs.python.org>
More information about the Python-bugs-list