Skip to content

Commit 3c04d9d

Browse files
authored
Merge branch 'main' into gh-162822-bytearray-list-race
2 parents 3992fba + f77c71e commit 3c04d9d

54 files changed

Lines changed: 1160 additions & 323 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.gitignore‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
*.orig
1818
*.pyc
1919
*.pyd
20-
*.pyo
2120
*.rej
2221
*.swp
2322
*.pickle

‎Doc/library/sqlite3.rst‎

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -443,18 +443,19 @@ Module constants
443443
.. code-block:: sql
444444
445445
CREATE TABLE test(
446-
i integer primary key, ! will look up a converter named "integer"
447-
p point, ! will look up a converter named "point"
448-
n number(10) ! will look up a converter named "number"
446+
i integer primary key, -- will look up a converter named "integer"
447+
p point, -- will look up a converter named "point"
448+
n number(10) -- will look up a converter named "number"
449449
)
450450
451451
This flag may be combined with :const:`PARSE_COLNAMES` using the ``|``
452452
(bitwise or) operator.
453453

454454
.. note::
455455

456-
Generated fields (for example ``MAX(p)``) are returned as :class:`str`.
457-
Use :const:`!PARSE_COLNAMES` to enforce types for such queries.
456+
Expressions such as ``MAX(p)`` have no declared type, so their results use
457+
the :ref:`default type conversions <sqlite3-types>`.
458+
Use :const:`!PARSE_COLNAMES` to specify a converter for such expressions.
458459

459460
.. data:: PARSE_COLNAMES
460461

@@ -467,7 +468,7 @@ Module constants
467468

468469
.. code-block:: sql
469470
470-
SELECT MAX(p) as "p [point]" FROM test; ! will look up converter "point"
471+
SELECT MAX(p) as "p [point]" FROM test; -- will look up converter "point"
471472
472473
This flag may be combined with :const:`PARSE_DECLTYPES` using the ``|``
473474
(bitwise or) operator.
@@ -846,7 +847,7 @@ Connection objects
846847
* ``finalize()``: Return the final result of the aggregate as
847848
:ref:`a type natively supported by SQLite <sqlite3-types>`.
848849

849-
The number of arguments that the ``step()`` and ``value()`` methods
850+
The number of arguments that the ``step()`` and ``inverse()`` methods
850851
must accept is controlled by *num_params*.
851852

852853
Set to ``None`` to remove an existing SQL aggregate window function.
@@ -1186,8 +1187,8 @@ Connection objects
11861187
``ATTACH DATABASE`` SQL statement.
11871188

11881189
:param float sleep:
1189-
The number of seconds to sleep between successive attempts
1190-
to back up remaining pages.
1190+
The number of seconds to wait before retrying a backup step
1191+
when the database is busy or locked.
11911192

11921193
Example 1, copy an existing database into another:
11931194

@@ -1407,8 +1408,7 @@ Connection objects
14071408
This read-only attribute corresponds to the low-level SQLite
14081409
`autocommit mode`_.
14091410

1410-
``True`` if a transaction is active (there are uncommitted changes),
1411-
``False`` otherwise.
1411+
``True`` if a transaction is active, ``False`` otherwise.
14121412

14131413
.. versionadded:: 3.2
14141414

@@ -2172,7 +2172,7 @@ The coordinate pair will be stored as a text string in the database,
21722172
using a semicolon to separate the coordinates.
21732173
This can be implemented by adding a ``__conform__(self, protocol)``
21742174
method which returns the adapted value.
2175-
The object passed to *protocol* will be of type :class:`PrepareProtocol`.
2175+
The parameter *protocol* will be :class:`PrepareProtocol`.
21762176

21772177
.. testcode::
21782178

@@ -2443,7 +2443,7 @@ or if :attr:`~Connection.autocommit` is ``True``,
24432443
the context manager does nothing.
24442444

24452445
.. note::
2446-
The context manager neither implicitly opens a new transaction
2446+
The context manager neither implicitly opens a new transaction on entry
24472447
nor closes the connection. If you need a closing context manager, consider
24482448
using :meth:`contextlib.closing`.
24492449

@@ -2491,8 +2491,8 @@ Some useful URI tricks include:
24912491
OperationalError: attempt to write a readonly database
24922492
>>> con.close()
24932493

2494-
* Do not implicitly create a new database file if it does not already exist;
2495-
will raise :exc:`~sqlite3.OperationalError` if unable to create a new file:
2494+
* Open an existing database in read/write mode.
2495+
If the file does not exist, :func:`connect` raises :exc:`OperationalError`:
24962496

24972497
.. doctest::
24982498

‎Doc/whatsnew/3.14.rst‎

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3492,6 +3492,16 @@ Changes in the C API
34923492
.. _pythoncapi-compat project: https://github.com/python/pythoncapi-compat/
34933493

34943494

3495+
Notable changes in 3.14.1
3496+
=========================
3497+
3498+
* Add :c:func:`PyUnstable_ThreadState_SetStackProtection` and
3499+
:c:func:`PyUnstable_ThreadState_ResetStackProtection` functions to set
3500+
the stack protection base address and stack protection size of a Python
3501+
thread state.
3502+
(Contributed by Victor Stinner in :gh:`139653`.)
3503+
3504+
34953505
Notable changes in 3.14.5
34963506
=========================
34973507

