Tests
-----
+ - Issue #15539: Added regression tests for Tools/scripts/pindent.py.
+
+- Issue #16836: Enable IPv6 support even if IPv6 is disabled on the build host.
+
- Issue #16925: test_configparser now works with unittest test discovery.
Patch by Zachary Ware.
Tools/Demos
-----------
+ - Issue #15539: Fix a number of bugs in Tools/scripts/pindent.py. Now
+ pindent.py works with a "with" statement. pindent.py no longer produces
+ improper indentation. pindent.py now works with continued lines broken after
+ "class" or "def" keywords and with continuations at the start of line.
+
+- Issue #11797: Add a 2to3 fixer that maps reload() to imp.reload().
+
+- Issue #10966: Remove the concept of unexpected skipped tests.
+
+- Issue #9893: Removed the Misc/Vim directory.
+
+- Removed the Misc/TextMate directory.
+
+- Issue #16245: Add the Tools/scripts/parse_html5_entities.py script to parse
+ the list of HTML5 entities and update the html.entities.html5 dictionary.
+
- Issue #15378: Fix Tools/unicode/comparecodecs.py. Patch by Serhiy Storchaka.
+- Issue #13301: use ast.literal_eval() instead of eval() in Tools/i18n/msgfmt.py
+ Patch by Serhiy Storchaka.
+
What's New in Python 3.3.0?
===========================
# end if
import os
try: os.rename(filename, filename + '~')
- except os.error: pass
+ except OSError: pass
# end try
- f = open(filename, 'w')
- f.write(result)
- f.close()
+ with open(filename, 'w') as f:
+ f.write(result)
+ # end with
return 1
# end def complete_file
# end if
import os
try: os.rename(filename, filename + '~')
- except os.error: pass
+ except OSError: pass
# end try
- f = open(filename, 'w')
- f.write(result)
- f.close()
+ with open(filename, 'w') as f:
+ f.write(result)
+ # end with
return 1
# end def delete_file
# end if
import os
try: os.rename(filename, filename + '~')
- except os.error: pass
+ except OSError: pass
# end try
- f = open(filename, 'w')
- f.write(result)
- f.close()
+ with open(filename, 'w') as f:
+ f.write(result)
+ # end with
return 1
# end def reformat_file