The Python 3.9.0 stable version (Python 3.9.0 final) was officially released yesterday. It contains many new features and optimizations. It is forbidden to install on Windows 7, and 64-bit installation is provided by default. program.

IT Home learned that the first iteration of Python 3.9.0 alpha 1 was launched in November 2019, and it has been nearly a year since.

Compared with Python 3.8, the main new features and changes of the Python 3.9 series mainly include:

  1. PEP 573, Module Status Access of C Extension Method

  2. PEP 584, dict of joint operators

  3. PEP 585, Type Prompt Generics in the Standard Collection

  4. PEP 593, Flexible function function and variable annotation

  5. PEP 602, Python adopts a stable annual release method

  6. PEP 614, relaxation of grammatical restrictions on decorators

  7. PEP 615, supports the IANA time zone database in the standard library

  8. PEP 616, removing string methods for prefix and suffix

  9. PEP 617, a new PEG parser for CPython

  10. BPO 38379, the garbage collector will not prevent the resurrected object;

  11. BPO 38692, added os.pidfd_open, which allows process management without races and signals;

  12. BPO 39926, Unicode support has been updated to version 13.0.0;

  13. BPO 1635741, when Python is initialized multiple times in the same process, it no longer leaks memory;

  14. Now use PEP 590 vectorcall to speed up many Python built-in functions (range, tuple, set, frozenset, list, dictionary);

  15. Now, many Python modules (_abc, audioop, _bz2, _codecs, _contextvars, _crypt, _functools, _json, _locale, operator, resource, time, _weakref) use multi-stage initialization defined by PEP 489;

  16. Many standard library modules (audioop, ast, grp, _hashlib, pwd, _posixsubprocess, random, select, struct, termios, zlib) now use the stable ABI defined by PEP 384.

In addition, after the official version is released, it will receive full support within one year, and there will be security updates within 5 years. The release time of the updated version of Python 4.0 has not yet been announcement.