Issue 17867: Deleting import from builtins can crash Python3 (original) (raw)
Simple case - let's delete import and try to import anything
$ python3.3 Python 3.3.0 (default, Oct 7 2012, 11:03:52) [GCC 4.4.3] on linux Type "help", "copyright", "credits" or "license" for more information.
del builtins.dict['import'] import os Traceback (most recent call last): File "", line 1, in Fatal Python error: import missing
Current thread 0x00007f07c9ebc700: Aborted
But in python2.x
$ python2.7 Python 2.7.3 (default, Sep 22 2012, 02:37:18) [GCC 4.4.3] on linux2 Type "help", "copyright", "credits" or "license" for more information.
del builtins.dict['import'] import os Traceback (most recent call last): File "", line 1, in ImportError: import not found