New submission from Amaury Forgeot d'Arc <[EMAIL PROTECTED]>: The example Demo/embed/importexc.c crashes, because Py_NewInterpreter cannot reimport builtins and sys modules. This problem seems important for embedding applications like mod_python, for example.
(the "import exceptions" statement does not work with python 3.0, but replacing with e.g. "import types" does not change anything: the interpreter is not correctly renewed) I tried to put "-1" in the m_size structure of these modules, and they seem to import correctly. However, "builtins" comes with its original dictionary - without the standard exceptions. I think that these modules should be made re-importable, with specific functions. Maybe two related problems: - once you've done del sys.modules['sys'] it's not possible to get it back, "import sys" raises an error... - the usual trick to call sys.setdefaultencoding will not work, since it needs to "imp.reload(sys)" ---------- components: Extension Modules messages: 72127 nosy: amaury.forgeotdarc, loewis priority: release blocker severity: normal status: open title: Py_NewInterpreter does not work versions: Python 3.0 _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue3723> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com