Running Python 2 test suite with "python -3 -Wd" displays a lot of DeprecationWarning warnings. Just one example: /home/haypo/prog/python/2.7/Lib/test/test_ssl.py:2368: DeprecationWarning: urllib.urlopen() has been removed in Python 3.0 in favor of urllib2.urlopen() Attached patch fix most of them (maybe all).
Please just change '1/0' to '1//0'. Any expression that raises something other than NameError or AttributeError will do. .get_entity evals user code and Idle previously crashed when other exceptions were not caught. Thanks, Serhiy, for catching this. The other warned code appears to be essential to the corresponding test. I presume Serhiy checked this also.
Ok, I replaced 1/0 with 1//0 in IDLE tests. I also changed the context manager in test_collections, the sets module is just deprecated, it's not a Python 3 specific warning. Thanks for the review Serhiy.