]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
2 years agobpo-42663: Fix parsing TZ strings in zoneinfo module (GH-23825)
Serhiy Storchaka [Sat, 14 Oct 2023 20:24:33 +0000 (23:24 +0300)] 
bpo-42663: Fix parsing TZ strings in zoneinfo module (GH-23825)

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.

2 years agogh-101100: Fix sphinx warnings in `library/time.rst` (#110862)
Nikita Sobolev [Sat, 14 Oct 2023 14:20:19 +0000 (17:20 +0300)] 
gh-101100: Fix sphinx warnings in `library/time.rst` (#110862)

2 years agoremove redundant call to attach_loop in watcher (#110847)
Thomas Grainger [Sat, 14 Oct 2023 08:24:02 +0000 (01:24 -0700)] 
remove redundant call to attach_loop in watcher (#110847)

2 years agogh-110715: Add missing import in zipfile (gh-110822)
Kirill Podoprigora [Sat, 14 Oct 2023 07:17:47 +0000 (10:17 +0300)] 
gh-110715: Add missing import in zipfile (gh-110822)

2 years agogh-109747: Improve errors for unsupported look-behind patterns (GH-109859)
Serhiy Storchaka [Sat, 14 Oct 2023 06:13:02 +0000 (09:13 +0300)] 
gh-109747: Improve errors for unsupported look-behind patterns (GH-109859)

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).

2 years agogh-107705: Fix file leak in test_tkinter in the C locale (GH-110507)
Serhiy Storchaka [Sat, 14 Oct 2023 06:09:07 +0000 (09:09 +0300)] 
gh-107705: Fix file leak in test_tkinter in the C locale (GH-110507)

2 years agogh-88434: Emit deprecation warnings for non-integer numbers in gettext if translation...
Serhiy Storchaka [Sat, 14 Oct 2023 06:07:02 +0000 (09:07 +0300)] 
gh-88434: Emit deprecation warnings for non-integer numbers in gettext if translation not found (GH-110574)

2 years agogh-101100: Fix sphinx warnings in `usage/cmdline.rst` (#110841)
Nikita Sobolev [Sat, 14 Oct 2023 06:05:46 +0000 (09:05 +0300)] 
gh-101100: Fix sphinx warnings in `usage/cmdline.rst` (#110841)

2 years agogh-110628: Add tests for PyLong C API (GH-110629)
Serhiy Storchaka [Sat, 14 Oct 2023 05:53:57 +0000 (08:53 +0300)] 
gh-110628: Add tests for PyLong C API (GH-110629)

2 years agogh-110392: Fix tty functions (GH-110642)
Serhiy Storchaka [Sat, 14 Oct 2023 05:50:41 +0000 (08:50 +0300)] 
gh-110392: Fix tty functions (GH-110642)

* 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.

2 years agogh-110815: Support non-ASCII keyword names in PyArg_ParseTupleAndKeywords() (GH-110816)
Serhiy Storchaka [Sat, 14 Oct 2023 05:50:03 +0000 (08:50 +0300)] 
gh-110815: Support non-ASCII keyword names in PyArg_ParseTupleAndKeywords() (GH-110816)

It already mostly worked, except in the case when invalid keyword
argument with non-ASCII name was passed to function with non-ASCII
parameter names. Then it crashed in the debug mode.

2 years agoregrtest: --fast-ci/slow-ci no longer imply --rerun-fail (#110849)
Victor Stinner [Sat, 14 Oct 2023 00:25:38 +0000 (02:25 +0200)] 
regrtest: --fast-ci/slow-ci no longer imply --rerun-fail (#110849)

2 years agogh-109693: Update pyruntimestate._finalizing to use pyatomic.h (gh-110837)
Donghee Na [Fri, 13 Oct 2023 16:40:15 +0000 (01:40 +0900)] 
gh-109693: Update pyruntimestate._finalizing to use pyatomic.h (gh-110837)

2 years agogh-110697: test_os TimerfdTests uses selectors (#110789)
Victor Stinner [Fri, 13 Oct 2023 14:20:18 +0000 (16:20 +0200)] 
gh-110697: test_os TimerfdTests uses selectors (#110789)

Replace select.epoll() with selectors.DefaultSelector to support
FreeBSD 14 and newer.

* Merge common code between test_timerfd_epoll()
  test_timerfd_ns_epoll().
* Replace "_ = func()" with "func()".
* Add TimerfdTests.read_count_signaled() method.

2 years agogh-110771: Decompose run_forever() into parts (#110773)
Russell Keith-Magee [Fri, 13 Oct 2023 14:12:32 +0000 (16:12 +0200)] 
gh-110771: Decompose run_forever() into parts (#110773)

Effectively introduce an unstable, private (really: protected) API for subclasses that want to override `run_forever()`.

2 years agoBump sphinx-lint to 0.7.0 (#110830)
Alex Waygood [Fri, 13 Oct 2023 13:58:26 +0000 (15:58 +0200)] 
Bump sphinx-lint to 0.7.0 (#110830)

2 years agogh-110703: Add asyncio.wait_for() change notes for 3.11 (GH-110818)
paskozdilar [Fri, 13 Oct 2023 13:15:28 +0000 (15:15 +0200)] 
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

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
---------

Co-authored-by: Kumar Aditya <kumaraditya@python.org>
2 years agogh-110815: Improve tests for PyArg_ParseTupleAndKeywords() (GH-110817)
Serhiy Storchaka [Fri, 13 Oct 2023 13:05:01 +0000 (16:05 +0300)] 
gh-110815: Improve tests for PyArg_ParseTupleAndKeywords() (GH-110817)

2 years agogh-110803: Reorganize docs for what PyType_Slot doesn't cover (GH-110813)
Petr Viktorin [Fri, 13 Oct 2023 12:51:48 +0000 (14:51 +0200)] 
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...

2 years agoMerge branch 'main' of https://github.com/python/cpython
Thomas Wouters [Fri, 13 Oct 2023 11:40:12 +0000 (13:40 +0200)] 
Merge branch 'main' of https://github.com/python/cpython

2 years agoPost 3.13.0a1
Thomas Wouters [Fri, 13 Oct 2023 11:39:00 +0000 (13:39 +0200)] 
Post 3.13.0a1

2 years agogh-110805: Fix test_peg_generator after the change in the parser for REPL tracebacks...
Pablo Galindo Salgado [Fri, 13 Oct 2023 11:04:23 +0000 (13:04 +0200)] 
gh-110805: Fix test_peg_generator after the change in the parser for REPL tracebacks (#110814)

Fix test_peg_generator after the change in the parser for REPL tracebacks

2 years agogh-110805: Allow the repl to show source code and complete tracebacks (#110775)
Pablo Galindo Salgado [Fri, 13 Oct 2023 09:25:37 +0000 (11:25 +0200)] 
gh-110805: Allow the repl to show source code and complete tracebacks (#110775)

2 years agogh-106212: Raise when using c-analyzer with clang on darwin (#110757)
Lysandros Nikolaou [Fri, 13 Oct 2023 08:52:30 +0000 (10:52 +0200)] 
gh-106212: Raise when using c-analyzer with clang on darwin (#110757)

2 years agoPython 3.13.0a1 v3.13.0a1
Thomas Wouters [Fri, 13 Oct 2023 08:50:46 +0000 (10:50 +0200)] 
Python 3.13.0a1

2 years agoFix the pyspecific SOURCE_URI (#110811)
T. Wouters [Fri, 13 Oct 2023 08:43:01 +0000 (10:43 +0200)] 
Fix the pyspecific SOURCE_URI (#110811)

2 years agogh-107450: Fix testMemoryErrorBigSource using the bigmemtest decorator (GH-110810)
Lysandros Nikolaou [Fri, 13 Oct 2023 08:30:56 +0000 (10:30 +0200)] 
gh-107450: Fix testMemoryErrorBigSource using the bigmemtest decorator (GH-110810)

2 years agogh-110525: Delete `test_c_api` method from `set` object (#110688)
Nikita Sobolev [Fri, 13 Oct 2023 08:06:25 +0000 (11:06 +0300)] 
gh-110525: Delete `test_c_api` method from `set` object (#110688)

2 years agogh-107450: Fix parser column offset overflow test on Windows (#110768)
Lysandros Nikolaou [Fri, 13 Oct 2023 07:41:00 +0000 (09:41 +0200)] 
gh-107450: Fix parser column offset overflow test on Windows (#110768)

Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
2 years agoGH-110796: fix intermittent test failure in test_current_exceptions
Filipe Laíns [Fri, 13 Oct 2023 06:26:27 +0000 (07:26 +0100)] 
GH-110796: fix intermittent test failure in test_current_exceptions

2 years agoGH-110786: suppress BrokenPipeError on the sysconfig CLI (#110791)
Filipe Laíns [Fri, 13 Oct 2023 05:49:55 +0000 (06:49 +0100)] 
GH-110786: suppress BrokenPipeError on the sysconfig CLI (#110791)

2 years agoGH-103480: fix sysconfig package not being installed (#110792)
Filipe Laíns [Fri, 13 Oct 2023 01:13:28 +0000 (02:13 +0100)] 
GH-103480: fix sysconfig package not being installed (#110792)

2 years agogh-109693: Update _gil_runtime_state.last_holder to use pyatomic.h (#110605)
Donghee Na [Fri, 13 Oct 2023 01:07:27 +0000 (10:07 +0900)] 
gh-109693: Update _gil_runtime_state.last_holder to use pyatomic.h (#110605)

2 years agoGH-103480: make sysconfig a package (GH-110785)
Filipe Laíns [Thu, 12 Oct 2023 23:41:34 +0000 (00:41 +0100)] 
GH-103480: make sysconfig a package (GH-110785)

2 years agogh-110782: Fix crash when TypeVar is constructed with keyword args (#110784)
Jelle Zijlstra [Thu, 12 Oct 2023 23:00:12 +0000 (16:00 -0700)] 
gh-110782: Fix crash when TypeVar is constructed with keyword args (#110784)

2 years agoRemove unnecessary escape in Doc/library/enum.rst (GH-110780)
InSync [Thu, 12 Oct 2023 22:04:36 +0000 (05:04 +0700)] 
Remove unnecessary escape in Doc/library/enum.rst (GH-110780)

2 years agogh-109653: Improve the import time of `email.utils` (#109824)
Alex Waygood [Thu, 12 Oct 2023 22:03:20 +0000 (00:03 +0200)] 
gh-109653: Improve the import time of `email.utils` (#109824)

2 years agogh-110721: Use the traceback module for PyErr_Display() and fallback to the C impleme...
Pablo Galindo Salgado [Thu, 12 Oct 2023 14:52:14 +0000 (16:52 +0200)] 
gh-110721: Use the traceback module for PyErr_Display() and fallback to the C implementation (#110702)

2 years agogh-94597: Add asyncio.EventLoop (#110723)
Thomas Grainger [Thu, 12 Oct 2023 14:13:57 +0000 (07:13 -0700)] 
gh-94597: Add asyncio.EventLoop (#110723)

This is needed to pave the way for deprecating and eventually killing the event loop policy system (which is over-engineered and rarely used).

2 years agogh-110752: Reset `ceval.eval_breaker` to 0 in `interpreter_clear` (GH-110753)
Tian Gao [Thu, 12 Oct 2023 14:10:21 +0000 (07:10 -0700)] 
gh-110752: Reset `ceval.eval_breaker` to 0 in `interpreter_clear` (GH-110753)

2 years agogh-109409: Fix inheritance of frozen dataclass from non-frozen dataclass mixins ...
Nikita Sobolev [Thu, 12 Oct 2023 13:05:23 +0000 (16:05 +0300)] 
gh-109409: Fix inheritance of frozen dataclass from non-frozen dataclass mixins (gh-109437)

Fix inheritance of frozen dataclass from non-frozen dataclass mixins

2 years agogh-109094: remove redundant arg to _PyFrame_PushTrampolineUnchecked (GH-110759)
Irit Katriel [Thu, 12 Oct 2023 10:02:42 +0000 (12:02 +0200)] 
gh-109094: remove redundant arg to _PyFrame_PushTrampolineUnchecked (GH-110759)

2 years agoGH-109214: Convert _SAVE_CURRENT_IP to _SET_IP in tier 2 trace creation. (GH-110755)
Mark Shannon [Thu, 12 Oct 2023 09:34:32 +0000 (10:34 +0100)] 
GH-109214: Convert _SAVE_CURRENT_IP to _SET_IP in tier 2 trace creation. (GH-110755)

2 years agogh-107450: Raise OverflowError when parser column offset overflows (#110754)
Lysandros Nikolaou [Thu, 12 Oct 2023 09:34:12 +0000 (11:34 +0200)] 
gh-107450: Raise OverflowError when parser column offset overflows (#110754)

2 years agogh-110696: Fix incorrect syntax error message for incorrect argument unpacking (...
Pablo Galindo Salgado [Thu, 12 Oct 2023 09:02:02 +0000 (10:02 +0100)] 
gh-110696: Fix incorrect syntax error message for incorrect argument unpacking (#110706)

2 years agogh-71587: Establish global state in `_datetime` (#110475)
Erlend E. Aasland [Thu, 12 Oct 2023 08:28:10 +0000 (10:28 +0200)] 
gh-71587: Establish global state in `_datetime` (#110475)

* Use explicit initialiser for m_base
* Add module state stub; establish global state on stack
* Put conversion factors in state struct
* Move PyDateTime_TimeZone_UTC to state
* Move PyDateTime_Epoch to state struct
* Fix ref leaks in and clean up initialisation

2 years agogh-106193: Rename and fix duplicated tests in `test_monitoring` (GH-109139)
Hugo van Kemenade [Thu, 12 Oct 2023 07:43:58 +0000 (09:43 +0200)] 
gh-106193: Rename and fix duplicated tests in `test_monitoring` (GH-109139)

2 years agogh-104169: Fix test_peg_generator after tokenizer refactoring (#110727)
Lysandros Nikolaou [Thu, 12 Oct 2023 07:34:35 +0000 (09:34 +0200)] 
gh-104169: Fix test_peg_generator after tokenizer refactoring (#110727)

* Fix test_peg_generator after tokenizer refactoring
* Remove references to tokenizer.c in comments etc.

2 years agoGH-110749: fix unistd.h import in file_tokenizer.c (#110750)
Filipe Laíns [Thu, 12 Oct 2023 05:52:13 +0000 (06:52 +0100)] 
GH-110749: fix unistd.h import in file_tokenizer.c (#110750)

2 years agogh-110682: Ignore `__match_args__` from `__instancecheck__` in protocols (#110683)
Nikita Sobolev [Thu, 12 Oct 2023 02:20:20 +0000 (05:20 +0300)] 
gh-110682: Ignore `__match_args__` from `__instancecheck__` in protocols (#110683)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2 years agogh-85283: _stat extension now uses the limited C API (#110711)
Victor Stinner [Wed, 11 Oct 2023 22:06:20 +0000 (00:06 +0200)] 
gh-85283: _stat extension now uses the limited C API (#110711)

gh-85283: _stat extension uses the limited C API

The _stat C extension is now built with the limited C API.

2 years agogh-110673: test_pty raises on short write (#110677)
Victor Stinner [Wed, 11 Oct 2023 21:30:15 +0000 (23:30 +0200)] 
gh-110673: test_pty raises on short write (#110677)

Add write_all() helper function to test_pty to raise an exception on
short write: if os.writes() does not write all bytes. It should not
happen for a PTY.

2 years agogh-110733: Micro-optimization in BaseEventLoop._run_once (#110735)
J. Nick Koston [Wed, 11 Oct 2023 20:59:27 +0000 (10:59 -1000)] 
gh-110733: Micro-optimization in BaseEventLoop._run_once (#110735)

2 years agogh-110631: Fix reST indentation in `Doc/reference` (#110708)
Ezio Melotti [Wed, 11 Oct 2023 20:50:55 +0000 (22:50 +0200)] 
gh-110631: Fix reST indentation in `Doc/reference` (#110708)

Fix wrong indentation in the Doc/reference dir.

2 years agogh-85283: If Py_LIMITED_API is defined, undefine Py_BUILD_CORE (#110725)
Victor Stinner [Wed, 11 Oct 2023 20:47:54 +0000 (22:47 +0200)] 
gh-85283: If Py_LIMITED_API is defined, undefine Py_BUILD_CORE (#110725)

If the Py_LIMITED_API macro is defined, Py_BUILD_CORE,
Py_BUILD_CORE_BUILTIN and Py_BUILD_CORE_MODULE macros are now
undefined by Python.h.

Only undefine these 3 macros after including "exports.h" which uses
them to define PyAPI_FUNC(), PyAPI_DATA() and PyMODINIT_FUNC macros.

Remove hacks (undefine manually the 3 Py_BUILD_CORE macros) in
Modules/_testcapi/parts.h and Modules/_testclinic_limited.c.

2 years agogh-110631: Fix reST indentation (#110724)
Ezio Melotti [Wed, 11 Oct 2023 20:43:03 +0000 (22:43 +0200)] 
gh-110631: Fix reST indentation (#110724)

* Fix wrong indentation in the other dirs.

* Fix more wrong indentation.

2 years agogh-110631: Fix reST indentation in `Doc/library` (#110685)
Ezio Melotti [Wed, 11 Oct 2023 20:24:12 +0000 (22:24 +0200)] 
gh-110631: Fix reST indentation in `Doc/library` (#110685)

Fix wrong indentation in the Doc/library dir.

2 years agogh-65052: Prevent pdb from crashing when trying to display objects (#110578)
Tian Gao [Wed, 11 Oct 2023 17:52:14 +0000 (10:52 -0700)] 
gh-65052: Prevent pdb from crashing when trying to display objects (#110578)

2 years agogh-109408: Revert pre-commit whitespace checks pending portable solution (#110726)
Hugo van Kemenade [Wed, 11 Oct 2023 16:12:28 +0000 (18:12 +0200)] 
gh-109408: Revert pre-commit whitespace checks pending portable solution (#110726)

2 years agogh-110313: Revert "gh-90108: Disable LTO on _freeze_module and _teste… (#110720)
Victor Stinner [Wed, 11 Oct 2023 15:54:40 +0000 (17:54 +0200)] 
gh-110313: Revert "gh-90108: Disable LTO on _freeze_module and _teste… (#110720)

gh-110313: Revert "gh-90108: Disable LTO on _freeze_module and _testembed (#109581)"

This reverts commit 3e3a7da590e1c3e5f03802e538f26c5204889c82.

2 years agogh-104169: Refactor tokenizer into lexer and wrappers (#110684)
Lysandros Nikolaou [Wed, 11 Oct 2023 15:14:44 +0000 (17:14 +0200)] 
gh-104169: Refactor tokenizer into lexer and wrappers (#110684)

* The lexer, which include the actual lexeme producing logic, goes into
  the `lexer` directory.
* The wrappers, one wrapper per input mode (file, string, utf-8, and
  readline), go into the `tokenizer` directory and include logic for
  creating a lexer instance and managing the buffer for different modes.
---------

Co-authored-by: Pablo Galindo <pablogsal@gmail.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2 years agogh-110289: C API: Add PyUnicode_EqualToUTF8() and PyUnicode_EqualToUTF8AndSize()...
Serhiy Storchaka [Wed, 11 Oct 2023 13:41:58 +0000 (16:41 +0300)] 
gh-110289: C API: Add PyUnicode_EqualToUTF8() and PyUnicode_EqualToUTF8AndSize() functions (GH-110297)

2 years agoGH-107518: Remove the Argument Clinic How-To (#109900)
Adam Turner [Wed, 11 Oct 2023 12:57:51 +0000 (13:57 +0100)] 
GH-107518: Remove the Argument Clinic How-To (#109900)

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

2 years agogh-84489: Properly handle trailing spaces in Py_BuildValue() format strings (GH-21158)
Zackery Spytz [Wed, 11 Oct 2023 11:44:06 +0000 (04:44 -0700)] 
gh-84489: Properly handle trailing spaces in Py_BuildValue() format strings (GH-21158)

The docs state that the space, tab, colon, and comma characters are
ignored in Py_BuildValue() format strings.

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2 years ago gh-76106: Remove the cleanup lock in test_socket (GH-110539)
Serhiy Storchaka [Wed, 11 Oct 2023 10:52:06 +0000 (13:52 +0300)] 
 gh-76106: Remove the cleanup lock in test_socket  (GH-110539)

It does not already work (because it locks only addCleanup(), not doCleanups()),
and it is no longer needed since the clean up procedure waits for all test threads to join.

2 years agogh-84489: C API: Add tests for Py_BuildValue() (GH-110596)
Serhiy Storchaka [Wed, 11 Oct 2023 07:08:51 +0000 (10:08 +0300)] 
gh-84489: C API: Add tests for Py_BuildValue() (GH-110596)

2 years agogh-110631: fix wrong indentation in the `Doc/whatsnew` dir (#110632)
Ezio Melotti [Wed, 11 Oct 2023 05:34:38 +0000 (07:34 +0200)] 
gh-110631: fix wrong indentation in the `Doc/whatsnew` dir (#110632)

Fix wrong indentation in the Doc/whatsnew dir.

2 years agoGH-110488: Fix two small issues in `pathlib.PurePath.with_name()` (#110651)
Barney Gale [Wed, 11 Oct 2023 03:45:11 +0000 (04:45 +0100)] 
GH-110488: Fix two small issues in `pathlib.PurePath.with_name()` (#110651)

Ensure that `PurePath('foo/a').with_name('.')` raises `ValueError`

Ensure that `PureWindowsPath('foo/a').with_name('a:b')` does not raise
`ValueError`.

2 years agogh-110662: multiprocessing test_async_timeout() increase timeout (#110663)
Victor Stinner [Wed, 11 Oct 2023 02:36:06 +0000 (04:36 +0200)] 
gh-110662: multiprocessing test_async_timeout() increase timeout (#110663)

Increase timeout from 1 second to 30 seconds, if not longer. The
important part is that apply_async() takes longer than TIMEOUT2.

2 years agogh-110666: Fix multiprocessing test_terminate() elapsed (#110667)
Victor Stinner [Wed, 11 Oct 2023 01:49:09 +0000 (03:49 +0200)] 
gh-110666: Fix multiprocessing test_terminate() elapsed (#110667)

multiprocessing test_terminate() and test_wait_socket_slow() no
longer test the CI performance: no longer check maximum elapsed time.

Add CLOCK_RES constant: tolerate a difference of 100 ms.

2 years agogh-110656: Fix logging test_post_fork_child_no_deadlock() if ASAN (#110657)
Victor Stinner [Wed, 11 Oct 2023 00:57:53 +0000 (02:57 +0200)] 
gh-110656: Fix logging test_post_fork_child_no_deadlock() if ASAN (#110657)

Skip test_post_fork_child_no_deadlock() if Python is built with ASAN.

Add support.HAVE_ASAN_FORK_BUG.

2 years agogh-108277: test_os tolerates 1 ms diff for timerfd (#110661)
Victor Stinner [Wed, 11 Oct 2023 00:38:04 +0000 (02:38 +0200)] 
gh-108277: test_os tolerates 1 ms diff for timerfd (#110661)

2 years agogh-110647: Fix signal test_stress_modifying_handlers() (#110650)
Victor Stinner [Tue, 10 Oct 2023 23:59:43 +0000 (01:59 +0200)] 
gh-110647: Fix signal test_stress_modifying_handlers() (#110650)

* cycle_handlers() now waits until at least one signal is received.
* num_received_signals can be equal to num_sent_signals.

2 years agoGH-110109: Simplify pathlib test setup (#110308)
Barney Gale [Tue, 10 Oct 2023 23:03:42 +0000 (00:03 +0100)] 
GH-110109: Simplify pathlib test setup (#110308)

Use the class under test to create files, directories and symlinks.

2 years agogh-108826: Document `dis` module CLI and rename `_test` function to `main` (#108827)
Radislav Chugunov [Tue, 10 Oct 2023 22:31:28 +0000 (01:31 +0300)] 
gh-108826: Document `dis` module CLI and rename `_test` function to `main` (#108827)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2 years agogh-108303: Move all inspect test files to `test_inspect/` (#109607)
Nikita Sobolev [Tue, 10 Oct 2023 20:15:11 +0000 (23:15 +0300)] 
gh-108303: Move all inspect test files to `test_inspect/` (#109607)

2 years agogh-110525: Add tests for internal `set` CAPI (GH-110630)
Nikita Sobolev [Tue, 10 Oct 2023 16:00:05 +0000 (19:00 +0300)] 
gh-110525: Add tests for internal `set` CAPI (GH-110630)

2 years agogh-110631: Set three-space indents for reST in EditorConfig (#110635)
Hugo van Kemenade [Tue, 10 Oct 2023 14:36:19 +0000 (16:36 +0200)] 
gh-110631: Set three-space indents for reST in EditorConfig (#110635)

Set three-space indents in EditorConfig

2 years agogh-109693: Update pycore_interp.h to use pyatomic.h (#110604)
Donghee Na [Tue, 10 Oct 2023 14:17:08 +0000 (23:17 +0900)] 
gh-109693: Update pycore_interp.h to use pyatomic.h (#110604)

2 years agoGH-109408: Move the C file whitespace check from patchcheck to pre-commit (#109890)
Adam Turner [Tue, 10 Oct 2023 13:40:08 +0000 (14:40 +0100)] 
GH-109408: Move the C file whitespace check from patchcheck to pre-commit (#109890)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2 years agoDon't doubly-parallelise sphinx-lint (#110617)
Adam Turner [Tue, 10 Oct 2023 12:51:20 +0000 (13:51 +0100)] 
Don't doubly-parallelise sphinx-lint (#110617)

2 years agogh-110050: Adjust the newline position in the TypeError message of the random.seed...
Yilei Yang [Tue, 10 Oct 2023 12:16:26 +0000 (05:16 -0700)] 
gh-110050: Adjust the newline position in the TypeError message of the random.seed call. (#110051)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2 years agogh-101100: Fix sphinx warnings in `library/socketserver.rst` (GH-110207)
Nikita Sobolev [Tue, 10 Oct 2023 11:44:19 +0000 (14:44 +0300)] 
gh-101100: Fix sphinx warnings in `library/socketserver.rst` (GH-110207)

2 years agogh-110388: Add tests for tty (GH-110394)
Serhiy Storchaka [Tue, 10 Oct 2023 11:42:25 +0000 (14:42 +0300)] 
gh-110388: Add tests for tty (GH-110394)

2 years agogh-81002: Add tests for termios (GH-110386)
Serhiy Storchaka [Tue, 10 Oct 2023 11:35:15 +0000 (14:35 +0300)] 
gh-81002: Add tests for termios (GH-110386)

2 years agogh-110590: Fix a bug where _sre.compile would overwrite exceptions (#110591)
Nikita Sobolev [Tue, 10 Oct 2023 10:15:12 +0000 (13:15 +0300)] 
gh-110590: Fix a bug where _sre.compile would overwrite exceptions (#110591)

TypeError would be overwritten by OverflowError
if 'code' param contained non-ints.

2 years agogh-109595: Add -Xcpu_count=<n> cmdline for container users (#109667)
Donghee Na [Tue, 10 Oct 2023 10:00:09 +0000 (19:00 +0900)] 
gh-109595: Add -Xcpu_count=<n> cmdline for container users (#109667)

---------

Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Gregory P. Smith [Google LLC] <greg@krypto.org>
2 years agogh-110378: Fix test_async_gen_propagates_generator_exit in test_contextlib_async...
Serhiy Storchaka [Tue, 10 Oct 2023 09:38:40 +0000 (12:38 +0300)] 
gh-110378: Fix test_async_gen_propagates_generator_exit in test_contextlib_async (#110500)

It now fails if the original bug is not fixed, and no longer produce ResourceWarning with fixed code.

2 years agogh-110558: Enable ruff's pyupgrade rules when running on Argument Clinic (#110603)
Alex Waygood [Tue, 10 Oct 2023 09:35:36 +0000 (11:35 +0200)] 
gh-110558: Enable ruff's pyupgrade rules when running on Argument Clinic (#110603)

2 years agogh-84570: Implement Waiting in SendChannel.send() (gh-110565)
Eric Snow [Tue, 10 Oct 2023 09:35:14 +0000 (03:35 -0600)] 
gh-84570: Implement Waiting in SendChannel.send() (gh-110565)

We had been faking it (poorly).

We will add timeouts separately.

2 years agogh-107652: Fix CIFuzz typo (#110602)
Nikita Sobolev [Tue, 10 Oct 2023 09:34:48 +0000 (12:34 +0300)] 
gh-107652: Fix CIFuzz typo (#110602)

2 years agoGH-109408: Move the Python file whitespace check from patchcheck to pre-commit (...
Adam Turner [Tue, 10 Oct 2023 09:17:53 +0000 (10:17 +0100)] 
GH-109408: Move the Python file whitespace check from patchcheck to pre-commit (#109891)

Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
2 years agoRemove an old macro from executor.c (#110597)
Brandt Bucher [Tue, 10 Oct 2023 08:45:23 +0000 (10:45 +0200)] 
Remove an old macro from executor.c (#110597)

2 years agoGH-104584: Fix refleak when tracing through calls (GH-110593)
Brandt Bucher [Tue, 10 Oct 2023 08:29:48 +0000 (10:29 +0200)] 
GH-104584: Fix refleak when tracing through calls (GH-110593)

2 years agoAdd some 'meta hooks' to our pre-commit config (#110587)
Alex Waygood [Tue, 10 Oct 2023 08:21:58 +0000 (10:21 +0200)] 
Add some 'meta hooks' to our pre-commit config (#110587)

2 years agogh-109408: Add the docs whitespace check from patchcheck to pre-commit (#109854)
Hugo van Kemenade [Tue, 10 Oct 2023 08:11:51 +0000 (10:11 +0200)] 
gh-109408: Add the docs whitespace check from patchcheck to pre-commit (#109854)

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2 years agogh-110558: Run ruff on Argument Clinic in CI (#110559)
Alex Waygood [Tue, 10 Oct 2023 07:52:39 +0000 (09:52 +0200)] 
gh-110558: Run ruff on Argument Clinic in CI (#110559)

2 years agogh-110378: Close invalid generators in contextmanager and asynccontextmanager (GH...
Serhiy Storchaka [Tue, 10 Oct 2023 07:43:04 +0000 (10:43 +0300)] 
gh-110378: Close invalid generators in contextmanager and asynccontextmanager (GH-110499)

contextmanager and asynccontextmanager context managers now close an invalid
underlying generator object that yields more then one value.

2 years agoFix CIFuzz build (#110576)
Nikita Sobolev [Tue, 10 Oct 2023 06:44:57 +0000 (09:44 +0300)] 
Fix CIFuzz build (#110576)

2 years agogh-109693: Use pyatomic.h for signal module (gh-110480)
Donghee Na [Mon, 9 Oct 2023 23:26:29 +0000 (08:26 +0900)] 
gh-109693: Use pyatomic.h for signal module (gh-110480)