@@ -3504,3 +3514,31 @@ gc
35043514
<https://github.com/python/cpython/issues/142516>`__
35053515
of significant memory pressure in production environments.
35063516
See :ref:`whatsnew314-incremental-gc` for details.
3517+
3518+
3519+
Notable changes in 3.14.10
3520+
==========================
3521+
3522+
ssl
3523+
---
3524+
3525+
* The :mod:`ssl` module now rejects TLS certificate chains that contain one
3526+
of a set of compromised eMudhra intermediate CA certificates. The affected
3527+
certificates are identified by their public key, so cross-signed copies that
3528+
reuse the same key are blocked as well. It is a defense-in-depth backstop
3529+
that applies even when an application supplies its own root CA bundle, and
3530+
regardless of whether the platform trust store has removed trust.
3531+
(Contributed by Christian Heimes in :gh:`160040` for :cve:`2026-115557`.)
3532+
3533+
3534+
Notable changes in 3.14.11
3535+
==========================
3536+
3537+
C API changes
3538+
-------------
3539+
3540+
* :c:func:`Py_INCREF`, :c:func:`Py_XINCREF`, :c:func:`Py_DECREF` and
3541+
:c:func:`Py_XDECREF` are now implemented as function calls on all limited C
3542+
API versions. Previously, they were only implemented as function calls on
3543+
the limited C API version 3.12 or newer. Patch by Victor Stinner:
3544+
(Contributed by Victor Stinner in :gh:`158401`.)

‎Doc/whatsnew/3.15.rst‎

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2937,3 +2937,43 @@ that may require changes to your code.
29372937
Use warning filters to silence them or additional :meth:`!assertWarns*`
29382938
to catch and check them.
29392939
(Contributed by Serhiy Storchaka in :gh:`143231`.)
2940+
2941+
2942+
Notable changes in 3.15.2
2943+
=========================
2944+
2945+
importlib
2946+
---------
2947+
2948+
* Threads that simultaneously perform first-time ``import package.submodule``
2949+
imports no longer risk a deadlock or spurious import errors, a regression
2950+
introduced in 3.15.0 by the fix for :gh:`83065`. A package's import lock is
2951+
now released as soon as its ``__init__`` returns.
2952+
:func:`importlib.import_module` now returns the partially initialized
2953+
module in a circular import split across threads, as the :keyword:`import`
2954+
statement already did, instead of raising ``_DeadlockError``.
2955+
(Contributed by Gregory P. Smith in :gh:`159963`.)
2956+
2957+
ssl
2958+
---
2959+
2960+
* The :mod:`ssl` module now rejects TLS certificate chains that contain one
2961+
of a set of compromised eMudhra intermediate CA certificates. The affected
2962+
certificates are identified by their public key, so cross-signed copies that
2963+
reuse the same key are blocked as well. It is a defense-in-depth backstop
2964+
that applies even when an application supplies its own root CA bundle, and
2965+
regardless of whether the platform trust store has removed trust.
2966+
(Contributed by Christian Heimes in :gh:`160040` for :cve:`2026-115557`.)
2967+
2968+
2969+
Notable changes in 3.15.3
2970+
=========================
2971+
2972+
C API changes
2973+
-------------
2974+
2975+
* :c:func:`Py_INCREF`, :c:func:`Py_XINCREF`, :c:func:`Py_DECREF` and
2976+
:c:func:`Py_XDECREF` are now implemented as function calls on all limited C
2977+
API versions. Previously, they were only implemented as function calls on
2978+
the limited C API version 3.12 or newer. Patch by Victor Stinner:
2979+
(Contributed by Victor Stinner in :gh:`158401`.)

‎Doc/whatsnew/3.16.rst‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,13 @@ Other language changes
139139
:func:`asyncio.print_call_graph` can see through them into the awaited code.
140140
(Contributed by Kumar Aditya in :gh:`157361`.)
141141

142+
* Functions that take timestamp or timeout arguments
143+
no longer convert numbers other than integers and floats
144+
(such as :class:`~decimal.Decimal` and :class:`~fractions.Fraction`)
145+
to :class:`float`.
146+
They are converted exactly, which avoids the precision loss.
147+
(Contributed by Serhiy Storchaka in :gh:`67795`.)
148+
142149

143150
Default interactive shell
144151
=========================

‎Include/cpython/descrobject.h‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ typedef struct {
5555
PyDescr_COMMON;
5656
struct wrapperbase *d_base;
5757
void *d_wrapped; /* This can be any function pointer */
58+
vectorcallfunc vectorcall;
5859
} PyWrapperDescrObject;
5960

6061
PyAPI_FUNC(PyObject *) PyDescr_NewWrapper(PyTypeObject *,

‎Include/internal/pycore_global_objects_fini_generated.h‎

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎Include/internal/pycore_global_strings.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -436,6 +436,7 @@ struct _Py_global_strings {
436436
STRUCT_FOR_ID(default)
437437
STRUCT_FOR_ID(defaultaction)
438438
STRUCT_FOR_ID(delete)
439+
STRUCT_FOR_ID(denominator)
439440
STRUCT_FOR_ID(depth)
440441
STRUCT_FOR_ID(desired_access)
441442
STRUCT_FOR_ID(detect_types)
@@ -704,6 +705,7 @@ struct _Py_global_strings {
704705
STRUCT_FOR_ID(nt)
705706
STRUCT_FOR_ID(null)
706707
STRUCT_FOR_ID(number)
708+
STRUCT_FOR_ID(numerator)
707709
STRUCT_FOR_ID(obj)
708710
STRUCT_FOR_ID(object)
709711
STRUCT_FOR_ID(offset)

‎Include/internal/pycore_runtime_init_generated.h‎

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎Include/internal/pycore_unicodeobject_generated.h‎

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)