Skip to content

Commit afd8a5b

Browse files
authored
Merge branch 'main' into frozenset_immutable_tracking
2 parents f37f46e + 58ccf21 commit afd8a5b

File tree

169 files changed

+6288
-3072
lines changed

Some content is hidden

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

169 files changed

+6288
-3072
lines changed

.github/CODEOWNERS

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,8 @@
6363
.azure-pipelines/ @AA-Turner
6464

6565
# GitHub & related scripts
66-
.github/ @ezio-melotti @hugovk @AA-Turner
67-
Tools/build/compute-changes.py @AA-Turner
66+
.github/ @ezio-melotti @hugovk @AA-Turner @webknjaz
67+
Tools/build/compute-changes.py @AA-Turner @hugovk @webknjaz
6868
Tools/build/verify_ensurepip_wheels.py @AA-Turner @pfmoore @pradyunsg
6969

7070
# Pre-commit
@@ -176,6 +176,7 @@ Tools/wasm/config.site-wasm32-emscripten @freakboy3742 @emmatyping
176176
Tools/wasm/emscripten @freakboy3742 @emmatyping
177177

178178
# WebAssembly (WASI)
179+
Platforms/WASI @brettcannon @emmatyping @savannahostrowski
179180
Tools/wasm/wasi-env @brettcannon @emmatyping @savannahostrowski
180181
Tools/wasm/wasi.py @brettcannon @emmatyping @savannahostrowski
181182
Tools/wasm/wasi @brettcannon @emmatyping @savannahostrowski

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ jobs:
261261
# Keep 1.1.1w in our list despite it being upstream EOL and otherwise
262262
# unsupported as it most resembles other 1.1.1-work-a-like ssl APIs
263263
# supported by important vendors such as AWS-LC.
264-
openssl_ver: [1.1.1w, 3.0.18, 3.2.6, 3.3.5, 3.4.3, 3.5.4]
264+
openssl_ver: [1.1.1w, 3.0.18, 3.3.5, 3.4.3, 3.5.4, 3.6.0]
265265
# See Tools/ssl/make_ssl_data.py for notes on adding a new version
266266
env:
267267
OPENSSL_VER: ${{ matrix.openssl_ver }}

.github/workflows/reusable-wasi.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,14 +47,14 @@ jobs:
4747
- name: "Runner image version"
4848
run: echo "IMAGE_OS_VERSION=${ImageOS}-${ImageVersion}" >> "$GITHUB_ENV"
4949
- name: "Configure build Python"
50-
run: python3 Tools/wasm/wasi configure-build-python -- --config-cache --with-pydebug
50+
run: python3 Platforms/WASI configure-build-python -- --config-cache --with-pydebug
5151
- name: "Make build Python"
52-
run: python3 Tools/wasm/wasi make-build-python
52+
run: python3 Platforms/WASI make-build-python
5353
- name: "Configure host"
5454
# `--with-pydebug` inferred from configure-build-python
55-
run: python3 Tools/wasm/wasi configure-host -- --config-cache
55+
run: python3 Platforms/WASI configure-host -- --config-cache
5656
- name: "Make host"
57-
run: python3 Tools/wasm/wasi make-host
57+
run: python3 Platforms/WASI make-host
5858
- name: "Display build info"
5959
run: make --directory "${CROSS_BUILD_WASI}" pythoninfo
6060
- name: "Test"

Doc/c-api/conversion.rst

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,8 @@ The following functions provide locale-independent string to number conversions.
130130
131131
*flags* can be zero or more of the following values or-ed together:
132132
133+
.. c:namespace:: NULL
134+
133135
.. c:macro:: Py_DTSF_SIGN
134136
135137
Always precede the returned string with a sign
@@ -151,9 +153,21 @@ The following functions provide locale-independent string to number conversions.
151153
152154
.. versionadded:: 3.11
153155
154-
If *ptype* is non-``NULL``, then the value it points to will be set to one of
155-
``Py_DTST_FINITE``, ``Py_DTST_INFINITE``, or ``Py_DTST_NAN``, signifying that
156-
*val* is a finite number, an infinite number, or not a number, respectively.
156+
If *ptype* is non-``NULL``, then the value it points to will be set to one
157+
of the following constants depending on the type of *val*:
158+
159+
.. list-table::
160+
:header-rows: 1
161+
:align: left
162+
163+
* - *\*ptype*
164+
- type of *val*
165+
* - .. c:macro:: Py_DTST_FINITE
166+
- finite number
167+
* - .. c:macro:: Py_DTST_INFINITE
168+
- infinite number
169+
* - .. c:macro:: Py_DTST_NAN
170+
- not a number
157171
158172
The return value is a pointer to *buffer* with the converted string or
159173
``NULL`` if the conversion failed. The caller is responsible for freeing the

Doc/c-api/lifecycle.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -256,6 +256,8 @@ To allocate and free memory, see :ref:`allocating-objects`.
256256
collection (i.e., the :c:macro:`Py_TPFLAGS_HAVE_GC` flag is set); this may
257257
change in the future.
258258
259+
.. versionadded:: 3.4
260+
259261
260262
.. c:function:: int PyObject_CallFinalizerFromDealloc(PyObject *op)
261263
@@ -266,6 +268,8 @@ To allocate and free memory, see :ref:`allocating-objects`.
266268
should happen. Otherwise, this function returns 0 and destruction can
267269
continue normally.
268270
271+
.. versionadded:: 3.4
272+
269273
.. seealso::
270274
271275
:c:member:`~PyTypeObject.tp_dealloc` for example code.

