]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
3 years agobpo-46306: simplify `CodeType` attribute access in `doctest.py` (GH-30481)
Nikita Sobolev [Sat, 8 Jan 2022 20:13:42 +0000 (23:13 +0300)] 
bpo-46306: simplify `CodeType` attribute access in `doctest.py` (GH-30481)

Assume co_firstlineno always exists on types.CodeType objects.

Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com>
3 years agobpo-46301: [Enum] test uncomparable values in `_convert_` (GH-30472)
Nikita Sobolev [Sat, 8 Jan 2022 19:43:42 +0000 (22:43 +0300)] 
bpo-46301: [Enum] test uncomparable values in `_convert_` (GH-30472)

add tests that cover different types, and same non-comparable types

3 years agobpo-46261: Update `sqlite3.Cursor.lastrowid` docs (GH-30407)
Erlend Egeberg Aasland [Sat, 8 Jan 2022 19:17:09 +0000 (20:17 +0100)] 
bpo-46261: Update `sqlite3.Cursor.lastrowid` docs (GH-30407)

3 years agobpo-46290: Fix parameter names in dataclasses docs (GH-30450)
Zsolt Dollenstein [Sat, 8 Jan 2022 10:56:35 +0000 (10:56 +0000)] 
bpo-46290: Fix parameter names in dataclasses docs (GH-30450)

3 years agobpo-46299: Improve test_descr (GH-30475)
Dong-hee Na [Sat, 8 Jan 2022 08:14:40 +0000 (17:14 +0900)] 
bpo-46299: Improve test_descr (GH-30475)

3 years agobpo-46299: improve `test_descr.py` with stricter error handling (GH-30471)
Nikita Sobolev [Sat, 8 Jan 2022 03:51:51 +0000 (06:51 +0300)] 
bpo-46299: improve `test_descr.py` with stricter error handling (GH-30471)

3 years agobpo-46235: Do all ref-counting at once during list/tuple multiplication (GH-30346)
Dennis Sweeney [Sat, 8 Jan 2022 03:47:58 +0000 (22:47 -0500)] 
bpo-46235: Do all ref-counting at once during list/tuple multiplication (GH-30346)

When multiplying lists and tuples by `n`, increment each element's refcount, by `n`, just once.

Saves `n-1` increments per element, and allows for a leaner & faster copying loop.

Code by  sweeneyde (Dennis Sweeney).

3 years agobpo-46237: Fix the line number of tokenizer errors inside f-strings (GH-30463)
Pablo Galindo Salgado [Sat, 8 Jan 2022 00:23:40 +0000 (00:23 +0000)] 
bpo-46237: Fix the line number of tokenizer errors inside f-strings (GH-30463)

