Python 3.6.4 已发布,Python 3.6.4 是 2016 年发布的 Python 3.6 的第四个维护版本。
与 Python 3.6.4 的首个 RC 版相比,3.6.4 并没有任何新的代码更改,下面简单看看 Python 3.6.4 RC1 的更新内容。
更新内容较多,包含了 C API、工具示例、IDLE、macOS、Windows、构建、测试、文档、库、核心这几大方面,详细的内容可点此进行参阅。
核心
Fixed several issues in printing tracebacks (PyTraceBack_Print())
Fix the interactive interpreter looping endlessly when no memory.
Bytearray methods partition() and rpartition() now accept only bytes-like objects as separator, as documented. In particular they now raise TypeError rather of returning a bogus result when an integer is passed as a separator.
Fix a segmentation fault caused by a combination of the async soft keyword and continuation lines.
BytesWarning no longer emitted when the fromlist argument of __import__() or the __all__ attribute of the module contain bytes instances.
Print the full context/cause chain of exceptions on interpreter exit, even if an exception in the chain is unhashable or compares equal to later ones. Patch by Zane Bitter.
库
Two minor fixes for typing module: allow shallow copying instances of generic classes, improve interaction of __init_subclass__with generics. Original PRs by Ivan Levkivskyi.
The header folding algorithm for the new email policies has been rewritten, which also fixes bpo-30788, bpo-31831, and bpo-32182. In particular, RFC2231 folding is now done correctly.
io.FileIO.readall() and io.FileIO.read() now release the GIL when getting the file size. Fixed hang of all threads with inaccessible NFS server. Patch by Nir Soffer.
测试
Skip test_httpservers test_undecodable_file on macOS: fails on APFS.
Skip test_socket.test_sha256() on Linux kernel older than 4.5. The test fails with ENOKEY on kernel 3.10 (on ppc64le). A fix was merged into the kernel 4.5.
Fix test_tools.test_unparse: DirectoryTestCase now stores the names sample to always test the same files. It prevents false alarms when hunting reference leaks.
Add the set_nomemory(start, stop) and remove_mem_hooks() functions to the _testcapi module.
预计下个维护版本将在未来三个月内发布,大约是 2018 年 3 月底。
下载地址:https://www.python.org/downloads/release/python-364/
来自:开源中国社区

