Brett Cannon added the comment:

This is going to have to wait until Python 3.5, so I'm going to back out the 
exec_module() aspects of BuiltinImporter and ExtensionFileLoader. As Nick has 
pointed out previously, we are going to need to change the init function 
signature of extension modules to accept the module to initialize (or 
something). This also extends to built-in modules as on Windows all extension 
modules are compiled in, so there is no real distinction between the two 
scenarios, so this can't be only partially solved for built-ins but not 
extension modules.

This is another reason why we will need to go with a soft deprecation of 
load_module() in Python 3.4 and hopefully get all of this straightened out in 
Python 3.5 so we can introduce a hard deprecation.

And just in case we end up having to hack our way around the call signature, 
PyModule_Create() could be tweaked to pull modules from a cache that can be 
seeded with the module that is to be used for the initialization. That way call 
signatures don't have to change but what module gets used can be controlled.

----------
priority: normal -> critical
versions: +Python 3.5 -Python 3.4

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue19698>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to