3 years agobpo-46217: Revert use of Windows constant that is newer than what we support (GH...
Steve Dower [Sat, 8 Jan 2022 00:06:53 +0000 (00:06 +0000)] 
bpo-46217: Revert use of Windows constant that is newer than what we support (GH-30473)

3 years agobpo-46297: Fix interpreter crash on startup with multiple PythonPaths set in registry...
Daniel [Fri, 7 Jan 2022 22:26:00 +0000 (00:26 +0200)] 
bpo-46297: Fix interpreter crash on startup with multiple PythonPaths set in registry (GH-30466)

3 years agobpo-46296: [Enum] add a test for missing `value` recovery (GH-30458)
Nikita Sobolev [Fri, 7 Jan 2022 21:44:21 +0000 (00:44 +0300)] 
bpo-46296: [Enum] add a test for missing `value` recovery (GH-30458)

In `__set_name__` there is a check for the `_value_` attribute and an attempt to add it if missing; this adds a test to cover the case for simple enums with a custom `__new__` method.

3 years agobpo-46289: Make conversion of FormattedValue not optional on ASDL (GH-30467)
Batuhan Taskaya [Fri, 7 Jan 2022 21:05:28 +0000 (00:05 +0300)] 
bpo-46289: Make conversion of FormattedValue not optional on ASDL (GH-30467)

Automerge-Triggered-By: GH:isidentical
3 years agobpo-28546: [doc] Clarify setting pdb breakpoints (GH-30360)
Hugo van Kemenade [Fri, 7 Jan 2022 19:41:23 +0000 (21:41 +0200)] 
bpo-28546: [doc] Clarify setting pdb breakpoints (GH-30360)

Co-authored-by: Ian Kelling <ian@iankelling.org>
3 years agobpo-24650: Use full term "generator function" in yield expressions docs (GH-24663)
Jacob Walls [Fri, 7 Jan 2022 18:39:40 +0000 (13:39 -0500)] 
bpo-24650: Use full term "generator function" in yield expressions docs (GH-24663)

3 years agobpo-46216: remove spurious link to os.system() from os.time() documentation (GH-30326)
Irit Katriel [Fri, 7 Jan 2022 18:28:08 +0000 (18:28 +0000)] 
bpo-46216: remove spurious link to os.system() from os.time() documentation (GH-30326)

Automerge-Triggered-By: GH:iritkatriel
3 years agobpo-46070: Fix asyncio initialisation guard (GH-30423)
Erlend Egeberg Aasland [Fri, 7 Jan 2022 14:08:19 +0000 (15:08 +0100)] 
bpo-46070: Fix asyncio initialisation guard (GH-30423)

If init flag is set, exit successfully immediately.
If not, only set the flag after successful initialization.

3 years agobpo-45723: Fix detection of epoll (#30449)
Christian Heimes [Fri, 7 Jan 2022 08:15:20 +0000 (10:15 +0200)] 
bpo-45723: Fix detection of epoll (#30449)

3 years agobpo-41011: venv -- add more variables to pyvenv.cfg (GH-30382)
andrei kulakov [Fri, 7 Jan 2022 06:50:30 +0000 (01:50 -0500)] 
bpo-41011: venv -- add more variables to pyvenv.cfg (GH-30382)

3 years agobpo-46251: Add 'Security Considerations' section to logging configura… (GH-30411)
Vinay Sajip [Thu, 6 Jan 2022 22:35:08 +0000 (22:35 +0000)] 
bpo-46251: Add 'Security Considerations' section to logging configura… (GH-30411)

3 years agobpo-46263: Fix second location that needs MALLOC_CONF on FreeBSD (GH-30440)
Christian Heimes [Thu, 6 Jan 2022 19:49:03 +0000 (21:49 +0200)] 
bpo-46263: Fix second location that needs MALLOC_CONF on FreeBSD (GH-30440)

Automerge-Triggered-By: GH:tiran
3 years agobpo-46286: use the new POP_JUMP_IF_NOT_NONE opcode to simplify except* (GH-30439)
Irit Katriel [Thu, 6 Jan 2022 19:43:16 +0000 (19:43 +0000)] 
bpo-46286: use the new POP_JUMP_IF_NOT_NONE opcode to simplify except* (GH-30439)

Automerge-Triggered-By: GH:iritkatriel
3 years agobpo-46208: Fix normalization of relative paths in _Py_normpath()/os.path.normpath...
neonene [Thu, 6 Jan 2022 19:13:10 +0000 (04:13 +0900)] 
bpo-46208: Fix normalization of relative paths in _Py_normpath()/os.path.normpath (GH-30362)

3 years agobpo-45292: [PEP-654] exception groups and except* documentation (GH-30158)
Irit Katriel [Thu, 6 Jan 2022 19:05:34 +0000 (19:05 +0000)] 
bpo-45292: [PEP-654] exception groups and except* documentation (GH-30158)

3 years agobpo-46263: Do not ever expect "use_frozen_modules" to be -1. (gh-30438)
Eric Snow [Thu, 6 Jan 2022 18:56:13 +0000 (11:56 -0700)] 
bpo-46263: Do not ever expect "use_frozen_modules" to be -1. (gh-30438)

The condition is no longer valid.  This should resolve the buildbot failure on FreeBSD.

https://bugs.python.org/issue46263

3 years agobpo-46263: FreeBSD 14.0 jemalloc workaround for junk bytes of freed memory (GH-30434)
Christian Heimes [Thu, 6 Jan 2022 15:14:49 +0000 (17:14 +0200)] 
bpo-46263: FreeBSD 14.0 jemalloc workaround for junk bytes of freed memory (GH-30434)

Automerge-Triggered-By: GH:tiran
3 years agobpo-46278: fix typo introduced in GH-30427 (GH-30430)
Kumar Aditya [Thu, 6 Jan 2022 13:21:24 +0000 (18:51 +0530)] 
bpo-46278: fix typo introduced in GH-30427 (GH-30430)

Automerge-Triggered-By: GH:asvetlov
3 years agobpo-45923: Handle call events in bytecode (GH-30364)
Mark Shannon [Thu, 6 Jan 2022 13:09:25 +0000 (13:09 +0000)] 
bpo-45923: Handle call events in bytecode (GH-30364)

* Add a RESUME instruction to handle "call" events.

3 years agoReflect 'context' arg in 'AbstractEventLoop.call_*()' methods (GH-30427)
Andrew Svetlov [Thu, 6 Jan 2022 12:31:32 +0000 (14:31 +0200)] 
Reflect 'context' arg in 'AbstractEventLoop.call_*()' methods (GH-30427)

3 years agobpo-46031: add POP_JUMP_IF_NOT_NONE and POP_JUMP_IF_NONE (GH-30019)
penguin_wwy [Thu, 6 Jan 2022 11:38:35 +0000 (19:38 +0800)] 
bpo-46031: add POP_JUMP_IF_NOT_NONE and POP_JUMP_IF_NONE (GH-30019)

3 years agobpo-46006: Revert "bpo-40521: Per-interpreter interned strings (GH-20085)" (GH-30422)
Victor Stinner [Thu, 6 Jan 2022 07:53:44 +0000 (08:53 +0100)] 
bpo-46006: Revert "bpo-40521: Per-interpreter interned strings (GH-20085)" (GH-30422)

This reverts commit ea251806b8dffff11b30d2182af1e589caf88acf.

Keep "assert(interned == NULL);" in _PyUnicode_Fini(), but only for
the main interpreter.

Keep _PyUnicode_ClearInterned() changes avoiding the creation of a
temporary Python list object.

3 years agobpo-46266: Add calendar day of week constants to __all__ (GH-30412)
Nikita Sobolev [Wed, 5 Jan 2022 20:21:04 +0000 (23:21 +0300)] 
bpo-46266:  Add calendar day of week constants to __all__  (GH-30412)

3 years agobpo-46269: [Enum] remove special-casing of `__new__` in `EnumType.__dir__` (GH-30421)
Nikita Sobolev [Wed, 5 Jan 2022 17:06:02 +0000 (20:06 +0300)] 
bpo-46269: [Enum] remove special-casing of `__new__` in `EnumType.__dir__` (GH-30421)

3 years agobpo-46257: Convert statistics._ss() to a single pass algorithm (GH-30403)
Raymond Hettinger [Wed, 5 Jan 2022 15:39:10 +0000 (07:39 -0800)] 
bpo-46257: Convert statistics._ss() to a single pass algorithm (GH-30403)

3 years agobpo-46236: Fix PyFunction_GetAnnotations() returned tuple. (GH-30409)
Inada Naoki [Wed, 5 Jan 2022 12:25:54 +0000 (21:25 +0900)] 
bpo-46236: Fix PyFunction_GetAnnotations() returned tuple. (GH-30409)

Automerge-Triggered-By: GH:pablogsal
3 years agobpo-43137: Revert "webbrowser: Don't run gvfs-open on GNOME" (GH-30417)
Simon McVittie [Wed, 5 Jan 2022 11:53:23 +0000 (11:53 +0000)] 
bpo-43137: Revert "webbrowser: Don't run gvfs-open on GNOME" (GH-30417)

gvfs-open was deprecated in 2015 and removed in 2018, but its replacement,
gio(1), is not available in Ubuntu 16.04, which is apparently still
supported by CPython upstream even though it is considered to be EOL by
Ubuntu developers.

Signed-off-by: Simon McVittie <smcv@debian.org>
3 years agobpo-45256: Don't track the exact depth of each `InterpreterFrame` (GH-30372)
Brandt Bucher [Wed, 5 Jan 2022 11:30:26 +0000 (03:30 -0800)] 
bpo-45256: Don't track the exact depth of each `InterpreterFrame` (GH-30372)

3 years agobpo-46263: Don't use MULTIARCH on FreeBSD (#30410)
Christian Heimes [Wed, 5 Jan 2022 09:54:17 +0000 (11:54 +0200)] 
bpo-46263: Don't use MULTIARCH on FreeBSD (#30410)

3 years agobpo-46262: [Enum] test error path in `Flag._missing_` (GH-30408)
Nikita Sobolev [Wed, 5 Jan 2022 00:11:06 +0000 (03:11 +0300)] 
bpo-46262: [Enum] test error path in `Flag._missing_` (GH-30408)

add tests that exercise the `_missing_` error path for `Flag` and `IntFlag`

Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
3 years agobpo-46009: Remove GEN_START (GH-30367)
Brandt Bucher [Tue, 4 Jan 2022 19:38:32 +0000 (11:38 -0800)] 
bpo-46009: Remove GEN_START (GH-30367)

3 years agoFix missing "," in the documentation of Executor Objects (GH-30404)
Philipp Claßen [Tue, 4 Jan 2022 18:48:04 +0000 (19:48 +0100)] 
Fix missing "," in the documentation of Executor Objects (GH-30404)

3 years agobpo-45609: More specialization stats for STORE_SUBSCR (GH-30193)
Dennis Sweeney [Tue, 4 Jan 2022 18:05:09 +0000 (13:05 -0500)] 
bpo-45609: More specialization stats for STORE_SUBSCR (GH-30193)

3 years agobpo-20369: concurrent.futures.wait() now deduplicates futures given a… (GH-30168)
Kumar Aditya [Tue, 4 Jan 2022 13:36:13 +0000 (19:06 +0530)] 
bpo-20369: concurrent.futures.wait() now deduplicates futures given a… (GH-30168)

* bpo-20369: concurrent.futures.wait() now deduplicates futures given as arg.

* 📜🤖 Added by blurb_it.

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
3 years agobpo-33252: Document that ResourceWarning is ignored by default (GH-30358)
Hugo van Kemenade [Tue, 4 Jan 2022 11:34:31 +0000 (13:34 +0200)] 
bpo-33252: Document that ResourceWarning is ignored by default (GH-30358)

`ResourceWarning` is ignored by default.

Document this behaviour, for consistency with others in this table such as `DeprecationWarning`.

Documentation PR can skip NEWS file.

Automerge-Triggered-By: GH:iritkatriel
3 years agobpo-46231: Remove invalid_* rules preceded by more tokens from the grammar docs ...
Pablo Galindo Salgado [Tue, 4 Jan 2022 10:42:15 +0000 (10:42 +0000)] 
bpo-46231: Remove invalid_* rules preceded by more tokens from the grammar docs (GH-30341)

3 years agobpo-46240: Correct the error for unclosed parentheses when the tokenizer is not finis...
Pablo Galindo Salgado [Tue, 4 Jan 2022 10:41:22 +0000 (10:41 +0000)] 
bpo-46240: Correct the error for unclosed parentheses when the tokenizer is not finished (GH-30378)

3 years agobpo-46202: Remove opcode POP_EXCEPT_AND_RERAISE (GH-30302)
Irit Katriel [Tue, 4 Jan 2022 10:37:12 +0000 (10:37 +0000)] 
bpo-46202: Remove opcode POP_EXCEPT_AND_RERAISE (GH-30302)

* bpo-46202: remove opcode POP_EXCEPT_AND_RERAISE

* do not assume that an exception group is truthy

3 years agobpo-44092: Move What's New entry to where it belongs (GH-30381)
Erlend Egeberg Aasland [Tue, 4 Jan 2022 09:36:30 +0000 (10:36 +0100)] 
bpo-44092: Move What's New entry to where it belongs (GH-30381)

3 years agoUpdate old-style strings to f-strings (GH-30384)
David Gilbertson [Tue, 4 Jan 2022 09:25:56 +0000 (20:25 +1100)] 
Update old-style strings to f-strings (GH-30384)

Let me know if this sort of change is unwanted...

3 years agobpo-46239: improve error message when importing `asyncio.windows_events` (GH-30353)
Nikita Sobolev [Tue, 4 Jan 2022 08:44:26 +0000 (11:44 +0300)] 
bpo-46239: improve error message when importing `asyncio.windows_events` (GH-30353)

3 years agobpo-46238: reuse `_winapi` constants in `asyncio.windows_events` (GH-30352)
Nikita Sobolev [Tue, 4 Jan 2022 08:42:19 +0000 (11:42 +0300)] 
bpo-46238: reuse `_winapi` constants in `asyncio.windows_events` (GH-30352)

3 years agobpo-46233: Minor speedup for bigint squaring (GH-30345)
Tim Peters [Tue, 4 Jan 2022 02:41:16 +0000 (20:41 -0600)] 
bpo-46233: Minor speedup for bigint squaring (GH-30345)

x_mul()'s squaring code can do some redundant and/or useless
work at the end of each digit pass. A more careful analysis
of worst-case carries at various digit positions allows
making that code leaner.

3 years agobpo-44092: Remove unused member `reset` from `sqlite3.Cursor` (GH-30377)
Erlend Egeberg Aasland [Mon, 3 Jan 2022 23:47:16 +0000 (00:47 +0100)] 
bpo-44092: Remove unused member `reset` from `sqlite3.Cursor` (GH-30377)

Automerge-Triggered-By: GH:pablogsal
3 years agobpo-34538: Remove Exception subclassing from tutorial (GH-30361)
Hugo van Kemenade [Mon, 3 Jan 2022 22:52:09 +0000 (00:52 +0200)] 
bpo-34538: Remove Exception subclassing from tutorial (GH-30361)

Remove the bit about subclassing exceptions.

Documentation PR can skip the NEWS label.

Automerge-Triggered-By: GH:iritkatriel
3 years agoAdd doctest and improve readability for move_to_end() example. (#30370)
Raymond Hettinger [Mon, 3 Jan 2022 22:26:08 +0000 (14:26 -0800)] 
Add doctest and improve readability for move_to_end() example. (#30370)

3 years agobpo-34931: [doc] clarify behavior of os.path.splitext() on paths with multiple leadin...
Irit Katriel [Mon, 3 Jan 2022 20:10:07 +0000 (20:10 +0000)] 
bpo-34931: [doc] clarify behavior of os.path.splitext() on paths with multiple leading periods (GH-30347)

3 years agobpo-46110: Restore commit e9898bf153d26059261ffef11f7643ae991e2a4c
Pablo Galindo Salgado [Mon, 3 Jan 2022 19:54:06 +0000 (19:54 +0000)] 
bpo-46110: Restore commit e9898bf153d26059261ffef11f7643ae991e2a4c

This restores commit e9898bf153d26059261ffef11f7643ae991e2a4c .

3 years agobpo-44092: Don't reset statements/cursors before rollback (GH-26026)
Erlend Egeberg Aasland [Mon, 3 Jan 2022 19:02:39 +0000 (20:02 +0100)] 
bpo-44092: Don't reset statements/cursors before rollback (GH-26026)

In SQLite versions pre 3.7.11, pending statements would block a rollback.  This is no longer the case, so remove the workaround.

3 years agoRevert "bpo-46110: Add a recursion check to avoid stack overflow in the PEG parser...
Pablo Galindo Salgado [Mon, 3 Jan 2022 18:29:18 +0000 (18:29 +0000)] 
Revert "bpo-46110: Add a recursion check to avoid stack overflow in the PEG parser (GH-30177)" (GH-30363)

This reverts commit e9898bf153d26059261ffef11f7643ae991e2a4c temporarily as we want to confirm if this commit is the cause of a slowdown at startup time.

3 years agobpo-46222: posixmodule sendfile FreeBSD's constants updates. (GH-30327)
David CARLIER [Mon, 3 Jan 2022 13:01:04 +0000 (13:01 +0000)] 
bpo-46222: posixmodule sendfile FreeBSD's constants updates. (GH-30327)

* posixodule sendfile FreeBSD's constants updates.

* 📜🤖 Added by blurb_it.

Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
3 years agobpo-40477: macOS Python Launcher app fixes for recent macOS releases (GH-30348)
Ned Deily [Mon, 3 Jan 2022 06:19:59 +0000 (01:19 -0500)] 
bpo-40477: macOS Python Launcher app fixes for recent macOS releases (GH-30348)

This change solves two problems encountered by users of the macOS Python Launcher app on recent macOS releases (10.14+):

- The launcher app was no longer able to launch the macOS Terminal.app to run a script.

- Even if Terminal.app was already launched, the launcher app was unable to send an Apple Event to Terminal.app to open and run Python with the desired .py file.

3 years agobpo-46229: remove `CODE_OF_CONDUCT.md` to use org default (GH-30342)
Nikita Sobolev [Sun, 2 Jan 2022 23:30:54 +0000 (02:30 +0300)] 
bpo-46229: remove `CODE_OF_CONDUCT.md` to use org default (GH-30342)

Automerge-Triggered-By: GH:Mariatta
3 years agobpo-46219, 46221: simplify except* implementation following exc_info changes. Move...
Irit Katriel [Sun, 2 Jan 2022 23:22:42 +0000 (23:22 +0000)] 
bpo-46219, 46221: simplify except* implementation following exc_info changes. Move helpers to exceptions.c. Do not assume that exception groups are truthy. (GH-30289)

3 years agoargparse docs: prog default is the basename of argv[0] (GH-30298)
Jade Lovelace [Sun, 2 Jan 2022 20:16:25 +0000 (12:16 -0800)] 
argparse docs: prog default is the basename of argv[0] (GH-30298)

3 years agoUpdate copyright year to 2022. (GH-30335)
Benjamin Peterson [Sun, 2 Jan 2022 20:08:48 +0000 (14:08 -0600)] 
Update copyright year to 2022. (GH-30335)

Automerge-Triggered-By: GH:benjaminp
3 years agobpo-46218: Change long_pow() to sliding window algorithm (GH-30319)
Tim Peters [Sun, 2 Jan 2022 19:18:20 +0000 (13:18 -0600)] 
bpo-46218: Change long_pow() to sliding window algorithm (GH-30319)

* bpo-46218: Change long_pow() to sliding window algorithm

The primary motivation is to eliminate long_pow's reliance on that the number of bits in a long "digit" is a multiple of 5. Now it no longer cares how many bits are in a digit.

But the sliding window approach also allows cutting the precomputed table of small powers in half, which reduces initialization overhead enough that the approach pays off for smaller exponents too. Depending on exponent bit patterns, a sliding window may also be able to save some bigint multiplies (sometimes when at least 5 consecutive exponent bits are 0, regardless of their starting bit position modulo 5).

Note: boosting the window width to 6 didn't work well overall. It give marginal speed improvements for huge exponents, but the increased overhead (the small-power table needs twice as many entries) made it a loss for smaller exponents.

Co-authored-by: Oleg Iarygin <dralife@yandex.ru>
3 years agobpo-46196: document method cmd.Cmd.columnize (#30303)
Nikita Sobolev [Sun, 2 Jan 2022 18:33:20 +0000 (21:33 +0300)] 
bpo-46196: document method cmd.Cmd.columnize (#30303)

The method is already written and tested, now it's officially public.

3 years agobpo-45903: Fix typo in What's New: Signature.from_builtin is removed (GH-29813)
Hugo van Kemenade [Sun, 2 Jan 2022 16:51:56 +0000 (18:51 +0200)] 
bpo-45903: Fix typo in What's New: Signature.from_builtin is removed (GH-29813)

3 years agobpo-45615: Add missing test for printing traceback for non-exception. Fix traceback... 30340/head
Irit Katriel [Sun, 2 Jan 2022 09:34:03 +0000 (09:34 +0000)] 
bpo-45615: Add missing test for printing traceback for non-exception. Fix traceback.py (GH-30091)

3 years agobpo-46095: Improve SeqIter documentation. (GH-30316)
Raymond Hettinger [Sat, 1 Jan 2022 18:37:26 +0000 (10:37 -0800)] 
bpo-46095: Improve SeqIter documentation. (GH-30316)

3 years agobpo-46079: Replace external link that is down for maintenance. (GH-30315)
Raymond Hettinger [Sat, 1 Jan 2022 17:49:55 +0000 (09:49 -0800)] 
bpo-46079: Replace external link that is down for maintenance. (GH-30315)

3 years agobpo-37295: More direct computation of power-of-two factor in math.comb (GH-30313)
Mark Dickinson [Fri, 31 Dec 2021 19:52:27 +0000 (19:52 +0000)] 
bpo-37295: More direct computation of power-of-two factor in math.comb (GH-30313)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
3 years agobpo-45321: Add missing error codes to module `xml.parsers.expat.errors` (GH-30188)
Sebastian Pipping [Fri, 31 Dec 2021 09:57:00 +0000 (10:57 +0100)] 
bpo-45321: Add missing error codes to module `xml.parsers.expat.errors` (GH-30188)

The idea is to ensure that module `xml.parsers.expat.errors`
contains all known error codes and messages,
even when CPython is compiled or run with an outdated version of libexpat.

https://bugs.python.org/issue45321

3 years agobpo-46118: Make sure importlib.resources is included. (GH-30311)
Jason R. Coombs [Fri, 31 Dec 2021 03:39:24 +0000 (22:39 -0500)] 
bpo-46118: Make sure importlib.resources is included. (GH-30311)

3 years agobpo-46109: Separate out files relating to importlib.resources (GH-30160)
Jason R. Coombs [Fri, 31 Dec 2021 02:17:05 +0000 (21:17 -0500)] 
bpo-46109: Separate out files relating to importlib.resources (GH-30160)

* Separate out files relating to importlib.resources

* Update Introduction to direct readers to the submodule documentation.

* Create separate file for abcs relating to resources.

* Move abc docs back to where they were.

3 years agobpo-46118: Move importlib.resources to its own package. (#30176)
Jason R. Coombs [Fri, 31 Dec 2021 02:00:48 +0000 (21:00 -0500)] 
bpo-46118: Move importlib.resources to its own package. (#30176)

* bpo-46118: Move importlib.resources to its own package.

* Expand compatibility shims with documentation and explicit imports.

3 years agobpo-46178: Remove/rename redundant Travis CI code (#30309)
Hugo van Kemenade [Fri, 31 Dec 2021 00:16:27 +0000 (02:16 +0200)] 
bpo-46178: Remove/rename redundant Travis CI code (#30309)

3 years agobpo-46178: remove unusued `.travis.yml` file (#30257)
Nikita Sobolev [Thu, 30 Dec 2021 21:26:01 +0000 (00:26 +0300)] 
bpo-46178: remove unusued `.travis.yml` file (#30257)

* bpo-46178: remove unusued `.travis.yml` file

* Delete 2021-12-26-12-35-41.bpo-46178.Aw1TZg.rst

3 years agobpo-46184: remove `netlify.toml` (#30272)
Nikita Sobolev [Thu, 30 Dec 2021 21:18:37 +0000 (00:18 +0300)] 
bpo-46184: remove `netlify.toml` (#30272)

* bpo-46184: remove `netlify.toml`

* Delete runtime.txt

* Delete requirements.txt

* Revert "Delete requirements.txt"

This reverts commit 9aa4f0631f9d206ed7fddf37b43a24ec4e90fa7c.

3 years agoDelete `FUNDING.yml`, since there's an organisation default (#30294)
Nikita Sobolev [Thu, 30 Dec 2021 20:24:46 +0000 (23:24 +0300)] 
Delete `FUNDING.yml`, since there's an organisation default (#30294)

3 years agobpo-45853: Fix misspelling and unused import in pathlib (GH-30292)
andrei kulakov [Thu, 30 Dec 2021 07:45:06 +0000 (02:45 -0500)] 
bpo-45853: Fix misspelling and unused import in pathlib (GH-30292)

3 years agobpo-46085: Fix iterator cache mechanism of OrderedDict. (GH-30290)
Dong-hee Na [Thu, 30 Dec 2021 03:35:45 +0000 (12:35 +0900)] 
bpo-46085: Fix iterator cache mechanism of OrderedDict. (GH-30290)

3 years agobpo-43424: Deprecate `webbrowser.MacOSXOSAScript._name` attribute (GH-30241)
Nikita Sobolev [Thu, 30 Dec 2021 01:30:13 +0000 (04:30 +0300)] 
bpo-43424: Deprecate `webbrowser.MacOSXOSAScript._name` attribute (GH-30241)

3 years agocloses docs: remove references to Py_USING_MEMORY_DEBUGGER (GH-30284)
Carlos Damazio [Wed, 29 Dec 2021 22:20:42 +0000 (19:20 -0300)] 
closes docs: remove references to Py_USING_MEMORY_DEBUGGER (GH-30284)

3 years agobpo-46185: Fix wrong version ref. in macOS installer ReadMe (GH-30278)
Erlend Egeberg Aasland [Wed, 29 Dec 2021 19:39:49 +0000 (20:39 +0100)] 
bpo-46185: Fix wrong version ref. in macOS installer ReadMe (GH-30278)

3 years agobpo-46176: mmap module adding MAP_STACK constant. (GH-30252)
David CARLIER [Wed, 29 Dec 2021 13:52:29 +0000 (13:52 +0000)] 
bpo-46176: mmap module adding MAP_STACK constant. (GH-30252)

3 years agobpo-46090: Allow PyThreadState.datastack_* members to be NULL (GH-30234)
Brandt Bucher [Tue, 28 Dec 2021 17:49:48 +0000 (09:49 -0800)] 
bpo-46090: Allow PyThreadState.datastack_* members to be NULL (GH-30234)

3 years agobpo-37295: Speed up math.comb(n, k) for 0 <= k <= n <= 67 (GH-30275)
Mark Dickinson [Tue, 28 Dec 2021 12:26:40 +0000 (12:26 +0000)] 
bpo-37295: Speed up math.comb(n, k) for 0 <= k <= n <= 67 (GH-30275)

3 years agobpo-45189: Drop the "list_frozen" command from _test_embed. (GH-30273)
Dong-hee Na [Tue, 28 Dec 2021 02:05:50 +0000 (11:05 +0900)] 
bpo-45189: Drop the "list_frozen" command from _test_embed. (GH-30273)

3 years agobpo-46055: Speed up binary shifting operators (GH-30044)
Xinhang Xu [Mon, 27 Dec 2021 18:36:55 +0000 (02:36 +0800)] 
bpo-46055: Speed up binary shifting operators (GH-30044)

Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
3 years agobpo-46055: Streamline inner loop for right shifts (#30243)
Mark Dickinson [Mon, 27 Dec 2021 18:04:36 +0000 (18:04 +0000)] 
bpo-46055: Streamline inner loop for right shifts (#30243)

3 years agobpo-45496: Allow flexibility in winfo_rgb tests (GH-30185)
E-Paine [Sun, 26 Dec 2021 11:28:24 +0000 (11:28 +0000)] 
bpo-45496: Allow flexibility in winfo_rgb tests (GH-30185)

3 years agobpo-43413: Revert changes in set.__init__ (GH-28403)
Serhiy Storchaka [Sun, 26 Dec 2021 11:27:01 +0000 (13:27 +0200)] 
bpo-43413: Revert changes in set.__init__ (GH-28403)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
3 years agobpo-22815: Print unexpected successes in summary in TextTestResult (GH-30138)
Serhiy Storchaka [Sun, 26 Dec 2021 11:22:44 +0000 (13:22 +0200)] 
bpo-22815: Print unexpected successes in summary in TextTestResult (GH-30138)

3 years agobpo-23819: Fix asyncio tests on python optimized mode (GH-30195)
Kumar Aditya [Sun, 26 Dec 2021 11:13:14 +0000 (16:43 +0530)] 
bpo-23819: Fix asyncio tests on python optimized mode (GH-30195)

3 years agoFix typo in io.rst (GH-30218)
David Gilbertson [Sun, 26 Dec 2021 11:11:08 +0000 (22:11 +1100)] 
Fix typo in io.rst (GH-30218)

3 years agodoc: fix a typo in unittest.mock.rst (GH-30227)
Joe [Sun, 26 Dec 2021 11:09:17 +0000 (19:09 +0800)] 
doc: fix a typo in unittest.mock.rst (GH-30227)

3 years agodocs: Fix typos and use anchor for internal link (GH-30236)
Rafael Fontenelle [Sun, 26 Dec 2021 10:43:06 +0000 (07:43 -0300)] 
docs: Fix typos and use anchor for internal link (GH-30236)

3 years agoRemove a NEWS entry for bpo-45878 (GH-30259)
Serhiy Storchaka [Sun, 26 Dec 2021 10:38:19 +0000 (12:38 +0200)] 
Remove a NEWS entry for bpo-45878 (GH-30259)

The docs linter complains about it, and in general news entries for such changes are not required.

3 years agobpo-46032: Check types in singledispatch's register() at declaration time (GH-30050)
Serhiy Storchaka [Sat, 25 Dec 2021 12:16:14 +0000 (14:16 +0200)] 
bpo-46032: Check types in singledispatch's register() at declaration time (GH-30050)

The registry() method of functools.singledispatch() functions checks now
the first argument or the first parameter annotation and raises a TypeError if it is
not supported. Previously unsupported "types" were ignored (e.g. typing.List[int])
or caused an error at calling time (e.g. list[int]).

3 years agobpo-46120: State that `|` is preferred over `Union` (GH-30222)
Nikita Sobolev [Fri, 24 Dec 2021 21:36:09 +0000 (00:36 +0300)] 
bpo-46120: State that `|` is preferred over `Union` (GH-30222)

Co-authored-by: Éric <merwok@netwok.org>
Co-authored-by: Guido van Rossum <gvanrossum@gmail.com>