Staging
v0.5.1
https://github.com/python/cpython
Revision 12c6bda4f0e96c4bea285d8c664044753ea81bf1 authored by Brett Cannon on 24 August 2012, 22:25:59 UTC, committed by Brett Cannon on 24 August 2012, 22:25:59 UTC
fromlist of __import__ propagate.

The problem previously was that if something listed in fromlist didn't
exist then that's okay. The fix for that was too broad in terms of
catching ImportError.

The trick with the solution to this issue is that the proper
refactoring of import thanks to importlib doesn't allow for a way to
distinguish (portably) between an ImportError because finders couldn't
find a loader, or a loader raised the exception. In Python 3.4 the
hope is to introduce a new exception (e.g. ModuleNotFound) to make it
clean to differentiate why ImportError was raised.
1 parent 7a54d16
Raw File
Tip revision: 12c6bda4f0e96c4bea285d8c664044753ea81bf1 authored by Brett Cannon on 24 August 2012, 22:25:59 UTC
Issue #15316: Let exceptions raised during imports triggered by the
Tip revision: 12c6bda
.bzrignore
ยด.purify
autom4te.cache
config.log
config.cache
config.status
config.status.lineno
db_home
Makefile
buildno
python
build
Makefile.pre
platform
pybuilddir.txt
pyconfig.h
libpython*.a
libpython*.so*
python.exe
python-gdb.py
reflog.txt
tags
TAGS
.gdb_history
Doc/tools/sphinx
Doc/tools/jinja
Doc/tools/jinja2
Doc/tools/pygments
Doc/tools/docutils
Misc/python.pc
Modules/Setup
Modules/Setup.config
Modules/Setup.local
Modules/config.c
Modules/ld_so_aix
Parser/pgen
Lib/test/data/*
Lib/lib2to3/Grammar*.pickle
Lib/lib2to3/PatternGrammar*.pickle
__pycache__
.coverage
coverage/*
htmlcov/*
back to top