Commit graph

116170 commits

Author SHA1 Message Date
Ronald Oussoren
11401e2c79
[3.11] gh-105912: document gotcha with using os.fork on macOS (GH-112871) (#113135)
* gh-105912: document gotcha with using os.fork on macOS

Using ``fork(2)`` on macOS when also using higher-level
system APIs in the parent proces can crash on macOS because
those system APIs are not written to handle this usage
pattern.

There's nothing we can do about this other than documenting
the problem.

(cherry picked from commit 22511f77c2)

Co-authored-by: Carol Willing <carolcode@willingconsulting.com>
2023-12-16 10:13:01 +01:00
Miss Islington (bot)
2be7a7296f
[3.11] gh-113046: Revise csv.reader doc (GH-113207) (#113211)
Clarify nature of csvfile.
(cherry picked from commit 84df3172ef)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-12-16 08:18:45 +00:00
Miss Islington (bot)
a7a176de07
[3.11] gh-110746: Improve markup in `tkinter.ttk.rst` (GH-111236) (#113194)
gh-110746: Improve markup in ``tkinter.ttk.rst`` (GH-111236)

* gh-110746: Improve markup in tkinter.ttk.rst

* gh-110746: Improve markup in tkinter.ttk.rst

* 📜🤖 Added by blurb_it.

---------

(cherry picked from commit 00d2b6d1fc)

Co-authored-by: Akshat Khandelwal <35228810+akshatgokul@users.noreply.github.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2023-12-15 22:56:36 +01:00
Miss Islington (bot)
bbc70451e0
[3.11] gh-101100: Fix various Sphinx warnings for dunder references in the library/ directory (GH-113163) (#113184)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-15 17:21:59 +00:00
Miss Islington (bot)
740d5da5d9
[3.11] gh-101100: Fix Sphinx nitpicks in library/numbers.rst (GH-113162) (#113181)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-15 19:17:14 +02:00
Miss Islington (bot)
220fae7706
[3.11] gh-113009: Fix multiprocessing Process.terminate() on Windows (GH-113128) (#113178)
gh-113009: Fix multiprocessing Process.terminate() on Windows (GH-113128)

On Windows, Process.terminate() no longer sets the returncode
attribute to always call WaitForSingleObject() in Process.wait().
Previously, sometimes the process was still running after
TerminateProcess() even if GetExitCodeProcess() is not STILL_ACTIVE.
(cherry picked from commit 4026ad5b2c)

Co-authored-by: Victor Stinner <vstinner@python.org>
2023-12-15 15:20:18 +00:00
Miss Islington (bot)
6ff7c1311f
[3.11] gh-61648: Detect line numbers of properties in doctests (GH-113161) (GH-113165)
(cherry picked from commit 8f8f0f97e1)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-15 13:38:45 +00:00
Miss Islington (bot)
811972e2fd
[3.11] gh-101100: Fix Sphinx nitpicks in library/rlcompleter.rst (GH-113125) (#113159)
gh-101100: Fix Sphinx nitpicks in `library/rlcompleter.rst` (GH-113125)
(cherry picked from commit 7bb00f053e)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-15 09:07:15 +00:00
Hugo van Kemenade
a056aabbc7
[3.11] gh-101100: Cleanup mailbox docs (GH-113124) (#113145)
(cherry picked from commit 25061f5c98)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-14 21:26:49 +00:00
Hugo van Kemenade
b8ad2e2909
[3.11] gh-101100: Fix Sphinx warnings in whatsnew/2.3.rst (GH-112373) (#113143) 2023-12-14 14:09:53 -07:00
Miss Islington (bot)
ba6958522d
[3.11] gh-101100: Fix Sphinx nitpicks in library/collections.abc.rst (GH-113116) (#113137)
gh-101100: Fix Sphinx nitpicks in `library/collections.abc.rst` (GH-113116)
(cherry picked from commit 006355b2a9)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-14 19:32:37 +00:00
Miss Islington (bot)
99c8d16cff
[3.11] gh-101100: Fix Sphinx nitpicks in library/traceback.rst (GH-113106) (#113112)
gh-101100: Fix Sphinx nitpicks in `library/traceback.rst` (GH-113106)
(cherry picked from commit d9e1b5794a)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-14 14:17:13 +00:00
Miss Islington (bot)
3b7b256053
[3.11] gh-101100: Fix Sphinx nitpicks in library/inspect.rst and reference/simple_stmts.rst (GH-113107) (#113110)
gh-101100: Fix Sphinx nitpicks in `library/inspect.rst` and `reference/simple_stmts.rst` (GH-113107)
(cherry picked from commit 4b3cb082da)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-14 13:37:38 +00:00
Serhiy Storchaka
d4234937a1
[3.11] gh-112716: Fix SystemError when __builtins__ is not a dict (GH-112770) (GH-113105)
It was raised in two cases:
* in the import statement when looking up __import__
* in pickling some builtin type when looking up built-ins iter, getattr, etc.

(cherry picked from commit 1161c14e8c)
2023-12-14 12:59:33 +00:00
Miss Islington (bot)
08ff6fa23d
[3.11] gh-113090: Fix test.support.os_support.can_chmod() on Windows (GH-113091) (GH-113100)
(cherry picked from commit c6e953be12)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-14 14:01:01 +02:00
Miss Islington (bot)
e0c6995b4f
[3.11] Fixing typo in DocTestRunner docs (GH-112326) (GH-113098)
(cherry picked from commit b3c21265fa)

Co-authored-by: Daniel Wysocki <dwysocki@users.noreply.github.com>
2023-12-14 10:15:43 +00:00
Miss Islington (bot)
e4cdb74079
[3.11] gh-113086: Add tests for os.chmod() and os.lchmod() (GH-113087) (GH-113089)
Also make test_copymode_symlink_to_symlink in test_shutil more strict.
(cherry picked from commit b4f2c89118)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-14 07:33:35 +00:00
Miss Islington (bot)
a45a059afe
[3.11] bpo-40648: Test modes that file can get with chmod() on Windows (GH-20130) (GH-113069)
Order of tests matter second part makes testing file writable and
possible to remove again.
(cherry picked from commit f5c05e015c)

Co-authored-by: Pavol Babinčák‏ <scroolik@gmail.com>
2023-12-13 20:48:43 +00:00
Miss Islington (bot)
694631ca14
[3.11] gh-107959: clarify Unix-availability of os.lchmod() (GH-107960) (GH-113067)
gh-107959: clarify Unix-availability of `os.lchmod()` (GH-107960)

POSIX specifies that implementations are not required to support changing the
file mode of symbolic links, but may do so.
Consequently, `lchmod()` is not part of POSIX (but mentioned for implementations
which do support the above).

The current wording of the availability of `os.lchmod()` is rather vague and
improved to clearly tell which POSIX/Unix/BSD-like support the function in
general (those that support changing the file mode of symbolic links).
Further, some examples of major implementations are added.

Data for the BSDs taken from their online manpages.

(cherry picked from commit f14e3d59c9)

Signed-off-by: Christoph Anton Mitterer <mail@christoph.anton.mitterer.name>
Co-authored-by: Christoph Anton Mitterer <mail@christoph.anton.mitterer.name>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2023-12-13 20:02:07 +00:00
Miss Islington (bot)
f35322502a
[3.11] [doc] Make subprocess.wait documentation more precise (GH-98700) (#112154)
[doc] Make subprocess.wait documentation more precise (GH-98700)

[doc] Make subprocess.wait doc more precise

An active loop is only used when the `timeout` parameter is used on
POSIX.

When no timeout is used, the code calls `os.waitpid` internally (which puts
the process on a sleep status). On Windows, the internal Windows API
call accepts a timeout parameter, so that is delegated to the OS.
(cherry picked from commit 81ab0e8a4a)

Co-authored-by: Luis Pedro Coelho <luis@luispedro.org>
2023-12-13 12:01:36 -08:00
Miss Islington (bot)
4c45927c3f
[3.11] Docs: Fix external link to devguide.python.org (GH-112899) (#113064)
Co-authored-by: Miro Hrončok <miro@hroncok.cz>
2023-12-13 19:48:44 +00:00
Miss Islington (bot)
9b3447ca3c
[3.11] gh-101100: Improve docs on exception attributes (GH-113057) (#113062)
gh-101100: Improve docs on exception attributes (GH-113057)

(cherry picked from commit d05a180350)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-13 19:07:19 +00:00
Miss Islington (bot)
5fd915df6e
[3.11] [pprint]: Add docstring about PrettyPrinter.underscore_numbers parameter (GH-112963) (#113052)
[pprint]: Add docstring about `PrettyPrinter.underscore_numbers` parameter (GH-112963)
(cherry picked from commit 2a3c37c273)

Co-authored-by: Sequew <88668176+KrySeyt@users.noreply.github.com>
Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
2023-12-13 12:38:19 +00:00
Hugo van Kemenade
51858aa606
[3.11] gh-101100: Fix Sphinx warning in references with asterisks (GH-113029) (#113044) 2023-12-13 11:02:20 +02:00
Alex Waygood
b8a6eeec39
[3.11] gh-101100: Further improve docs on function attributes (#113001) (#113031)
(cherry-picked from commit 81a15ea74e)
2023-12-12 20:36:51 +00:00
Serhiy Storchaka
f78f6b6e89
[3.11] gh-112999: Replace the outdated "deprecated" directives with "versionchanged" (GH-113000) (GH-113020)
(cherry picked from commit fe9991bb67)
2023-12-12 17:17:35 +00:00
Miss Islington (bot)
8298f44136
[3.11] Update pre-commit to fix Sphinx Lint (GH-113015) (#113018)
Update pre-commit to fix Sphinx Lint (GH-113015)
(cherry picked from commit eafc2381a0)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-12-12 16:30:49 +00:00
Miss Islington (bot)
11f9502192
[3.11] [3.12] gh-83162: Rename re.error in idlelib (GH-101677) (GH-112987) (#113013)
Backport idlelib part of GH-101677 with simple rename.
(cherry picked from commit fd3b894725)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-12-12 16:21:07 +00:00
Alex Waygood
f83087ce03
[3.11] gh-101100: Improve documentation on function attributes (#112933) (#113003)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-12-12 14:19:02 +02:00
Terry Jan Reedy
ada2d77977
[3.11] gh-112953: Rename idlelib/NEWS.txt to News3.txt and update (GH… (#112992) 2023-12-12 06:10:29 +00:00
Miss Islington (bot)
70e50c0756
[3.11] gh-108303: Move double_const to test_import where it belongs (GH-112108) (#112977)
gh-108303: Move `double_const` to `test_import` where it belongs (GH-112108)
(cherry picked from commit 0738b9a338)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-12-11 18:46:02 +00:00
Miss Islington (bot)
5aec2d2452
[3.11] gh-94606: Fix error when message with Unicode surrogate not surrogateescaped string (GH-94641) (GH-112972)
(cherry picked from commit 27a5fd8cb8)

Co-authored-by: Sidney Markowitz <sidney@sidney.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-11 16:47:25 +00:00
Miss Islington (bot)
a37e1473da
[3.11] gh-112898: warn about unsaved files when quitting IDLE on macOS (GH-112939) (#112961)
gh-112898: warn about unsaved files when quitting IDLE on macOS (GH-112939)

* gh-112898: warn about unsaved files when quitting IDLE on macOS

Implement the TK function ``::tk::mac::Quit`` on macOS to
ensure that IDLE asks about saving unsaved files when
quitting IDLE.

(cherry picked from commit 3251ba8f1a)


Co-authored-by: Christopher Chavez chrischavez@gmx.us

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
2023-12-11 17:14:45 +01:00
Miss Islington (bot)
449fdfca96
[3.11] Fix SyntaxWarning in test_syntax.py (GH-112944) (GH-112956)
(cherry picked from commit 97cd45bfdb)

Co-authored-by: Anthony Sottile <asottile@umich.edu>
2023-12-11 12:09:03 +00:00
Hugo van Kemenade
2f2668391c
[3.11] GH-101986: Support translation for Limited/Unstable API & Stable ABI (GH-107680) (#112941)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
2023-12-10 12:28:10 -07:00
Miss Islington (bot)
95f5c8c46c
[3.11] gh-109980: Fix test_tarfile_vs_tar on macOS (GH-112905) (#112928)
gh-109980: Fix test_tarfile_vs_tar on macOS (GH-112905)

On recentish macOS versions the system tar
command includes system metadata (ACLs, extended attributes
and resource forks) in the tar archive, which
shutil.make_archive will not do. This can cause
spurious test failures.
(cherry picked from commit dd2ebdf89f)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
2023-12-10 19:50:10 +01:00
Miss Islington (bot)
4cc9e875c2
[3.11] gh-101100: Fix Sphinx warning in library/http.cookies.rst (GH-112908) (#112930)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Fix Sphinx warning in library/http.cookies.rst (GH-112908)
2023-12-10 12:59:29 +00:00
Miss Islington (bot)
58219bfce6
[3.11] Docs: Use 'f-strings' as header (GH-112888) (#112924)
Docs: Use 'f-strings' as header (GH-112888)
(cherry picked from commit 5bf7580d72)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-12-10 11:36:25 +02:00
Miss Islington (bot)
671f3d3ccd
[3.11] IDLE: Tweak iomenu.IOBinding.maybesave (GH-112914) (#112918)
Add docstring, use f-string, simplify code.
(cherry picked from commit ca1bde8943)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-12-10 02:56:07 +00:00
Alex Waygood
8c51e4030a
[3.11] gh-101100: Fix Sphinx nitpicks in library/tempfile.rst (#112886) (#112913)
(cherry-picked from commit 54410e6bd9)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-12-09 22:56:01 +00:00
Miss Islington (bot)
c95aa4e310
[3.11] gh-101100: Improve documentation of TracebackType attributes (GH-112884) (#112912)
gh-101100: Improve documentation of `TracebackType` attributes (GH-112884)
(cherry picked from commit 96f64a2b1b)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-09 22:50:01 +00:00
Miss Islington (bot)
2d8012f852
[3.11] gh-79429: Ignore FileNotFoundError when remove a temporary directory in the multiprocessing finalizer (GH-112865) (GH-112897)
(cherry picked from commit 7e82c626c4)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-12-09 13:31:42 +00:00
Alex Waygood
23234e9223
[3.11] gh-101100: Fix Sphinx nits in library/contextlib.rst (#112870) (#112874)
(cherry-picked from commit e4c0876033)
2023-12-08 14:03:15 +00:00
Miss Islington (bot)
161cfd0dda
[3.11] gh-101100: Improve documentation for attributes on instance methods (GH-112832) (#112873)
gh-101100: Improve documentation for attributes on instance methods (GH-112832)
(cherry picked from commit ed21d0c1f4)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-08 13:25:05 +00:00
Miss Islington (bot)
5a11bcbf71
[3.11] gh-101100: Fix Sphinx nitpicks in library/shelve.rst (GH-112836) (#112869)
gh-101100: Fix Sphinx nitpicks in `library/shelve.rst` (GH-112836)
(cherry picked from commit 3cdcc2edf8)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-12-08 12:38:40 +00:00
Łukasz Langa
1e6d36da1e
[3.11] gh-110190: Temporarily skip new test introduced in gh-112604 on PPC64LE (GH-112818) (#112830)
(cherry picked from commit 9f67042f28)
2023-12-08 12:47:32 +01:00
Miss Islington (bot)
1eac0aab85
[3.11] gh-110017: Disable test_signal.test_stress_modifying_handlers on macOS (GH-112834) (#112852)
gh-110017: Disable test_signal.test_stress_modifying_handlers on macOS (GH-112834)

Test test_stress_modifying_handlers in test_signal can crash
the interpreter due to a bug in macOS. Filed as FB13453490
with Apple.
(cherry picked from commit bf0beae6a0)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
2023-12-08 10:08:04 +01:00
Alex Waygood
cda1695799
[3.11] gh-101100: Silence Sphinx warnings when ntpath or posixpath are referenced (#112833) (#112858)
(cherry-picked from commit 2c3906bc4b)
2023-12-07 21:12:37 +00:00
Serhiy Storchaka
a18201bff1
[3.11] gh-79325: Fix recursion error in TemporaryDirectory cleanup on Windows (GH-112762) (GH-112848)
(cherry picked from commit b2923a61a1)
2023-12-07 17:46:30 +00:00
Serhiy Storchaka
5585334d77
[3.11] gh-91133: tempfile.TemporaryDirectory: fix symlink bug in cleanup (GH-99930) (GH-112839)
(cherry picked from commit 81c16cd94e)

Co-authored-by: Søren Løvborg <sorenl@unity3d.com>
2023-12-07 18:37:10 +02:00