mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Python 3.11.0b4
This commit is contained in:
parent
a276833a7d
commit
5a7e1e0a92
111 changed files with 1128 additions and 245 deletions
|
@ -20,10 +20,10 @@
|
|||
#define PY_MINOR_VERSION 11
|
||||
#define PY_MICRO_VERSION 0
|
||||
#define PY_RELEASE_LEVEL PY_RELEASE_LEVEL_BETA
|
||||
#define PY_RELEASE_SERIAL 3
|
||||
#define PY_RELEASE_SERIAL 4
|
||||
|
||||
/* Version as a string */
|
||||
#define PY_VERSION "3.11.0b3+"
|
||||
#define PY_VERSION "3.11.0b4"
|
||||
/*--end constants--*/
|
||||
|
||||
/* Version as a single 4-byte hex number, e.g. 0x010502B2 == 1.5.2b2.
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Autogenerated by Sphinx on Wed Jun 1 14:07:03 2022
|
||||
# Autogenerated by Sphinx on Mon Jul 11 16:25:08 2022
|
||||
topics = {'assert': 'The "assert" statement\n'
|
||||
'**********************\n'
|
||||
'\n'
|
||||
|
@ -4144,7 +4144,7 @@ topics = {'assert': 'The "assert" statement\n'
|
|||
' invoking the superclass’s "__new__()" method using\n'
|
||||
' "super().__new__(cls[, ...])" with appropriate arguments '
|
||||
'and then\n'
|
||||
' modifying the newly-created instance as necessary before '
|
||||
' modifying the newly created instance as necessary before '
|
||||
'returning\n'
|
||||
' it.\n'
|
||||
'\n'
|
||||
|
@ -4547,7 +4547,7 @@ topics = {'assert': 'The "assert" statement\n'
|
|||
'Python.This is\n'
|
||||
' intended to provide protection against a '
|
||||
'denial-of-service caused\n'
|
||||
' by carefully-chosen inputs that exploit the worst '
|
||||
' by carefully chosen inputs that exploit the worst '
|
||||
'case\n'
|
||||
' performance of a dict insertion, O(n^2) complexity. '
|
||||
'See\n'
|
||||
|
@ -9076,7 +9076,7 @@ topics = {'assert': 'The "assert" statement\n'
|
|||
' invoking the superclass’s "__new__()" method using\n'
|
||||
' "super().__new__(cls[, ...])" with appropriate arguments '
|
||||
'and then\n'
|
||||
' modifying the newly-created instance as necessary before '
|
||||
' modifying the newly created instance as necessary before '
|
||||
'returning\n'
|
||||
' it.\n'
|
||||
'\n'
|
||||
|
@ -9477,7 +9477,7 @@ topics = {'assert': 'The "assert" statement\n'
|
|||
'is\n'
|
||||
' intended to provide protection against a '
|
||||
'denial-of-service caused\n'
|
||||
' by carefully-chosen inputs that exploit the worst case\n'
|
||||
' by carefully chosen inputs that exploit the worst case\n'
|
||||
' performance of a dict insertion, O(n^2) complexity. '
|
||||
'See\n'
|
||||
' http://www.ocert.org/advisories/ocert-2011-003.html '
|
||||
|
|
1120
Misc/NEWS.d/3.11.0b4.rst
Normal file
1120
Misc/NEWS.d/3.11.0b4.rst
Normal file
File diff suppressed because it is too large
Load diff
|
@ -1 +0,0 @@
|
|||
``configure`` now detects and reports :pep:`11` support tiers.
|
|
@ -1,2 +0,0 @@
|
|||
Address race condition in ``Makefile`` when installing a PGO build. All
|
||||
``test`` and ``install`` targets now depend on ``all`` target.
|
|
@ -1,3 +0,0 @@
|
|||
``makesetup`` now works around an issue with sed on macOS and uses correct
|
||||
CFLAGS for object files that end up in a shared extension. Module CFLAGS
|
||||
are used before PY_STDMODULE_CFLAGS to avoid clashes with system headers.
|
|
@ -1,3 +0,0 @@
|
|||
Add C++ overloads for _Py_CAST_impl() to handle 0/NULL. This will allow C++
|
||||
extensions that pass 0 or NULL to macros using _Py_CAST() to continue to
|
||||
compile.
|
|
@ -1,3 +0,0 @@
|
|||
Avoid defining the ``static_assert`` when compiling with C++ 11, where this
|
||||
is a keyword and redefining it can lead to undefined behavior. Patch by
|
||||
Pablo Galindo
|
|
@ -1,2 +0,0 @@
|
|||
Fix the compatibility of the Python C API with C++ older than C++11. Patch by
|
||||
Victor Stinner.
|
|
@ -1,14 +0,0 @@
|
|||
The following frame functions and type are now directly available with
|
||||
``#include <Python.h>``, it's no longer needed to add ``#include
|
||||
<frameobject.h>``:
|
||||
|
||||
* :c:func:`PyFrame_Check`
|
||||
* :c:func:`PyFrame_GetBack`
|
||||
* :c:func:`PyFrame_GetBuiltins`
|
||||
* :c:func:`PyFrame_GetGenerator`
|
||||
* :c:func:`PyFrame_GetGlobals`
|
||||
* :c:func:`PyFrame_GetLasti`
|
||||
* :c:func:`PyFrame_GetLocals`
|
||||
* :c:type:`PyFrame_Type`
|
||||
|
||||
Patch by Victor Stinner.
|
|
@ -1,3 +0,0 @@
|
|||
Make ``--help`` output shorter by moving some info to the new
|
||||
``--help-env`` and ``--help-xoptions`` command-line options.
|
||||
Also add ``--help-all`` option to print complete usage.
|
|
@ -1 +0,0 @@
|
|||
Improve error message for some suites with syntax error before ':'
|
|
@ -1 +0,0 @@
|
|||
Always round the allocated size for lists up to the nearest even number.
|
|
@ -1 +0,0 @@
|
|||
Fixed a crash in ``_pickle.c`` from mutating collections during ``__reduce__`` or ``persistent_id``.
|
|
@ -1,2 +0,0 @@
|
|||
Fix the :attr:`__text_signature__` for :meth:`__get__` methods implemented
|
||||
in C. Patch by Jelle Zijlstra.
|
|
@ -1,3 +0,0 @@
|
|||
Use exponential backoff for specialization counters in the interpreter. Can
|
||||
reduce the number of failed specializations significantly and avoid slowdown
|
||||
for those parts of a program that are not suitable for specialization.
|
|
@ -1,2 +0,0 @@
|
|||
Cache the result of :c:func:`PyCode_GetCode` function to restore the O(1)
|
||||
lookup of the :attr:`~types.CodeType.co_code` attribute.
|
|
@ -1,2 +0,0 @@
|
|||
Fixed an assert where an f-string has an equal sign '=' following an
|
||||
expression, but there's no trailing brace. For example, f"{i=".
|
|
@ -1,6 +0,0 @@
|
|||
:func:`importlib.invalidate_caches` now drops entries from
|
||||
:data:`sys.path_importer_cache` with a relative path as name. This solves a
|
||||
caching issue when a process changes its current working directory.
|
||||
|
||||
``FileFinder`` no longer inserts a dot in the path, e.g.
|
||||
``/egg/./spam`` is now ``/egg/spam``.
|
|
@ -1,2 +0,0 @@
|
|||
Make sure that the end column offsets are correct in multi-line method
|
||||
calls. Previously, the end column could precede the column offset.
|
|
@ -1,2 +0,0 @@
|
|||
Fix some exponential backtrace case happening with deeply nested sequence
|
||||
patterns in match statements. Patch by Pablo Galindo
|
|
@ -1,2 +0,0 @@
|
|||
:class:`types.GenericAlias` no longer relays the ``__class__`` attribute.
|
||||
For example, ``isinstance(list[int], type)`` no longer returns ``True``.
|
|
@ -1,2 +0,0 @@
|
|||
Lazily create a table mapping bytecode offsets to line numbers to speed up
|
||||
calculation of line numbers when tracing.
|
|
@ -1,2 +0,0 @@
|
|||
Store offset of first traceable instruction in code object to avoid having
|
||||
to recompute it for each instruction when tracing.
|
|
@ -1 +0,0 @@
|
|||
Fix unreachable code warning in ``Python/specialize.c``.
|
|
@ -1 +0,0 @@
|
|||
Revise the display strategy of traceback enhanced error locations. The indicators are only shown when the location doesn't span the whole line.
|
|
@ -1 +0,0 @@
|
|||
Fix error for dictionary literals with invalid expression as value.
|
|
@ -1,3 +0,0 @@
|
|||
Don't create frame objects for incomplete frames. Prevents the creation of
|
||||
generators and closures from being observable to Python and C extensions,
|
||||
restoring the behavior of 3.10 and earlier.
|
|
@ -1,2 +0,0 @@
|
|||
Fix an issue when reading line numbers from code objects if the encoded line
|
||||
numbers are close to ``INT_MIN``. Patch by Pablo Galindo
|
|
@ -1,2 +0,0 @@
|
|||
Fixed a tokenizer crash when reading encoded files with syntax errors from
|
||||
``stdin`` with non utf-8 encoded text. Patch by Pablo Galindo
|
|
@ -1,2 +0,0 @@
|
|||
Compile and run code with unpacking of extremely large sequences (1000s of elements).
|
||||
Such code failed to compile. It now compiles and runs correctly.
|
|
@ -1,2 +0,0 @@
|
|||
Reload ``opcode`` when raising ``unknown opcode error`` in the interpreter main loop,
|
||||
for C compilers to generate dispatching code independently.
|
|
@ -1,2 +0,0 @@
|
|||
Account for instructions that can push NULL to the stack when setting line
|
||||
number in a frame. Prevents some (unlikely) crashes.
|
|
@ -1,2 +0,0 @@
|
|||
Line number of a module's ``RESUME`` instruction is set to 0 as specified in
|
||||
:pep:`626`.
|
|
@ -1 +0,0 @@
|
|||
Disable the compiler's inline-small-exit-blocks optimization for exit blocks that are associated with source code lines. This fixes a bug where the debugger cannot tell where an exception handler ends and the following code block begins.
|
|
@ -1,3 +0,0 @@
|
|||
Fix an issue where exceptions raised by line-tracing events would cause
|
||||
frames to be left in an invalid state, possibly resulting in a hard crash of
|
||||
the interpreter.
|
|
@ -1,2 +0,0 @@
|
|||
Fix an issue that caused internal frames to outlive failed Python function
|
||||
calls, possibly resulting in memory leaks or hard interpreter crashes.
|
|
@ -1,4 +0,0 @@
|
|||
Fix an issue that could cause code with multi-line method lookups to have
|
||||
misleading or incorrect column offset information. In some cases (when
|
||||
compiling a hand-built AST) this could have resulted in a hard crash of the
|
||||
interpreter.
|
|
@ -1,2 +0,0 @@
|
|||
Document that :class:`pathlib.PurePath` does not collapse
|
||||
initial double slashes because they denote UNC paths.
|
|
@ -1 +0,0 @@
|
|||
Augmented documentation of asyncio.create_task(). Clarified the need to keep strong references to tasks and added a code snippet detailing how to to this.
|
|
@ -1 +0,0 @@
|
|||
The minimum Sphinx version required to build the documentation is now 3.2.
|
|
@ -1 +0,0 @@
|
|||
Align :mod:`sqlite3` argument specs with the actual implementation.
|
|
@ -1 +0,0 @@
|
|||
Clarify :mod:`sqlite3` behavior when :ref:`sqlite3-connection-context-manager`.
|
|
@ -1,2 +0,0 @@
|
|||
Document the :pep:`246` style protocol type
|
||||
:class:`sqlite3.PrepareProtocol`.
|
|
@ -1 +0,0 @@
|
|||
:meth:`sqlite3.Connection.iterdump` now handles databases that use ``AUTOINCREMENT`` in one or more tables.
|
|
@ -1 +0,0 @@
|
|||
Fix :mod:`asyncio` incorrect traceback when future's exception is raised multiple times. Patch by Kumar Aditya.
|
|
@ -1 +0,0 @@
|
|||
Fix :mod:`ensurepip` environment isolation for subprocess running ``pip``.
|
|
@ -1,2 +0,0 @@
|
|||
In :class:`QueueHandler`, clear ``stack_info`` from :class:`LogRecord` to
|
||||
prevent stack trace from being written twice.
|
|
@ -1 +0,0 @@
|
|||
Fixed an issue with inconsistent trailing slashes in tarfile longname directories.
|
|
@ -1,3 +0,0 @@
|
|||
Deprecate current default auto() behavior: In 3.13 the default will be for
|
||||
for auto() to always return the largest member value incremented by
|
||||
1, and to raise if incompatible value types are used.
|
|
@ -1 +0,0 @@
|
|||
Move imports in :class:`~multiprocessing.SharedMemory` methods to module level so that they can be executed late in python finalization.
|
|
@ -1,3 +0,0 @@
|
|||
Now :func:`~dis.dis` and :func:`~dis.get_instructions` handle operand values
|
||||
for instructions prefixed by ``EXTENDED_ARG_QUICK``.
|
||||
Patch by Sam Gross and Dong-hee Na.
|
|
@ -1,3 +0,0 @@
|
|||
Fix :exc:`re.error` raised in :mod:`fnmatch` if the pattern contains a
|
||||
character range with upper bound lower than lower bound (e.g. ``[c-a]``).
|
||||
Now such ranges are interpreted as empty ranges.
|
|
@ -1,2 +0,0 @@
|
|||
:func:`shutil.make_archive` no longer temporarily changes the current
|
||||
working directory during creation of standard ``.zip`` or tar archives.
|
|
@ -1,2 +0,0 @@
|
|||
Accessing the :attr:`pathlib.PurePath.parents` sequence of an absolute path
|
||||
using negative index values produced incorrect results.
|
|
@ -1 +0,0 @@
|
|||
Make :class:`multiprocessing.Pool` raise an exception if ``maxtasksperchild`` is not ``None`` or a positive int.
|
|
@ -1,3 +0,0 @@
|
|||
Fix the :func:`importlib.resources.as_file` context manager to remove the
|
||||
temporary file if destroyed late during Python finalization: keep a local
|
||||
reference to the :func:`os.remove` function. Patch by Victor Stinner.
|
|
@ -1,5 +0,0 @@
|
|||
Support splitting of unpacked arbitrary-length tuple over ``TypeVar`` and
|
||||
``TypeVarTuple`` parameters. For example:
|
||||
|
||||
* ``A[T, *Ts][*tuple[int, ...]]`` -> ``A[int, *tuple[int, ...]]``
|
||||
* ``A[*Ts, T][*tuple[int, ...]]`` -> ``A[*tuple[int, ...], int]``
|
|
@ -1,3 +0,0 @@
|
|||
Update :data:`sqlite3.Cursor.rowcount` when a DML statement has run to
|
||||
completion. This fixes the row count for SQL queries like
|
||||
``UPDATE ... RETURNING``. Patch by Erlend E. Aasland.
|
|
@ -1,2 +0,0 @@
|
|||
:mod:`sqlite3` now correctly detects DML queries with leading comments.
|
||||
Patch by Erlend E. Aasland.
|
|
@ -1,4 +0,0 @@
|
|||
Fixed a case where dataclasses would try to add ``__weakref__`` into the
|
||||
``__slots__`` for a dataclass that specified ``weakref_slot=True`` when it was
|
||||
already defined in one of its bases. This resulted in a ``TypeError`` upon the
|
||||
new class being created.
|
|
@ -1,2 +0,0 @@
|
|||
Fix a multiprocessing bug where a global named resource (such as a semaphore)
|
||||
could leak when a child process is spawned (as opposed to forked).
|
|
@ -1,3 +0,0 @@
|
|||
:func:`copy.copy` and :func:`copy.deepcopy` now always raise a TypeError if
|
||||
``__reduce__()`` returns a tuple with length 6 instead of silently ignore
|
||||
the 6th item or produce incorrect result.
|
|
@ -1,2 +0,0 @@
|
|||
Emscripten and WASI have no home directory and cannot provide :pep:`370`
|
||||
user site directory.
|
|
@ -1 +0,0 @@
|
|||
Set ``__future__.annotations`` to have a ``None`` mandatoryRelease to indicate that it is currently 'TBD'.
|
|
@ -1,2 +0,0 @@
|
|||
Fix an issue where :mod:`dis` utilities could report missing or incorrect
|
||||
position information in the presence of ``CACHE`` entries.
|
|
@ -1,3 +0,0 @@
|
|||
Fixed names and ``__module__`` value of :mod:`weakref` classes
|
||||
:class:`~weakref.ReferenceType`, :class:`~weakref.ProxyType`,
|
||||
:class:`~weakref.CallableProxyType`. It makes them pickleable.
|
|
@ -1,2 +0,0 @@
|
|||
Fixed a regression when :func:`copy.copy`-ing :class:`enum.Flag` with
|
||||
multiple flag members.
|
|
@ -1 +0,0 @@
|
|||
Fix double closing of file description in :mod:`tempfile`.
|
|
@ -1,3 +0,0 @@
|
|||
Revert the :mod:`re` memory leak when a match is terminated by a signal or
|
||||
memory allocation failure as the implemented fix caused a major performance
|
||||
regression.
|
|
@ -1 +0,0 @@
|
|||
Fix repr of enum of generic aliases.
|
|
@ -1 +0,0 @@
|
|||
Pickle :class:`enum.Flag` by name.
|
|
@ -1,3 +0,0 @@
|
|||
Fix a regression in the :mod:`sqlite3` where statement objects were not
|
||||
properly cleared and reset after use in cursor iters. The regression was
|
||||
introduced by PR 27884 in Python 3.11a1. Patch by Erlend E. Aasland.
|
|
@ -1,7 +0,0 @@
|
|||
:func:`inspect.iscoroutinefunction`, :func:`inspect.isgeneratorfunction`,
|
||||
and :func:`inspect.isasyncgenfunction` now properly return ``True`` for
|
||||
duck-typed function-like objects like instances of
|
||||
:class:`unittest.mock.AsyncMock`.
|
||||
|
||||
This makes :func:`inspect.iscoroutinefunction` consistent with the
|
||||
behavior of :func:`asyncio.iscoroutinefunction`. Patch by Mehdi ABAAKOUK.
|
|
@ -1,3 +0,0 @@
|
|||
Manual instantiation of :class:`ssl.SSLSession` objects is no longer allowed
|
||||
as it lead to misconfigured instances that crashed the interpreter when
|
||||
attributes where accessed on them.
|
|
@ -1 +0,0 @@
|
|||
Fix :mod:`pdb` crash after jump caused by a null pointer dereference. Patch by Kumar Aditya.
|
|
@ -1,2 +0,0 @@
|
|||
Made :class:`_struct.Struct` GC-tracked in order to fix a reference leak in
|
||||
the :mod:`_struct` module.
|
|
@ -1 +0,0 @@
|
|||
Fixed types of :mod:`struct` module to be immutable. Patch by Kumar Aditya.
|
|
@ -1 +0,0 @@
|
|||
Once a :class:`asyncio.TaskGroup` has started shutting down (i.e., at least one task has failed and the task group has started cancelling the remaining tasks), it should not be possible to add new tasks to the task group.
|
|
@ -1 +0,0 @@
|
|||
Fix bug where :meth:`linecache.getline` fails on bad files with :exc:`UnicodeDecodeError` or :exc:`SyntaxError`. It now returns an empty string as per the documentation.
|
|
@ -1,2 +0,0 @@
|
|||
Re-entrant calls to :func:`sys.setprofile` and :func:`sys.settrace` now
|
||||
raise :exc:`RuntimeError`. Patch by Pablo Galindo.
|
|
@ -1 +0,0 @@
|
|||
Fix :func:`asyncio.run` and :class:`unittest.IsolatedAsyncioTestCase` to always the set event loop as it was done in Python 3.10 and earlier. Patch by Kumar Aditya.
|
|
@ -1,3 +0,0 @@
|
|||
The ability to access the other values of an enum on an enum (e.g.
|
||||
``Color.RED.BLUE``) has been restored in order to fix a performance
|
||||
regression.
|
|
@ -1,2 +0,0 @@
|
|||
Fix subclassing complex generics with type variables in :mod:`typing`. Previously an error message saying ``Some type variables ... are not listed in Generic[...]`` was shown.
|
||||
:mod:`typing` no longer populates ``__parameters__`` with the ``__parameters__`` of a Python class.
|
|
@ -1,3 +0,0 @@
|
|||
:meth:`SSLContext.set_default_verify_paths` now releases the GIL around
|
||||
``SSL_CTX_set_default_verify_paths`` call. The function call performs I/O
|
||||
and CPU intensive work.
|
|
@ -1 +0,0 @@
|
|||
Fix crash when deallocating an instance of a subclass of ``_multiprocessing.SemLock``. Patch by Kumar Aditya.
|
|
@ -1,4 +0,0 @@
|
|||
The deprecated mailcap module now refuses to inject unsafe text (filenames,
|
||||
MIME types, parameters) into shell commands. Instead of using such text, it
|
||||
will warn and act as if a match was not found (or for test commands, as if
|
||||
the test failed).
|
|
@ -1,2 +0,0 @@
|
|||
Fix ``memoryview`` use after free when accessing the backing buffer in certain cases.
|
||||
|
|
@ -1 +0,0 @@
|
|||
LWPCookieJar and MozillaCookieJar create files with file mode 600 instead of 644 (Microsoft Windows is not affected)
|
|
@ -1,3 +0,0 @@
|
|||
:mod:`http.server`: Fix an open redirection vulnerability in the HTTP server
|
||||
when an URI path starts with ``//``. Vulnerability discovered, and initial
|
||||
fix proposed, by Hamza Avvan.
|
|
@ -1,2 +0,0 @@
|
|||
Create a GitHub Actions workflow for verifying bundled pip and setuptools.
|
||||
Patch by Illia Volochii and Adam Turner.
|
|
@ -1 +0,0 @@
|
|||
Fixing tests that fail when running with optimizations (``-O``) in ``test_zipimport.py``
|
|
@ -1 +0,0 @@
|
|||
Fixing tests that fail when running with optimizations (``-O``) in ``test_imaplib.py``.
|
|
@ -1 +0,0 @@
|
|||
Fix ``test_embed`` for out-of-tree builds. Patch by Kumar Aditya.
|
|
@ -1,2 +0,0 @@
|
|||
Skip symlink tests on WASI. wasmtime uses ``openat2(2)`` with
|
||||
``RESOLVE_BENEATH`` flag, which prevents symlinks with absolute paths.
|
|
@ -1 +0,0 @@
|
|||
Increase calendar test coverage for :meth:`calendar.LocaleTextCalendar.formatweekday`.
|
|
@ -1 +0,0 @@
|
|||
Skip tests on WASI that require symlinks with absolute paths.
|
|
@ -1,2 +0,0 @@
|
|||
WASI does not have a ``chmod(2)`` syscall. :func:`os.chmod` is now a dummy
|
||||
function on WASI. Skip all tests that depend on working :func:`os.chmod`.
|
|
@ -1,4 +0,0 @@
|
|||
Fix issue with test_unicode test_raiseMemError. The test case now use
|
||||
``test.support.calcobjsize`` to calculate size of PyUnicode structs.
|
||||
:func:`sys.getsizeof` may return different size when string has UTF-8
|
||||
memory.
|
|
@ -1,2 +0,0 @@
|
|||
``test_modulefinder`` now creates a temporary directory in
|
||||
``ModuleFinderTest.setUp()`` instead of module scope.
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue