Skip to content

Commit 49876df

Browse files
authored
Merge branch 'main' into invalid-double-star-mapping
2 parents bc0eb7d + fbf0843 commit 49876df

File tree

80 files changed

+734
-289
lines changed

Some content is hidden

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

80 files changed

+734
-289
lines changed

.github/workflows/mypy.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ on:
1616
- "Tools/build/check_extension_modules.py"
1717
- "Tools/build/check_warnings.py"
1818
- "Tools/build/compute-changes.py"
19+
- "Tools/build/consts_getter.py"
1920
- "Tools/build/deepfreeze.py"
2021
- "Tools/build/generate-build-details.py"
2122
- "Tools/build/generate_sbom.py"

Android/testbed/app/build.gradle.kts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ for ((i, prefix) in prefixes.withIndex()) {
4747
val libDir = file("$prefix/lib")
4848
val version = run {
4949
for (filename in libDir.list()!!) {
50-
"""python(\d+\.\d+)""".toRegex().matchEntire(filename)?.let {
50+
"""python(\d+\.\d+[a-z]*)""".toRegex().matchEntire(filename)?.let {
5151
return@run it.groupValues[1]
5252
}
5353
}
@@ -64,9 +64,10 @@ for ((i, prefix) in prefixes.withIndex()) {
6464
val libPythonDir = file("$libDir/python$pythonVersion")
6565
val triplet = run {
6666
for (filename in libPythonDir.list()!!) {
67-
"""_sysconfigdata__android_(.+).py""".toRegex().matchEntire(filename)?.let {
68-
return@run it.groupValues[1]
69-
}
67+
"""_sysconfigdata_[a-z]*_android_(.+).py""".toRegex()
68+
.matchEntire(filename)?.let {
69+
return@run it.groupValues[1]
70+
}
7071
}
7172
throw GradleException("Failed to find Python triplet in $libPythonDir")
7273
}

Doc/bugs.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,12 @@ If you find a bug in this documentation or would like to propose an improvement,
1919
please submit a bug report on the :ref:`issue tracker <using-the-tracker>`. If you
2020
have a suggestion on how to fix it, include that as well.
2121

22+
.. only:: translation
23+
24+
If the bug or suggested improvement concerns the translation of this
25+
documentation, submit the report to the
26+
`translation’s repository <TRANSLATION_REPO_>`_ instead.
27+
2228
You can also open a discussion item on our
2329
`Documentation Discourse forum <https://discuss.python.org/c/documentation/26>`_.
2430

Doc/c-api/long.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ distinguished from a number. Use :c:func:`PyErr_Occurred` to disambiguate.
4343
.. impl-detail::
4444
4545
CPython keeps an array of integer objects for all integers
46-
between ``-5`` and ``256``. When you create an int in that range
46+
between ``-5`` and ``1024``. When you create an int in that range
4747
you actually just get back a reference to the existing object.
4848
4949

Doc/c-api/stable.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ The full API is described below for advanced use cases.
294294
Default flags, based on current values of macros such as
295295
:c:macro:`Py_LIMITED_API` and :c:macro:`Py_GIL_DISABLED`.
296296

297-
Alternately, the field can be set to to the following flags, combined
297+
Alternately, the field can be set to the following flags, combined
298298
by bitwise OR.
299299
Unused bits must be set to zero.
300300

Doc/conf.py

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -444,6 +444,25 @@
444444
# https://github.com/sphinx-doc/sphinx/issues/12359
445445
epub_use_index = False
446446

447+
# translation tag
448+
# ---------------
449+
450+
language_code = None
451+
for arg in sys.argv:
452+
if arg.startswith('language='):
453+
language_code = arg.split('=', 1)[1]
454+
455+
if language_code:
456+
tags.add('translation') # noqa: F821
457+
458+
rst_epilog += f"""\
459+
.. _TRANSLATION_REPO: https://github.com/python/python-docs-{language_code.replace("_", "-").lower()}
460+
""" # noqa: F821
461+
else:
462+
rst_epilog += """\
463+
.. _TRANSLATION_REPO: https://github.com/python
464+
"""
465+
447466
# Options for the coverage checker
448467
# --------------------------------
449468

Doc/library/importlib.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1257,7 +1257,7 @@ find and load modules.
12571257
To accommodate this requirement, when running on iOS, extension module
12581258
binaries are *not* packaged as ``.so`` files on ``sys.path``, but as
12591259
individual standalone frameworks. To discover those frameworks, this loader
1260-
is be registered against the ``.fwork`` file extension, with a ``.fwork``
1260+
is registered against the ``.fwork`` file extension, with a ``.fwork``
12611261
file acting as a placeholder in the original location of the binary on
12621262
``sys.path``. The ``.fwork`` file contains the path of the actual binary in
12631263
the ``Frameworks`` folder, relative to the app bundle. To allow for

Doc/library/os.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3496,7 +3496,7 @@ features:
34963496
Maximum optimized size for direct I/O with torn-write protection.
34973497

34983498
.. availability:: Linux >= 4.11 with glibc >= 2.28 and build-time kernel
3499-
userspace API headers >= 6.11.
3499+
userspace API headers >= 6.16.
35003500

35013501
.. attribute:: stx_atomic_write_segments_max
35023502

Doc/library/stdtypes.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5944,7 +5944,7 @@ It is written as ``None``.
59445944
The Ellipsis Object
59455945
-------------------
59465946

5947-
This object is commonly used used to indicate that something is omitted.
5947+
This object is commonly used to indicate that something is omitted.
59485948
It supports no special operations. There is exactly one ellipsis object, named
59495949
:const:`Ellipsis` (a built-in name). ``type(Ellipsis)()`` produces the
59505950
:const:`Ellipsis` singleton.

Doc/library/tkinter.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -392,7 +392,7 @@ by spaces. Without getting into too many details, notice the following:
392392
* Operations which are implemented as separate *commands* in Tcl (like
393393
``grid`` or ``destroy``) are represented as *methods* on Tkinter widget
394394
objects. As you'll see shortly, at other times Tcl uses what appear to be
395-
method calls on widget objects, which more closely mirror what would is
395+
method calls on widget objects, which more closely mirror what is
396396
used in Tkinter.
397397

398398

0 commit comments

Comments
 (0)