Commit graph

116227 commits

Author SHA1 Message Date
Donghee Na
9beb56594d
[3.11] Use the official term "free-threading" for GitHub Action (g… (#113647) 2024-01-02 15:04:11 +02:00
Hugo van Kemenade
035b6eb987
[3.11] gh-101100: Fix Sphinx warnings from removed ~! references (GH-113629) (#113642)
(cherry picked from commit 7595380347)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2024-01-02 13:00:06 +00:00
Miss Islington (bot)
f8b61c739b
[3.11] gh-81094: Refer to PEP 318 in compound_statements.rst (GH-113588) (#113644)
Co-authored-by: John D. McDonald <43117960+Rasputin2@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2024-01-02 08:45:51 +00:00
Serhiy Storchaka
36153494f1
[3.11] gh-62260: Fix ctypes.Structure subclassing with multiple layers (GH-13374) (GH-113624)
The length field of StgDictObject for Structure class contains now
the total number of items in ffi_type_pointer.elements (excluding
the trailing null).

The old behavior of using the number of elements in the parent class can
cause the array to be truncated when it is copied, especially when there
are multiple layers of subclassing.

(cherry picked from commit 5f3cc90a12)

Co-authored-by: Jeffrey Kintscher <49998481+websurfer5@users.noreply.github.com>
2024-01-01 16:46:07 +00:00
Hugo van Kemenade
5169113379
[3.11] gh-101100: Fix Sphinx warnings in library/configparser.rst (GH-113598) (#113600)
(cherry picked from commit 30a6d79fb8)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-31 18:18:49 +00:00
Miss Islington (bot)
02912125b4
[3.11] Update ConfigParser docs defining valid section name (GH-110506) (#113590)
Co-authored-by: Delgan <4193924+Delgan@users.noreply.github.com>
2023-12-30 23:24:39 +00:00
Miss Islington (bot)
206dc9a82e
[3.11] gh-89414: Document that SIGCLD is not available on macOS (GH-113580) (#113586)
gh-89414: Document that SIGCLD is not available on macOS (GH-113580)

Document that SIGCLD is not available on macOS
(cherry picked from commit f48a1bcb29)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
2023-12-30 18:10:11 +01:00
Guido van Rossum
8938495120
[3.11] gh-113566: Fix asyncio segfault during interpreter finalization (#113578) 2023-12-29 21:06:32 -08:00
Miss Islington (bot)
ced2d35523
[3.11] gh-113543: Make sure that MacOSXOSAScript sends webbrowser.open audit event (GH-113544) (#113550)
gh-113543: Make sure that `MacOSXOSAScript` sends `webbrowser.open` audit event (GH-113544)
(cherry picked from commit fba324154e)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-12-29 09:57:21 +01:00
Miss Islington (bot)
2025d9fba2
[3.11] Doc/library/os.rst: os.waitid absent on MacOS (GH-104558) (#113554)
Doc/library/os.rst: `os.waitid` absent on MacOS (GH-104558)

* Doc/library/os.rst: `os.waitid` absent on MacOS

(cherry picked from commit db1c882239)

Co-authored-by: John Hawkinson <jhawk@alum.mit.edu>
Co-authored-by: AN Long <aisk@users.noreply.github.com>
2023-12-29 09:27:19 +01:00
Miss Islington (bot)
4d0b50ac9a
[3.11] gh-101100: Fix Sphinx warnings in library/random.rst (GH-112981) (#113552)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-28 12:40:46 -07:00
Miss Islington (bot)
656eb16707
[3.11] bpo-11102: Make configure enable major(), makedev(), and minor() on HP-UX (GH-19856) (GH-113541)
Always include <sys/types.h> before <sys/sysmacros.h>.

(cherry picked from commit f108468970)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-28 11:02:23 +00:00
Miss Islington (bot)
a486d10fc6
[3.11] gh-57795: Add news to idlelib/News3.txt (GH-113522) (#113524)
gh-57795: Add news to idlelib/News3.txt (GH-113522)
(cherry picked from commit 6c98fce33a)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-12-27 21:10:39 +00:00
Miss Islington (bot)
f9d25b56e1
[3.11] gh-67641: Clarify documentation on bytes vs text with non-seeking tarfile stream (GH-31610) (GH-113520)
(cherry picked from commit 0651936ae2)

Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
2023-12-27 17:33:00 +00:00
Miss Islington (bot)
54927cd21a
[3.11] bpo-26791: Update shutil.move() to provide the same symlink move behavior as the mv shell when moving a symlink into a directory that is the target of the symlink (GH-21759) (GH-113518)
(cherry picked from commit c66b577d9f)

Co-authored-by: Jeffrey Kintscher <49998481+websurfer5@users.noreply.github.com>
2023-12-27 19:03:45 +02:00
Miss Islington (bot)
a1f0118a26
[3.11] gh-57795: IDLE: Enter the selected text when opening the "Replace" dialog (GH-17593) (GH-113515)
(cherry picked from commit 712afab5ac)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
Co-authored-by: Roger Serwy <roger.serwy@gmail.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-27 14:43:59 +00:00
Miss Islington (bot)
050d50a28d
[3.11] gh-101100: Fix Sphinx warnings in library/cmd.rst (GH-113502) (#113510)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-27 10:24:18 +00:00
Miss Islington (bot)
e095f374bb
[3.11] gh-101100: Fix Sphinx warnings in library/calendar.rst (GH-113500) (#113508)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-12-27 09:42:57 +00:00
Hugo van Kemenade
5b5d774679
[3.11] gh-101100: Fix Sphinx warnings in library/bisect.rst (GH-113496) (#113505) 2023-12-26 14:54:07 -07:00
Serhiy Storchaka
f1951900f1
[3.11] bpo-36959: Fix error messages for invalid ISO format string in _strptime() (GH-13408) (GH-113499)
Previously some error messages complained about incompatible
combinations of directives that are not contained in the format string.

(cherry picked from commit 4b2c3e8e43)

Co-authored-by: Gordon P. Hemsley <me@gphemsley.org>
2023-12-26 20:09:41 +00:00
Miss Islington (bot)
86424e06b7
[3.11] gh-101100: Fix Sphinx warnings in howto/isolating-extensions.rst (GH-113493) (#113498)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-12-26 19:47:16 +00:00
Miss Islington (bot)
a3a461648e
[3.11] Docs: make htmllive: open browser when ready (GH-113288) (#113485)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-12-26 12:08:02 +00:00
Ronald Oussoren
0eea5c04b8
[3.11] gh-101778: Fix build error when there's a dangling symlink in the directory containing "ffi.h" (#113466)
gh-101778: Fix build error when there's a dangling symlink in the directory containing "ffi.h"
2023-12-26 10:05:48 +01:00
Serhiy Storchaka
4b358d754c
[3.11] gh-106905: Use separate structs to track recursion depth in each PyAST_mod2obj call. (GH-113035) (GH-113472) (GH-113476)
(cherry picked from commit 48c49739f5)
(cherry picked from commit d58a5f453f)

Co-authored-by: Yilei Yang <yileiyang@google.com>
Co-authored-by: Gregory P. Smith [Google LLC] <greg@krypto.org>
2023-12-25 20:40:33 +00:00
Miss Islington (bot)
1cc594d571
[3.11] bpo-37013: Fix the error handling in socket.if_indextoname() (GH-13503) (GH-112598)
* Fix a crash when pass UINT_MAX.
* Fix an integer overflow on 64-bit non-Windows platforms.
(cherry picked from commit 0daf555c6f)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2023-12-25 20:55:27 +02:00
Miss Islington (bot)
1162d29f5b
[3.11] gh-76785: Make test.test_interpreters executable (GH-112982) (GH-113470) (GH-113473)
This is so that we can run python -m test.test_interpreters. As such it
backports that aspect of commit 86a77f4e1a,
where it is implemented by a package __main__.py.
(cherry picked from commit bdad5c367f)

Co-authored-by: Jeff Allen <ja.py@farowl.co.uk>
2023-12-25 18:46:44 +00:00
Miss Islington (bot)
bc6528ee6b
[3.11] docs: specify that PyBytes_AsStringAndSize returns 0 on success (GH-110888) (GH-111691)
(cherry picked from commit 9f33ede127)

Co-authored-by: lefp <70862148+lefp@users.noreply.github.com>
2023-12-25 20:24:44 +02:00
Miss Islington (bot)
88cc19b530
[3.11] gh-113440: Ignore the "ver" command failure with exit code 0xc0000142 (GH-113435) (GH-113452)
(cherry picked from commit 53330f1677)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-24 10:47:54 +00:00
Miss Islington (bot)
d04ca4ccd7
[3.11] gh-113421: Fix multiprocessing logger for "%(filename)s" (GH-113423) (GH-113451)
(cherry picked from commit ce77ee5035)

Co-authored-by: Xu Song <xusong.vip@gmail.com>
2023-12-24 10:22:34 +00:00
Miss Islington (bot)
336d445934
[3.11] gh-113028: Correctly memoize str in pickle when escapes added (GH-113436) (GH-113449)
This fixes a divergence between the Python and C implementations of pickle
for protocol 0, such that it pickle.py fails to re-use the first pickled
representation of strings involving characters that have to be escaped.
(cherry picked from commit 08398631a0)

Co-authored-by: Jeff Allen <ja.py@farowl.co.uk>
2023-12-24 10:01:53 +00:00
Miss Islington (bot)
b60bddbde2
[3.11] gh-112559: Avoid unnecessary conversion attempts to enum_klass in signal.py (GH-113040) (#113444)
gh-112559: Avoid unnecessary conversion attempts to enum_klass in signal.py (GH-113040)
(cherry picked from commit 050783cb37)

Co-authored-by: Yilei Yang <yileiyang@google.com>
2023-12-23 18:09:46 -08:00
Miss Islington (bot)
9000b8a713
[3.11] gh-109989: Fix test_c_locale_coercion when PYTHONIOENCODING is set (GH-113378) (#113399)
gh-109989: Fix test_c_locale_coercion when PYTHONIOENCODING is set (GH-113378)

* gh-109989: Fix test_c_locale_coercion when PYTHONIOENCODING is set

This fixes the existing tests when PYTHONIOENCODING is
set by unsetting PYTHONIOENCODING.

Also add a test that explicitly checks what happens
when PYTHONIOENCODING is set.

(cherry picked from commit 5f665e99e0)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-12-23 21:58:18 +01:00
Miss Islington (bot)
478da38e74
[3.11] gh-74573: document that ndbm can silently corrupt databases on macOS (GH-113354) (#113432)
gh-74573: document that ndbm can silently corrupt databases on macOS (GH-113354)

* gh-74573: document that ndbm can silently corrupt databases on macOS

The system ndbm implementation on macOS has an undocumented limitation
on the size of values and can silently corrupt database files when those
are exceeded.

(cherry picked from commit 593b4d81d2)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2023-12-23 13:49:58 +01:00
Serhiy Storchaka
fe2b4dd3c0
[3.11] gh-81682: Fix test failures when CPython is built without docstrings (GH-113410) (GH-113430)
(cherry picked from commit 4e5b27e6a3)
2023-12-23 11:38:07 +00:00
Miss Islington (bot)
80b2bad2c2
[3.11] gh-113188: Fix shutil.copymode() and shutil.copystat() on Windows (GH-113285) (GH-113426)
Previously they worked differenly if dst is a symbolic link:
they modified the permission bits of dst itself rather than the file
it points to if follow_symlinks is true or src is not a symbolic link,
and did nothing if follow_symlinks is false and src is a symbolic link.
(cherry picked from commit c7874bb56f)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-23 12:53:48 +02:00
Miss Islington (bot)
0bd134d15f
[3.11] gh-112925: Fix error in example of datetime.time.fromisoformat and add doctest marker (GH-112931) (GH-113428)
(cherry picked from commit bdc8d667ab)

Co-authored-by: F-park <52167622+F-park@users.noreply.github.com>
2023-12-23 10:50:19 +00:00
Miss Islington (bot)
e59ad5796e
[3.11] gh-113384: Skip test_freeze for framework builds on macOS (GH-113390) (#113396)
gh-113384: Skip test_freeze for framework builds on macOS (GH-113390)
(cherry picked from commit bee627c1e2)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
2023-12-22 12:07:07 +01:00
Miss Islington (bot)
706b40e892
[3.11] gh-65701: document that freeze doesn't work with framework builds on macOS (GH-113352) (#113361)
gh-65701: document that freeze doesn't work with framework builds on macOS (GH-113352)

* gh-65701: document that freeze doesn't work with framework builds on macOS

The framework install is inherently incompatible with freeze. Document
that that freeze doesn't work with framework builds and bail out
early when trying to run freeze anyway.

(cherry picked from commit df1eec3dae)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2023-12-22 11:16:59 +01:00
Hugo van Kemenade
a39131ed8c
[3.11] gh-110383: Improve accuracy of str.split() and str.rsplit() docstrings (GH-113355) (#113380)
Co-authored-by: Erlend E. Aasland <erlend@python.org>
2023-12-22 00:43:38 -07:00
Miss Islington (bot)
beb1c6506c
[3.11] gh-113313: Note that slice support is not required for all sequences. (gh-113377) (gh-113383) 2023-12-21 22:01:25 +00:00
Miss Islington (bot)
4baa4b519a
[3.11] Docs: OpenSSL wording ambiguity (GH-113296) (#113349)
Co-authored-by: Jan Brasna <1784648+janbrasna@users.noreply.github.com>
2023-12-21 07:56:34 +00:00
Miss Islington (bot)
90593e6fa1
[3.11] gh-112305: Fix check-clean-src to detect frozen_modules .h files. (GH-113344) (#113347)
gh-112305: Fix check-clean-src to detect frozen_modules .h files. (GH-113344)

A typo left this check broken so many of us who do out-of-tree builds
were seeing strange failures due to bad `Python/frozen_modules/*.h`
files being picked up from the source tree and used at build time from
different Python versions leading to errors like:

`Fatal Python error: _PyImport_InitCore: failed to initialize importlib`

Or similar once our build got to an "invoke the interpreter"
bootstrapping step due to incorrect bytecode being embedded.
(cherry picked from commit 103c4ea274)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2023-12-21 07:47:20 +00:00
Miss Islington (bot)
9cbe4738bc
[3.11] GH-113214: Fix SSLProto exception handling in SSL-over-SSL scenarios (GH-113334) (#113340)
When wrapped, `_SSLProtocolTransport._force_close(exc)` is called just like in the unwrapped scenario `_SelectorTransport._force_close(exc)` or `_ProactorBasePipeTransport._force_close(exc)` would be called, except here the exception needs to be passed through the `SSLProtocol._abort()` method, which didn't accept an exception object.

This commit ensures that this path works, in the same way that the uvloop implementation of SSLProto passes on the exception (on which the current implementation of SSLProto is based).

(cherry picked from commit 1ff0238594)

Co-authored-by: Martijn Pieters <mj@zopatista.com>
2023-12-20 16:51:51 -08:00
Alex Waygood
d65dfc8238
[3.11] gh-113255: Clarify docs for typing.reveal_type (#113286) (#113326)
(cherry-picked from commit 11ee912327)

Co-authored-by: Kir <note351@hotmail.com>
2023-12-20 18:35:13 +00:00
Miss Islington (bot)
899f1c082c
[3.11] Fix typo in datamodel docs (GH-113314) (#113315)
Fix typo in datamodel docs (GH-113314)
(cherry picked from commit 5a7cc667f8)

Co-authored-by: Rodrigo Girão Serrão <5621605+rodrigogiraoserrao@users.noreply.github.com>
2023-12-20 12:04:59 +00:00
Miss Islington (bot)
f1c27bebb2
[3.11] Fix typo in collections.abc docs example (GH-113310) (#113312)
Fix typo in collections.abc docs example (GH-113310)

Calling the instance reference arg for the __next__ method, "next", seems misleading as it would normally just be "self"
(cherry picked from commit 22b8945d76)

Co-authored-by: David Greaves <david@dgreaves.com>
2023-12-20 09:57:25 +00:00
Miss Islington (bot)
5e0d9aea99
[3.11] gh-102362: Fix macOS version number in result of sysconfig.get_platform() (GH-112942) (#113265)
gh-102362: Fix macOS version number in result of sysconfig.get_platform() (GH-112942)

Change _osx_support.get_platform_osx() to make sure that the
version number in the result includes at least a major and
minor version (e.g. 14.2) even if MACOSX_DEPLOYMENT_TARGET is
set to just a major version (e.g. 14).

This matches the versions expected by pip when selecting
appropriate wheels for installation.
(cherry picked from commit 893c9ccf48)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
2023-12-19 19:57:08 +01:00
Hugo van Kemenade
182676beba
[3.11] gh-101100: Fix Sphinx warnings in library/ast.rst (GH-113289) (#113291) 2023-12-19 18:12:33 +02:00
Miss Islington (bot)
208c95bffe
[3.11] gh-113234: tomllib docs: reorder conversion table & add remaining types (GH-113236) (GH-113284)
gh-113234: tomllib docs: reorder conversion table & add remaining types (GH-113236)
(cherry picked from commit 76d757b38b)

Co-authored-by: ryan-duve <ryan-duve@users.noreply.github.com>
2023-12-19 10:36:01 +00:00
Miss Islington (bot)
d6830c7cbf
[3.11] gh-113208: Mention namespace packages don't require __init__.py (GH-113209) (#113277)
Co-authored-by: Unique-Usman <86585626+Unique-Usman@users.noreply.github.com>
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2023-12-19 08:46:08 +00:00