Doc/c-api/long.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -687,7 +687,7 @@ Export API
687687
688688
.. versionadded:: 3.14
689689
690-
.. c:struct:: PyLongLayout
690+
.. c:type:: PyLongLayout
691691
692692
Layout of an array of "digits" ("limbs" in the GMP terminology), used to
693693
represent absolute value for arbitrary precision integers.
@@ -727,15 +727,15 @@ Export API
727727
728728
Get the native layout of Python :class:`int` objects.
729729
730-
See the :c:struct:`PyLongLayout` structure.
730+
See the :c:type:`PyLongLayout` structure.
731731
732732
The function must not be called before Python initialization nor after
733733
Python finalization. The returned layout is valid until Python is
734734
finalized. The layout is the same for all Python sub-interpreters
735735
in a process, and so it can be cached.
736736
737737
738-
.. c:struct:: PyLongExport
738+
.. c:type:: PyLongExport
739739
740740
Export of a Python :class:`int` object.
741741
@@ -769,7 +769,7 @@ Export API
769769
770770
Export a Python :class:`int` object.
771771
772-
*export_long* must point to a :c:struct:`PyLongExport` structure allocated
772+
*export_long* must point to a :c:type:`PyLongExport` structure allocated
773773
by the caller. It must not be ``NULL``.
774774
775775
On success, fill in *\*export_long* and return ``0``.
@@ -799,7 +799,7 @@ The :c:type:`PyLongWriter` API can be used to import an integer.
799799
800800
.. versionadded:: 3.14
801801
802-
.. c:struct:: PyLongWriter
802+
.. c:type:: PyLongWriter
803803
804804
A Python :class:`int` writer instance.
805805
@@ -827,7 +827,7 @@ The :c:type:`PyLongWriter` API can be used to import an integer.
827827
The layout of *digits* is described by :c:func:`PyLong_GetNativeLayout`.
828828
829829
Digits must be in the range [``0``; ``(1 << bits_per_digit) - 1``]
830-
(where the :c:struct:`~PyLongLayout.bits_per_digit` is the number of bits
830+
(where the :c:type:`~PyLongLayout.bits_per_digit` is the number of bits
831831
per digit).
832832
Any unused most significant digits must be set to ``0``.
833833

Doc/data/stable_abi.dat

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

Doc/faq/programming.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1226,13 +1226,13 @@ This converts the list into a set, thereby removing duplicates, and then back
12261226
into a list.
12271227

12281228

1229-
How do you remove multiple items from a list
1230-
--------------------------------------------
1229+
How do you remove multiple items from a list?
1230+
---------------------------------------------
12311231

12321232
As with removing duplicates, explicitly iterating in reverse with a
12331233
delete condition is one possibility. However, it is easier and faster
12341234
to use slice replacement with an implicit or explicit forward iteration.
1235-
Here are three variations.::
1235+
Here are three variations::
12361236

12371237
mylist[:] = filter(keep_function, mylist)
12381238
mylist[:] = (x for x in mylist if keep_condition)

Doc/howto/remote_debugging.rst

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@ execute Python code remotely.
88

99
Most platforms require elevated privileges to attach to another Python process.
1010

11+
Disabling remote debugging
12+
--------------------------
13+
14+
To disable remote debugging support, use any of the following:
15+
16+
* Set the :envvar:`PYTHON_DISABLE_REMOTE_DEBUG` environment variable to ``1`` before
17+
starting the interpreter.
18+
* Use the :option:`-X disable_remote_debug` command-line option.
19+
* Compile Python with the :option:`--without-remote-debug` build flag.
20+
1121
.. _permission-requirements:
1222

1323
Permission requirements
@@ -614,4 +624,3 @@ To inject and execute a Python script in a remote process:
614624
6. Set ``_PY_EVAL_PLEASE_STOP_BIT`` in the ``eval_breaker`` field.
615625
7. Resume the process (if suspended). The script will execute at the next safe
616626
evaluation point.
617-

Doc/library/base64.rst

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -84,15 +84,20 @@ POST request.
8484
A :exc:`binascii.Error` exception is raised
8585
if *s* is incorrectly padded.
8686

87-
If *validate* is ``False`` (the default), characters that are neither
87+
If *validate* is false (the default), characters that are neither
8888
in the normal base-64 alphabet nor the alternative alphabet are
89-
discarded prior to the padding check. If *validate* is ``True``,
90-
these non-alphabet characters in the input result in a
91-
:exc:`binascii.Error`.
89+
discarded prior to the padding check, but the ``+`` and ``/`` characters
90+
keep their meaning if they are not in *altchars* (they will be discarded
91+
in future Python versions).
92+
If *validate* is true, these non-alphabet characters in the input
93+
result in a :exc:`binascii.Error`.
9294

9395
For more information about the strict base64 check, see :func:`binascii.a2b_base64`
9496

95-
May assert or raise a :exc:`ValueError` if the length of *altchars* is not 2.
97+
.. deprecated:: next
98+
Accepting the ``+`` and ``/`` characters with an alternative alphabet
99+
is now deprecated.
100+
96101

97102
.. function:: standard_b64encode(s)
98103

@@ -123,6 +128,9 @@ POST request.
123128
``/`` in the standard Base64 alphabet, and return the decoded
124129
:class:`bytes`.
125130

131+
.. deprecated:: next
132+
Accepting the ``+`` and ``/`` characters is now deprecated.
133+
126134

127135
.. function:: b32encode(s)
128136

@@ -246,8 +254,7 @@ Refer to the documentation of the individual functions for more information.
246254
*adobe* controls whether the input sequence is in Adobe Ascii85 format
247255
(i.e. is framed with <~ and ~>).
248256

249-
*ignorechars* should be a :term:`bytes-like object` or ASCII string
250-
containing characters to ignore
257+
*ignorechars* should be a byte string containing characters to ignore
251258
from the input. This should only contain whitespace characters, and by
252259
default contains all whitespace characters in ASCII.
253260

0 commit comments

Comments
 (0)