summaryrefslogtreecommitdiffstats
path: root/Misc/NEWS.d
Commit message (Collapse)AuthorAgeFilesLines
* Fix thread locks in zlib module may go wrong in rare case. (#22126)Ma Lin2021-04-271-0/+1
| | | Setting `next_in` before acquiring the thread lock may mix up compress/decompress state in other threads.
* bpo-43945: [Enum] Deprecate non-standard mixin format() behavior (GH-25649)Ethan Furman2021-04-271-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | In 3.12 the enum member, not the member's value, will be used for format() calls. Format specifiers can be used to retain the current display of enum members: Example enumeration: class Color(IntEnum): RED = 1 GREEN = 2 BLUE = 3 Current behavior: f'{Color.RED}' --> '1' Future behavior: f'{Color.RED}' --> 'RED' Using d specifier: f'{Color.RED:d}' --> '1' Using specifiers can be done now and is future-compatible.
* bpo-43762: Add audit events for loading of sqlite3 extensions (GH-25246)Erlend Egeberg Aasland2021-04-261-0/+3
|
* bpo-40432: Use python 3.8 or higher to compile CPython on Windows (#25389)Ken Jin2021-04-261-0/+3
|
* bpo-43938: improve dataclasses.FrozenInstanceError documentation (GH-25603)Llandy Riveron Del Risco2021-04-261-0/+2
|
* bpo-42904: Change search order of typing.get_type_hints eval (#25632)Ken Jin2021-04-261-0/+5
| | | While surprising (searching globals before locals in one specific case), this is needed for backwards compatibility.
* bpo-18233: Add internal methods to access peer chain (GH-25467)Christian Heimes2021-04-261-0/+2
| | | | | | | | | | | | The internal `_ssl._SSLSocket` object now provides methods to retrieve the peer cert chain and verified cert chain as a list of Certificate objects. Certificate objects have methods to convert the cert to a dict, PEM, or DER (ASN.1). These are private APIs for now. There is a slim chance to stabilize the approach and provide a public API for 3.10. Otherwise I'll provide a stable API in 3.11. Signed-off-by: Christian Heimes <christian@python.org>
* Add keyword-only fields to dataclasses. (GH=25608)Eric V. Smith2021-04-261-0/+2
|
* bpo-43534: Fix the turtle module working with multiple root windows (GH-25591)Serhiy Storchaka2021-04-251-0/+1
|
* bpo-38490: statistics: Add covariance, Pearson's correlation, and simple ↵Tymoteusz Wołodźko2021-04-251-0/+1
| | | | | linear regression (#16813) Co-authored-by: Tymoteusz Wołodźko <twolodzko+gitkraken@gmail.com
* bpo-39529: Deprecate creating new event loop in asyncio.get_event_loop() ↵Serhiy Storchaka2021-04-251-0/+9
| | | | | | (GH-23554) asyncio.get_event_loop() emits now a deprecation warning when it creates a new event loop. In future releases it will became an alias of asyncio.get_running_loop().
* bpo-42609: Check recursion depth in the AST validator and optimizer (GH-23744)Serhiy Storchaka2021-04-251-0/+3
|
* bpo-43534: Make dialogs in turtle.textinput() and turtle.numinput() ↵Serhiy Storchaka2021-04-251-0/+2
| | | | transitient again (GH-24923)
* bpo-43655: Tkinter and IDLE dialog windows are now recognized as dialogs by ↵Serhiy Storchaka2021-04-252-0/+4
| | | | window managers on macOS and X Window (#25187)
* bpo-42737: annotations with complex targets no longer causes any runtime ↵Batuhan Taskaya2021-04-251-0/+2
| | | | effects (GH-23952)
* bpo-43930: Update bundled pip to 21.1 and setuptools to 56.0.0 (GH-25576)Stéphane Bidoul2021-04-241-0/+1
| | | Update bundled pip to 21.1 and setuptools to 56.0.0
* bpo-43780: Sync with importlib_metadata 3.10 (GH-25297)Jason R. Coombs2021-04-241-0/+3
| | | | | | | * bpo-43780: Sync with importlib_metadata 3.10. * Add blurb * Apply changes from importlib_metadata 3.10.1.
* bpo-31870: Add a timeout parameter to ssl.get_server_certificate() (GH-22270)Zackery Spytz2021-04-241-0/+2
|
* bpo-30555: Fix WindowsConsoleIO fails in the presence of fd redirection ↵Segev Finer2021-04-231-0/+2
| | | | | | | | (GH-1927) This works by not caching the handle and instead getting the handle from the file descriptor each time, so that if the actual handle changes by fd redirection closing/opening the console handle beneath our feet, we will keep working correctly.
* bop-43652: Update Tcl and Tk to 8.6.11 in Windows installer (GH-25170)Terry Jan Reedy2021-04-231-0/+1
|
* bpo-43907: add missing memoize call in pure python pickling of bytearray ↵Carl Friedrich Bolz-Tereick2021-04-231-0/+4
| | | | (GH-25501)
* bpo-39950: add `pathlib.Path.hardlink_to()` method that supersedes ↵Barney Gale2021-04-231-0/+2
| | | | | | | | | | | `link_to()` (GH-18909) The argument order of `link_to()` is reversed compared to what one may expect, so: a.link_to(b) Might be expected to create *a* as a link to *b*, in fact it creates *b* as a link to *a*, making it function more like a "link from". This doesn't match `symlink_to()` nor the documentation and doesn't seem to be the original author's intent. This PR deprecates `link_to()` and introduces `hardlink_to()`, which has the same argument order as `symlink_to()`.
* bpo-43538: Add extra arguments to os.startfile (GH-25538)Steve Dower2021-04-232-0/+1
|
* bpo-43607: Fix urllib handling of Windows paths with \\?\ prefix (GH-25539)Steve Dower2021-04-231-0/+2
|
* bpo-35114: Make ssl.RAND_status() return a bool (GH-20063)Zackery Spytz2021-04-231-0/+2
|
* bpo-43914: Highlight invalid ranges in SyntaxErrors (#25525)Pablo Galindo2021-04-231-0/+3
| | | | | | | | | | | | | | | | | To improve the user experience understanding what part of the error messages associated with SyntaxErrors is wrong, we can highlight the whole error range and not only place the caret at the first character. In this way: >>> foo(x, z for z in range(10), t, w) File "<stdin>", line 1 foo(x, z for z in range(10), t, w) ^ SyntaxError: Generator expression must be parenthesized becomes >>> foo(x, z for z in range(10), t, w) File "<stdin>", line 1 foo(x, z for z in range(10), t, w) ^^^^^^^^^^^^^^^^^^^^ SyntaxError: Generator expression must be parenthesized
* bpo-43868: Remove PyOS_ReadlineFunctionPointer from the stable ABI list ↵Petr Viktorin2021-04-231-0/+3
| | | | | | | | | | | (GH-25442) The inclusion of PyOS_ReadlineFunctionPointer in python3dll.c was a mistake. According to PEP 384: > functions expecting FILE* are not part of the ABI, to avoid depending > on a specific version of the Microsoft C runtime DLL on Windows. https://bugs.python.org/issue43868
* bpo-43795: PEP-652: Clean up the stable ABI/limited API (GH-25482)Petr Viktorin2021-04-231-0/+2
| | | | | | | | | | | | | | | | | | - `_Py_EncodeLocaleRaw`, which is private by name, undocumented, and wasn't exported in `python3.dll`, is moved to a private header. - `_Py_HashSecret_Initialized`, again private by name, undocumented, and not exported in `python3.dll`, is excluded with `Py_LIMITED_API`. - `PyMarshal_*` and `PyMember_*One` functions, declared in private headers and not exported in `python3.dll`, are removed from `Doc/data/stable_abi.dat`. - `PyMem_Calloc` which *was* exported in `python3dll.c`, is moved to public headers where it joins its other `PyMem_*` friends. Only the last change is documented in the blurb; others are not user-visible. (Nothing uses `Doc/data/stable_abi.dat` yet.) https://bugs.python.org/issue43795
* bpo-41282: (PEP 632) Deprecate distutils.sysconfig (partial implementation ↵Lumír 'Frenzy' Balhar2021-04-231-0/+1
| | | | | | | | | | of the PEP) (GH-23142) This change: * merges `distutils.sysconfig` into `sysconfig` while keeping the original functionality and * marks `distutils.sysconfig` as deprecated https://bugs.python.org/issue41282
* bpo-43920: Make load_verify_locations(cadata) error message consistent ↵Christian Heimes2021-04-231-0/+2
| | | | | (GH-25554) Signed-off-by: Christian Heimes <christian@python.org>
* bpo-37363: Add audit events to the `http.client` module (GH-21321)Saiyang Gou2021-04-231-0/+1
| | | | | Add audit events to the `http.client` module Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
* bpo-39572: Address typo in CHANGELOG. (GH-24999)Simon Charette2021-04-231-1/+1
|
* bpo-35306: Avoid raising OSError from pathlib.Path.exists when passed an ↵Steve Dower2021-04-221-0/+2
| | | | invalid filename (GH-25529)
* bpo-38822: Fixed os.stat failing on inaccessible directories. (GH-25527)Steve Dower2021-04-221-0/+3
| | | It would just fail if the path was inaccessible and had a trailing slash. It should fall back to the parent directory's metadata.
* bpo-43284: Update platform.win32_ver to use _syscmd_ver instead of ↵Shreyan Avigyan2021-04-221-0/+6
| | | | | | | sys.getwindowsversion() (GH-25500) The sys module uses the kernel32.dll version number, which can vary from the "actual" Windows version. Since the best option for getting the version is WMI (which is expensive), we switch back to launching cmd.exe (which is also expensive, but a lot less code on our part). sys.getwindowsversion() is not updated to avoid launching executables from that module.
* bpo-43475: Fix worst case collision behavior for NaN instances (GH-25493)Raymond Hettinger2021-04-221-0/+3
|
* bpo-26227: Fixes decoding of host names on Windows from ANSI instead of ↵Steve Dower2021-04-211-0/+2
| | | | UTF-8 (GH-25510)
* bpo-43756: Add new audit event for new arguments added to glob.glob (GH-25239)Saiyang Gou2021-04-211-0/+2
|
* bpo-43472: Ensure PyInterpreterState_New audit events are raised when called ↵Steve Dower2021-04-211-0/+3
| | | | through _xxsubinterpreters module (GH-25506)
* bpo-38659: [Enum] add _simple_enum decorator (GH-25497)Ethan Furman2021-04-211-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | add: * `_simple_enum` decorator to transform a normal class into an enum * `_test_simple_enum` function to compare * `_old_convert_` to enable checking `_convert_` generated enums `_simple_enum` takes a normal class and converts it into an enum: @simple_enum(Enum) class Color: RED = 1 GREEN = 2 BLUE = 3 `_old_convert_` works much like` _convert_` does, using the original logic: # in a test file import socket, enum CheckedAddressFamily = enum._old_convert_( enum.IntEnum, 'AddressFamily', 'socket', lambda C: C.isupper() and C.startswith('AF_'), source=_socket, ) `_test_simple_enum` takes a traditional enum and a simple enum and compares the two: # in the REPL or the same module as Color class CheckedColor(Enum): RED = 1 GREEN = 2 BLUE = 3 _test_simple_enum(CheckedColor, Color) _test_simple_enum(CheckedAddressFamily, socket.AddressFamily) Any important differences will raise a TypeError
* bpo-43859: Improve the error message for IndentationError exceptions (GH-25431)Pablo Galindo2021-04-211-0/+2
|
* bpo-38605: Revert making 'from __future__ import annotations' the default ↵Pablo Galindo2021-04-211-0/+5
| | | | | | (GH-25490) This reverts commits 044a1048ca93d466965afc027b91a5a9eb9ce23c and 1be456ae9d53bb1cba2b24fc86175c282d1c2169, adapting the code to changes that happened after it.
* Revert "bpo-38659: [Enum] add _simple_enum decorator (GH-25285)" (GH-25476)Ethan Furman2021-04-201-4/+0
| | | This reverts commit dbac8f40e81eb0a29dc833e6409a1abf47467da6.
* bpo-38659: [Enum] add _simple_enum decorator (GH-25285)Ethan Furman2021-04-201-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | add: _simple_enum decorator to transform a normal class into an enum _test_simple_enum function to compare _old_convert_ to enable checking _convert_ generated enums _simple_enum takes a normal class and converts it into an enum: @simple_enum(Enum) class Color: RED = 1 GREEN = 2 BLUE = 3 _old_convert_ works much like _convert_ does, using the original logic: # in a test file import socket, enum CheckedAddressFamily = enum._old_convert_( enum.IntEnum, 'AddressFamily', 'socket', lambda C: C.isupper() and C.startswith('AF_'), source=_socket, ) test_simple_enum takes a traditional enum and a simple enum and compares the two: # in the REPL or the same module as Color class CheckedColor(Enum): RED = 1 GREEN = 2 BLUE = 3 _test_simple_enum(CheckedColor, Color) _test_simple_enum(CheckedAddressFamily, socket.AddressFamily) Any important differences will raise a TypeError
* bpo-40849: Expose X509_V_FLAG_PARTIAL_CHAIN ssl flag (GH-20463)l0x2021-04-191-0/+1
| | | This short PR exposes an openssl flag that wasn't exposed. I've also updated to doc to reflect the change. It's heavily inspired by 990fcaac3c428569697f62a80fd95ab4d4b93151.
* bpo-43880: Show DeprecationWarnings for deprecated ssl module features ↵Christian Heimes2021-04-191-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | (GH-25455) * ssl.OP_NO_SSLv2 * ssl.OP_NO_SSLv3 * ssl.OP_NO_TLSv1 * ssl.OP_NO_TLSv1_1 * ssl.OP_NO_TLSv1_2 * ssl.OP_NO_TLSv1_3 * ssl.PROTOCOL_SSLv2 * ssl.PROTOCOL_SSLv3 * ssl.PROTOCOL_SSLv23 (alias for PROTOCOL_TLS) * ssl.PROTOCOL_TLS * ssl.PROTOCOL_TLSv1 * ssl.PROTOCOL_TLSv1_1 * ssl.PROTOCOL_TLSv1_2 * ssl.TLSVersion.SSLv3 * ssl.TLSVersion.TLSv1 * ssl.TLSVersion.TLSv1_1 * ssl.wrap_socket() * ssl.RAND_pseudo_bytes() * ssl.RAND_egd() (already removed since it's not supported by OpenSSL 1.1.1) * ssl.SSLContext() without a protocol argument * ssl.match_hostname() * hashlib.pbkdf2_hmac() (pure Python implementation, fast OpenSSL function will stay) Signed-off-by: Christian Heimes <christian@python.org>
* bpo-42854: Use SSL_read/write_ex() (GH-25468)Christian Heimes2021-04-191-0/+4
| | | | | | | | The ssl module now uses ``SSL_read_ex`` and ``SSL_write_ex`` internally. The functions support reading and writing of data larger than 2 GB. Writing zero-length data no longer fails with a protocol violation error. Signed-off-by: Christian Heimes <christian@python.org>
* bpo-36076: Add SNI support to ssl.get_server_certificate. (GH-16820)juhovh2021-04-181-0/+1
| | | | | | | | | | | | | | Many servers in the cloud environment require SNI to be used during the SSL/TLS handshake, therefore it is not possible to fetch their certificates using the ssl.get_server_certificate interface. This change adds an additional optional hostname argument that can be used to set the SNI. Note that it is intentionally a separate argument instead of using the host part of the addr tuple, because one might want to explicitly fetch the default certificate or fetch a certificate from a specific IP address with the specified SNI hostname. A separate argument also works better for backwards compatibility. Automerge-Triggered-By: GH:tiran
* bpo-43362: Fix invalid free and return check in _sha3 module (GH-25463)Christian Heimes2021-04-181-0/+2
| | | | | | | | | | | Commit 93d50a6a8d0c5d332c11aef267e66573a09765ac / GH-21855 changed the order of variable definitions, which introduced a potential invalid free bug. Py_buffer object is now initialized earlier and the result of Keccak initialize is verified. Co-authored-by: Alex Henrie <alexhenrie24@gmail.com> Signed-off-by: Christian Heimes <christian@python.org> Co-authored-by: Alex Henrie <alexhenrie24@gmail.com>
* bpo-42333: Port _ssl extension to multiphase initialization (PEP 489) (GH-23253)Christian Heimes2021-04-171-0/+1
| | | | | | | | | - Introduce sslmodule_slots - Introduce sslmodulestate - Use sslmodulestate - Get rid of PyState_FindModule - Move new structs and helpers to header file - Use macros to access state - Keep a strong ref to socket type