[Python-Dev] Peculiar import code in pickle.py (original) (raw)
Alexander Belopolsky alexander.belopolsky at gmail.com
Tue Jul 13 23:20:42 CEST 2010
- Previous message: [Python-Dev] Peculiar import code in pickle.py
- Next message: [Python-Dev] Peculiar import code in pickle.py
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Tue, Jul 13, 2010 at 4:52 PM, Brett Cannon <brett at python.org> wrote: ..
Pulling from sys.modules is the correct way to do this. There are subtle issues when using a bunk fromlist argument (empty modules, double initialization, etc.). If one does not use importlib.importmodule -- written specifically to prevent people from doing the nasty hack with the fromlist -- then you should use the sys.modules approach, period. If import.c is not doing this then it should get fixed. You can assign me the issue if you want.
Please see http://bugs.python.org/issue9252 .
- Previous message: [Python-Dev] Peculiar import code in pickle.py
- Next message: [Python-Dev] Peculiar import code in pickle.py
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]