1. 文章
  2. 文章详情

Python 3.8.0稳定版发布

部分新特性

PEP 572,赋值表达式(Assignment expressions)
PEP 570,仅位置的参数
PEP 587,Python初始化配置(改进嵌入)
PEP 590,Vectorcall:用于CPython的快速调用协议
PEP 578,运行时审核挂钩
PEP 574,带外数据的Pickle协议5
并行文件系统缓存,用于编译的字节码
调试版本与发行版本共享ABI
typed_ast合并回CPython
LOAD_GLOBAL现在快40%
pickle现在默认使用协议4,提高了性能

Python 3.8.0 final

Release date: 2019-10-14

核心与内置

  • bpo-38469: Fixed a bug where the scope of named expressions was not being resolved correctly in the presence of the global keyword. Patch by Pablo Galindo.

  • bpo-38379: When cyclic garbage collection (gc) runs finalizers that resurrect unreachable objects, the current gc run ends, without collecting any cyclic trash. However, the statistics reported by collect() and get_stats() claimed that all cyclic trash found was collected, and that the resurrected objects were collected. Changed the stats to report that none were collected.

文档

  • bpo-38294: Add list of no-longer-escaped chars to re.escape documentation

测试

  • bpo-37531: On timeout, regrtest no longer attempts to call popen.communicate() again: it can hang until all child processes using stdout and stderr pipes completes. Kill the worker process and ignores its output. Change also the faulthandler timeout of the main process from 1 minute to 5 minutes, for Python slowest buildbots.

Windows

  • bpo-38344: Fix error message in activate.bat

  • bpo-38359: Ensures pyw.exe launcher reads correct registry key.

  • bpo-38355: Fixes ntpath.realpath failing on sys.executable.

IDLE

  • bpo-36698: IDLE no longer fails when write non-encodable characters to stderr. It now escapes them with a backslash, as the regular Python interpreter. Added the errors field to the standard streams.

工具/示例

  • bpo-38118: Update Valgrind suppression file to ignore a false alarm in PyUnicode_Decode() when using GCC builtin strcmp().

  • bpo-38347: pathfix.py: Assume all files that end on '.py' are Python scripts when working recursively.

C API

  • bpo-38395: Fix a crash in weakref.proxy objects due to incorrect lifetime management when calling some associated methods that may delete the last reference to object being referenced by the proxy. Patch by Pablo Galindo.


发表评论

登录后才能评论

评论列表(0条)