Commit graph

118378 commits

Author SHA1 Message Date
Hugo van Kemenade
41dfae8f86
[3.12] gh-101100: Fix sphinx warnings in library/getpass.rst (GH-110461) (#111080)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-10-19 15:38:58 +00:00
Miss Islington (bot)
3e9d84c94c
[3.12] gh-109510: Clearly explain "Which Docstrings Are Examined" (GH-109696) (#111077)
Co-authored-by: Unique-Usman <86585626+Unique-Usman@users.noreply.github.com>
Co-authored-by: Mariatta <Mariatta@users.noreply.github.com>
Co-authored-by: Jacob Coffee <jacob@z7x.org>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2023-10-19 18:35:04 +03:00
Miss Islington (bot)
91a6e98e92
[3.12] GH-101100: Fix reference warnings for `__enter__ and __exit__` (GH-110112) (#111075)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2023-10-19 18:34:25 +03:00
Miss Islington (bot)
cdcab408a0
[3.12] GH-101100: Fix reference warnings for `__getitem__` (GH-110118) (#111073)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2023-10-19 18:33:03 +03:00
Radislav Chugunov
68a5640a36
[3.12] gh-108791: Fix pdb CLI invalid argument handling (GH-108816) (#111064)
* [3.12] gh-108791: Fix `pdb` CLI invalid argument handling (GH-108816)
(cherry picked from commit 162213f2db)

Co-authored-by: Radislav Chugunov <52372310+chgnrdv@users.noreply.github.com>
2023-10-19 14:25:49 +01:00
Miss Islington (bot)
40db34c901
[3.12] gh-111031: Check more files in test_tokenize (GH-111032) (#111061)
gh-111031: Check more files in `test_tokenize` (GH-111032)
(cherry picked from commit e9b5399bee)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-10-19 09:18:22 +00:00
Miss Islington (bot)
e37d56e8dd
[3.12] gh-111050: IDLE - Simplify configdialog.HighPage.theme_elements (GH-111053) (#111055)
gh-111050: IDLE - Simplify configdialog.HighPage.theme_elements (GH-111053)

Replace tuple value with internal name, removing numbers.
Remove sorting of already ordered dislay names.
Remove '[0]' indexing into now-gone tuple.
(cherry picked from commit 642eb8df95)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-10-19 04:32:06 +00:00
Brandt Bucher
d312135764
[3.12] GH-103082: Clean up the sys.monitoring docs (GH-111048)
(cherry picked from commit 1991694117)
2023-10-18 23:30:13 +00:00
Miss Islington (bot)
9ef8caf293
[3.12] GH-104232: Fix statement about trace return values (GH-111047)
(cherry picked from commit d9246c7b73)
2023-10-18 23:22:03 +00:00
Miss Islington (bot)
228b124932
[3.12] gh-111015: Install IDLE.app and Python Launcher.app on macOS with correct permissions (gh-111037)
(cherry picked from commit cb1bf89c40)

Co-authored-by: Joshua Root <jmr@macports.org>
Co-authored-by: Ned Deily <nad@python.org>
2023-10-18 13:32:09 +00:00
Miss Islington (bot)
b8ce5d9c17
[3.12] gh-103737: IDLE - Remove unneeded .keys() for dict iteration (GH-110960) (#111026)
gh-103737: IDLE - Remove unneeded .keys() for dict iteration (GH-110960)

Add comments where .keys() is needed.
Leave debugger usages along because situation is unclear as indicated in expanded comment.
Most testing is manual.
(cherry picked from commit baefbb21d9)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2023-10-18 09:05:08 +00:00
Miss Islington (bot)
577a8fb72b
[3.12] gh-111019: Align expected and actual titles in test output (GH-111020) (#111024)
gh-111019: Align expected and actual titles in test output (GH-111020)

Align expected and actual titles in output from
assert_has_calls/assert_called_with for greater readability
(cherry picked from commit 77dbd95609)

Co-authored-by: James <morisja@gmail.com>
2023-10-18 08:01:18 +00:00
Miss Islington (bot)
004618fed7
[3.12] gh-110938: More syntax tests for PEP695 funcs and classes (GH-110986) (#111023)
gh-110938: More syntax tests for PEP695 funcs and classes (GH-110986)
(cherry picked from commit 220bcc9e27)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-10-18 06:02:17 +00:00
Jelle Zijlstra
2bca5f43af
[3.12] gh-110938: Fix error messages for indented blocks with functio… (#110990)
[3.12] gh-110938: Fix error messages for indented blocks with functions and classes with generic type parameters (GH-110973)
(cherry picked from commit 24e4ec7766)

Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
2023-10-17 22:26:34 -07:00
Miss Islington (bot)
8134811089
[3.12] Regen Doc/requirements-oldest-sphinx.txt (GH-111012) (#111022)
Regen Doc/requirements-oldest-sphinx.txt (GH-111012)

Fix https://github.com/python/cpython/security/dependabot/4: use
urllib3 version 2.0.7.
(cherry picked from commit e7ae43ad7d)

Co-authored-by: Victor Stinner <vstinner@python.org>
2023-10-18 04:30:14 +00:00
Miss Islington (bot)
ae838afe35
[3.12] gh-107457: update dis documentation with changes in 3.12 (GH-108900) (#110985)
gh-107457: update dis documentation with changes in 3.12 (GH-108900)
(cherry picked from commit 198aa67d4c)

Co-authored-by: Matthieu Dartiailh <m.dartiailh@gmail.com>
2023-10-18 00:38:42 +02:00
Miss Islington (bot)
f0c2390a1f
[3.12] gh-110995: Fix test_gdb check_usable_gdb() (GH-110998) (#111003)
gh-110995: Fix test_gdb check_usable_gdb() (GH-110998)

Fix detection of gdb built without Python scripting support.

* check_usable_gdb() doesn't check gdb exit code when calling
  run_gdb().
* Use shutil.which() to get the path to the gdb program.
(cherry picked from commit 920b3dfaca)

Co-authored-by: Victor Stinner <vstinner@python.org>
2023-10-17 18:45:55 +00:00
Nikita Sobolev
c1e5343928
[3.12] Bump test deps: ruff and pre-commit-hooks (GH-110972) (#110980)
(cherry picked from commit b75b1f389f)
2023-10-17 13:01:57 +00:00
Miss Islington (bot)
9aa899354a
[3.12] gh-110695: test_asyncio uses 50 ms for clock resolution (GH-110952) (#110970)
gh-110695: test_asyncio uses 50 ms for clock resolution (GH-110952)

Before utils.CLOCK_RES constant was added (20 ms), test_asyncio
already used 50 ms.
(cherry picked from commit 9a9fba825f)

Co-authored-by: Victor Stinner <vstinner@python.org>
2023-10-17 10:13:31 +00:00
Miss Islington (bot)
99b7e1c1d7
[3.12] Bump sphinx-lint to v0.8.1 (GH-110933) (#110957)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-10-16 23:29:43 -06:00
Miss Islington (bot)
94525a7a4d
[3.12] C-API docs: Clarify the size of arenas (GH-110895) (#110946)
C-API docs: Clarify the size of arenas (GH-110895)

Clarify the size of arenas

From 3.10.0 alpha 7, the pymalloc allocator uses arenas with a fixed size of 1
MiB on 64-bit platforms instead of 256 KiB on 32-bit platforms.
(cherry picked from commit f07ca27709)

Co-authored-by: Mienxiu <82512658+mienxiu@users.noreply.github.com>
2023-10-16 19:03:18 +00:00
Lysandros Nikolaou
3b87e520fc
[3.12] gh-107450: Check for overflow in the tokenizer and fix overflow test (GH-110832) (#110931)
(cherry picked from commit a1ac5590e0)

Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Filipe Laíns <lains@riseup.net>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-10-16 18:59:18 +02:00
Alex Waygood
b8e5b1b28a
[3.12] Enable ruff on several more files in Lib/test (#110929) (#110934)
(cherry-picked from commit 02d26c4bef)
2023-10-16 15:48:02 +00:00
Miss Islington (bot)
89f9c226a1
[3.12] regrtest: Prepend 'use' options in --{fast,slow}-ci (GH-110363) (#110925)
regrtest: Prepend 'use' options in --{fast,slow}-ci (GH-110363)

This allows individual resources to be disabled without having to explicitly re-enable all others.
(cherry picked from commit b75186f69e)

Co-authored-by: Zachary Ware <zach@python.org>
2023-10-16 13:35:01 +00:00
Miss Islington (bot)
b4ed73042e
[3.12] gh-110527: Improve PySet_Clear docs (GH-110528) (#110928)
gh-110527: Improve `PySet_Clear` docs (GH-110528)
(cherry picked from commit bfc1cd8145)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-10-16 13:14:52 +00:00
Miss Islington (bot)
7de3c8b7b6
[3.12] Lint: Include test_monitoring.py for Ruff (GH-110898) (#110899)
Lint: Include test_monitoring.py for Ruff (GH-110898)
(cherry picked from commit 9608704cde)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-10-15 18:34:37 +01:00
Hugo van Kemenade
9c39149b4b
[3.12] gh-106193: Rename and fix duplicated tests in test_monitoring (GH-109139) (#110897) 2023-10-15 17:32:08 +00:00
Miss Islington (bot)
97f4b667e7
[3.12] gh-110886 Doc: add a link to BNF Wikipedia article (GH-110887) (#110900)
Co-authored-by: partev <petrosyan@gmail.com>
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2023-10-15 17:00:44 +00:00
Serhiy Storchaka
72b0f0eaf5
[3.12] bpo-42663: Fix parsing TZ strings in zoneinfo module (GH-23825) (GH-110882)
zipinfo now supports the full range of values in the TZ string
determined by RFC 8536 and detects all invalid formats.
Both Python and C implementations now raise exceptions of the same
type on invalid data.
(cherry picked from commit ab08ff7882)
2023-10-15 10:59:19 +03:00
Nikita Sobolev
b6755d81d4
[3.12] gh-109216: Fix possible memory leak in BUILD_MAP (#109324) 2023-10-15 07:08:40 +05:30
Miss Islington (bot)
744f752f04
[3.12] gh-101100: Fix sphinx warnings in library/time.rst (GH-110862) (#110877)
gh-101100: Fix sphinx warnings in `library/time.rst` (GH-110862)
(cherry picked from commit 12deda7633)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-10-14 14:28:58 +00:00
Miss Islington (bot)
0c56c05022
[3.12] remove redundant call to attach_loop in watcher (GH-110847) (#110867)
(cherry picked from commit 596589104f)

Co-authored-by: Thomas Grainger <tagrain@gmail.com>
2023-10-14 12:27:08 +02:00
Miss Islington (bot)
9786959a11
[3.12] gh-110715: Add missing import in zipfile (gh-110822) (gh-110861)
gh-110715: Add missing import in zipfile (gh-110822)
(cherry picked from commit 4110cfec12)

Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
2023-10-14 07:58:31 +00:00
Serhiy Storchaka
7c3e8e5af0
[3.12] gh-110628: Add tests for PyLong C API (GH-110629) (GH-110854)
(cherry picked from commit 9d40ebf190)
2023-10-14 10:20:24 +03:00
Miss Islington (bot)
9a62322174
[3.12] gh-107705: Fix file leak in test_tkinter in the C locale (GH-110507) (GH-110857)
(cherry picked from commit ca0f3d858d)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-10-14 06:43:59 +00:00
Miss Islington (bot)
a2cc9a4c3a
[3.12] gh-109747: Improve errors for unsupported look-behind patterns (GH-109859) (GH-110859)
Now re.error is raised instead of OverflowError or RuntimeError for
too large width of look-behind pattern.

The limit is increased to 2**32-1 (was 2**31-1).
(cherry picked from commit e2b3d831fd)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-10-14 06:42:19 +00:00
Miss Islington (bot)
12b9cb80be
[3.12] gh-101100: Fix sphinx warnings in usage/cmdline.rst (GH-110841) (#110855)
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-10-14 00:28:34 -06:00
Miss Islington (bot)
0164832db5
[3.12] gh-110392: Fix tty functions (GH-110642) (GH-110853)
* tty.setraw() and tty.setcbreak() previously returned partially modified
  list of the original tty attributes. Now they return the correct list of
  the original tty attributes

* tty.cfmakeraw() and tty.cfmakecbreak() now make a copy of the list of
  special characters before modifying it.

(cherry picked from commit 84e2096fbd)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-10-14 06:18:14 +00:00
Nikita Sobolev
0102faf0ca
[3.12] gh-108303: Move all inspect test files to test_inspect/ (GH-109607) (#110732)
(cherry picked from commit 732532b0af)
2023-10-13 19:05:03 +02:00
Miss Islington (bot)
49da117665
[3.12] Bump sphinx-lint to 0.7.0 (GH-110830) (#110833)
Bump sphinx-lint to 0.7.0 (GH-110830)
(cherry picked from commit 0ed2329a16)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2023-10-13 13:59:12 +00:00
Miss Islington (bot)
1c44f881c7
[3.12] gh-110815: Improve tests for PyArg_ParseTupleAndKeywords() (GH-110817) (GH-110825)
(cherry picked from commit 548ce0923b)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2023-10-13 13:41:43 +00:00
Miss Islington (bot)
1a7afa7ef4
[3.12] gh-110703: Add asyncio.wait_for() change notes for 3.11 (GH-110818) (#110826)
gh-110703: Add asyncio.wait_for() change notes for 3.11 (GH-110818)

* Remove redundant versionchanged

* Add missing versionchanged

* Update Doc/library/asyncio-task.rst



---------

(cherry picked from commit f81e36f700)

Co-authored-by: paskozdilar <53006174+paskozdilar@users.noreply.github.com>
Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2023-10-13 13:24:28 +00:00
Miss Islington (bot)
f2e353b9d8
[3.12] gh-110803: Reorganize docs for what PyType_Slot doesn't cover (GH-110813) (#110823)
gh-110803: Reorganize docs for what PyType_Slot doesn't cover (GH-110813)

* gh-110803: Reorganize docs for what PyType_Slot doesn't cover

- Cover the offset fields first
- Mention the old alternative for MANAGED flags, which is needed
  to support older Pythons
- De-emphasize the internal flags: use an inline list.
- Add a note to PyMemberDef saying what to do with it

* Remove an older draft...
(cherry picked from commit 2ab34f0e42)

Co-authored-by: Petr Viktorin <encukou@gmail.com>
2023-10-13 12:59:55 +00:00
Miss Islington (bot)
08242cdd7b
[3.12] gh-107450: Fix parser column offset overflow test on Windows (GH-110768) (#110808)
(cherry picked from commit 05439d3087)

Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2023-10-13 10:31:39 +02:00
Miss Islington (bot)
27d5ea291c
[3.12] gh-110782: Fix crash when TypeVar is constructed with keyword args (GH-110784) (#110787)
gh-110782: Fix crash when TypeVar is constructed with keyword args (GH-110784)
(cherry picked from commit d2a536b170)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2023-10-12 23:24:37 +00:00
Victor Stinner
80f958529b
[3.12] gh-110756: Sync regrtest with main branch (#110779)
gh-110756: Sync regrtest with main branch

* Remove runtest.py and runtest_mp.py of Lib/test/libregrtest/.
* Backport support._parse_memlimit().
2023-10-12 21:24:12 +00:00
Victor Stinner
4b7a12db54
[3.12] gh-110756: Sync regrtest with main branch (#110758)
gh-110756: Sync regrtest with main branch

Copy files from main to this branch:

* Lib/test/libregrtest/*.py
* Lib/test/__init__.py
* Lib/test/__main__.py
* Lib/test/autotest.py
* Lib/test/pythoninfo.py
* Lib/test/regrtest.py
* Lib/test/test_regrtest.py

Do not modify scripts running tests such as Makefile.pre.in,
.github/workflows/build.yml or Tools/scripts/run_tests.py: do not use
--fast-ci and --slow-ci in this change.

Changes:

* SPLITTESTDIRS: don't include test_inspect.
* Add utils.process_cpu_count() using len(os.sched_getaffinity(0)).
* test_regrtest doesn't use @support.without_optimizer which doesn't
  exist in Python 3.12.
* Add support.set_sanitizer_env_var().
* Update test_faulthandler to use support.set_sanitizer_env_var().
2023-10-12 22:03:07 +02:00
Pablo Galindo Salgado
4d0e6c895e
[3.12] gh-110696: Fix incorrect syntax error message for incorrect argument unpacking (GH-110706) (#110765)
(cherry picked from commit 3d180347ae)
2023-10-12 10:51:56 +00:00
Miss Islington (bot)
ea3ac56a05
[3.12] gh-107450: Raise OverflowError when parser column offset overflows (GH-110754) (#110762)
(cherry picked from commit fb7843ee89)

Co-authored-by: Lysandros Nikolaou <lisandrosnik@gmail.com>
2023-10-12 10:03:09 +00:00
Erlend E. Aasland
e8d04190c6
[3.12] GH-107518: Remove the Argument Clinic How-To (#109900) (#110760)
(cherry picked from commit d1f7fae424)

* Remove the content of the Argument Clinic HOWTO
* Update cross-references to the Argument Clinic
* Add a note directing readers to the devguide

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2023-10-12 09:37:37 +00:00