cpython/Lib/test/test_importlib
Nick Coghlan 93602e3af7 [3.5] bpo-29537: Tolerate legacy invalid bytecode (#169)
bpo-27286 fixed a problem where BUILD_MAP_UNPACK_WITH_CALL could
be emitted with an incorrect oparg value, causing the eval loop
to access the wrong stack entry when attempting to read the
function name.

The associated magic number change caused significant problems when
attempting to upgrade to 3.5.3 for anyone that relies on pre-cached
bytecode remaining valid across maintenance releases.

This patch restores the ability to import legacy bytecode generated
by 3.5.0, 3.5.1 or 3.5.2, and modifies the eval loop to
avoid any harmful consequences from the potentially malformed legacy
bytecode.

Original import patch by Petr Viktorin, eval loop patch by Serhiy Storchaka,
and tests and integration by Nick Coghlan.
2017-03-08 16:41:01 +10:00
..
builtin Issue #15836: assertRaises(), assertRaisesRegex(), assertWarns() and 2015-05-21 20:15:40 +03:00
extension Issue #27782: Fix m_methods handling in multiphase init 2016-08-21 17:41:56 +10:00
frozen Closes #22002: Merge with 3.4 2014-07-23 12:06:47 -05:00
import_ [backport to 3.5] - issue26896 - Disambiguate uses of "importer" with "finder". 2016-09-07 00:52:20 -07:00
namespace_pkgs Issue #21097: Move test_namespace_pkgs into test_importlib. 2014-03-29 15:57:44 -06:00
source [3.5] bpo-29537: Tolerate legacy invalid bytecode (#169) 2017-03-08 16:41:01 +10:00
__init__.py Issue #22002: Make full use of test discovery in test sub-packages. 2014-07-23 12:00:29 -05:00
__main__.py Issue #22002: Make full use of test discovery in test sub-packages. 2014-07-23 12:00:29 -05:00
abc.py Implement PEP 451 (ModuleSpec). 2013-11-22 09:05:39 -07:00
regrtest.py
test_abc.py Issue #19593: Use specific asserts in importlib tests. 2014-07-07 14:09:43 +03:00
test_api.py Issue #21503: Use test_both() consistently in test_importlib. 2014-05-16 11:40:40 -06:00
test_lazy.py Fix a scoping issue where an UnboundLocalError was triggered if a 2016-06-25 10:47:53 -07:00
test_locks.py Issue #21755: Skip {Frozen,Source}_DeadlockAvoidanceTests tests when 2014-07-03 06:25:10 +03:00
test_namespace_pkgs.py Issue #21097: Move test_namespace_pkgs into test_importlib. 2014-03-29 15:57:44 -06:00
test_spec.py Issue #23014: Make importlib.abc.Loader.create_module() required when 2015-01-09 11:39:21 -05:00
test_util.py Issue #27895: Spelling fixes (Contributed by Ville Skyttä). 2016-09-07 12:03:06 +00:00
test_windows.py #22980 Adds platform and version tags to .pyd files 2014-12-15 20:45:23 -08:00
util.py [backport to 3.5] - issue26896 - Disambiguate uses of "importer" with "finder". 2016-09-07 00:52:20 -07:00