Skip to content

Commit f3f6cfe

Browse files
committed
backport 2.144:
Py_Initialize(): Apply patch by Jürgen Hermann to call _PyImport_FixupExtension() on the exceptions module. Now reload(exceptions) acts just like reload(sys) instead of raising an ImportError. This closes SF bug #422004.
1 parent f7adf24 commit f3f6cfe

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

‎Python/pythonrun.c‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ Py_Initialize(void)
144144

145145
/* initialize builtin exceptions */
146146
init_exceptions();
147+
_PyImport_FixupExtension("exceptions", "exceptions");
147148

148149
/* phase 2 of builtins */
149150
_PyImport_FixupExtension("__builtin__", "__builtin__");

0 commit comments

Comments
 (0)