summaryrefslogtreecommitdiffstats
path: root/Misc
Commit message (Collapse)AuthorAgeFilesLines
...
* gh-92930: _pickle.c: Acquire strong references before calling save() (GH-92931)Miss Islington (bot)2022-06-111-0/+1
| | | | | (cherry picked from commit 4c496f1f115a7910d4606b4de233d14874c77bfa) Co-authored-by: Dennis Sweeney <36520290+sweeneyde@users.noreply.github.com>
* gh-92886: Fix tests that fail when running with optimizations (`-O`) in ↵Miss Islington (bot)2022-06-101-0/+1
| | | | | | | `test_zipimport.py` (GH-93236) (cherry picked from commit 484a2357c8385694a077cf2ce0517f327fb0b172) Co-authored-by: jackh-ncl <1750152+jackh-ncl@users.noreply.github.com>
* gh-91317: Document that Path does not collapse initial `//` (GH-32193)Miss Islington (bot)2022-06-101-0/+2
| | | | | | | | | | | | | | | | | Documentation for `pathlib` says: > Spurious slashes and single dots are collapsed, but double dots ('..') are not, since this would change the meaning of a path in the face of symbolic links: However, it omits that initial double slashes also aren't collapsed. Later, in documentation of `PurePath.drive`, `PurePath.root`, and `PurePath.name` it mentions UNC but: - this abbreviation says nothing to a person who is unaware about existence of UNC (Wikipedia doesn't help either by [giving a disambiguation page](https://en.wikipedia.org/wiki/UNC)) - it shows up only if a person needs to use a specific property or decides to fully learn what the module provides. For context, see the BPO entry. (cherry picked from commit 78f1a436949209dab1f4a9d04036a1a42b165086) Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net>
* [3.10] gh-93671: Avoid exponential backtracking in deeply nested sequence ↵Pablo Galindo Salgado2022-06-101-0/+2
| | | | | | | | patterns in match statements (GH-93680) (#93690) Co-authored-by: Łukasz Langa <lukasz@langa.pl>. (cherry picked from commit 53a8b17895e91d08f76a2fb59a555d012cd85ab4) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* bpo-42658: Use LCMapStringEx in ntpath.normcase to match OS behaviour for ↵Steve Dower2022-06-101-0/+3
| | | | | case-folding (GH-93674) Co-authored-by: AN Long <aisk@users.noreply.github.com>
* gh-90494: Reject 6th element of the __reduce__() tuple (GH-93609) (GH-93632)Miss Islington (bot)2022-06-101-0/+3
| | | | | | | | copy.copy() and copy.deepcopy() now always raise a TypeError if __reduce__() returns a tuple with length 6 instead of silently ignore the 6th item or produce incorrect result. (cherry picked from commit a365dd64c2a1f0d142540d5031003f24986f489f) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* gh-90549: Fix leak of global named resources using multiprocessing spawn ↵Miss Islington (bot)2022-06-101-0/+2
| | | | | | | | | (GH-30617) Co-authored-by: XD Trol <milestonejxd@gmail.com> Co-authored-by: Antoine Pitrou <pitrou@free.fr> (cherry picked from commit 30610d28374f5a9698d456cebf3ae496ac01af51) Co-authored-by: Leo Trol <milestone.jxd@gmail.com>
* [3.10] gh-93421: Update sqlite3 cursor.rowcount only after SQLITE_DONE ↵Erlend Egeberg Aasland2022-06-081-0/+3
| | | | | (GH-93526) (GH-93599) (cherry picked from commit 875de61)
* gh-57539: Increase calendar test coverage (GH-93468) (GH-93565)Miss Islington (bot)2022-06-072-0/+2
| | | | | | | | (cherry picked from commit f0d0be3493fc5855eccfe0fbb3f25bf12760041f) Co-authored-by: Sean Fleming Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com> Co-authored-by: Łukasz Langa <lukasz@langa.pl> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* gh-88831: In docs for asyncio.create_task, explain why strong references to ↵Miss Islington (bot)2022-06-071-0/+1
| | | | | | | | tasks are needed (GH-93258) (GH-93567) Co-authored-by: Łukasz Langa <lukasz@langa.pl> (cherry picked from commit 75ceae05c11461beda65e6170b67b0b42fd55cd0) Co-authored-by: Andreas Grommek <76997441+agrommek@users.noreply.github.com>
* gh-92914: Round the allocated size for lists up to the even number ↵Miss Islington (bot)2022-06-071-0/+1
| | | | | | | (GH-92915) (GH-92942) (cherry picked from commit 8a6af5a34642f5564220eb50d72caada8f17fc78) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* gh-86986: bump min sphinx version to 3.2 (GH-93337) (GH-93562)Miss Islington (bot)2022-06-071-0/+1
| | | | | (cherry picked from commit 57e8ee7086bf3f5c50c901e9d5896275644bbb54) Co-authored-by: Davide Rizzo <sorcio@gmail.com>
* Python 3.10.5v3.10.5Pablo Galindo2022-06-0679-181/+824
|
* gh-89973: Fix re.error in the fnmatch module. (GH-93072)Miss Islington (bot)2022-06-051-0/+3
| | | | | | | | Character ranges with upper bound less that lower bound (e.g. [c-a]) are now interpreted as empty ranges, for compatibility with other glob pattern implementations. Previously it was re.error. (cherry picked from commit 0902c3d8edf7ef67972dd95f6a21670f5d1a4251) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* gh-92886: Fix test that fails when running with `-O` in `test_imaplib.py` ↵Miss Islington (bot)2022-06-041-0/+1
| | | | | | | (GH-93237) (cherry picked from commit 8150b8cf7fe09d601246f5bdc6456a0e31f31bca) Co-authored-by: jackh-ncl <1750152+jackh-ncl@users.noreply.github.com>
* gh-93156 - fix negative indexing into absolute `pathlib.PurePath().parents` ↵Miss Islington (bot)2022-06-031-0/+2
| | | | | | | | | | | | | | (GH-93273) When a `_PathParents` object has a drive or a root, the length of the object is *one less* than than the length of `self._parts`, which resulted in an off-by-one error when `path.parents[-n]` was fed through to `self._parts[:-n - 1]`. In particular, `path.parents[-1]` was a malformed path object with spooky properties. This is addressed by adding `len(self)` to negative indices. (cherry picked from commit f32e6b48d12834ba3bde01ec21c14da33abd26d6) Co-authored-by: Barney Gale <barney.gale@gmail.com>
* gh-93418: Fix an assert when an f-string expression is followed by an '=', ↵Miss Islington (bot)2022-06-021-0/+2
| | | | | | | | | but no closing brace. (gh-93419) (gh-93423) (cherry picked from commit ee70c70aa93d7a41cbe47a0b361b17f9d7ec8acd) Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com> Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
* bpo-42272: fix misleading warning filter message/module docs (GH-23172)Miss Islington (bot)2022-05-301-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * bpo-42272: improve message/module warning filter docs "The Warnings Filter" section of the warnings module documentation describes the message and module filters as "a string containing a regular expression". While that is true when they are arguments to the filterwarnings function, it is not true when they appear in -W or $PYTHONWARNINGS where they are matched literally (after stripping any starting/ending whitespace). Update the documentation to note when they are matched literally. Also clarify that module matches the "fully-qualified module name", rather than "module name" which is ambiguous. skip news (since this is a doc fix) Signed-off-by: Kevin Locke <kevin@kevinlocke.name> * bpo-42272: remove bad submodule warning filter doc The `error:::mymodule[.*]` example in the "Describing Warning Filters" section of the warnings module documentation does not behave as the comment describes. Since the module portion of the filter string is interpreted literally, it would match a module with a fully-qualified name that is literally `mymodule[.*]`. Unfortunately, there is not a way to match '"module" and any subpackages of "mymodule"' as documented, since the module part of a filter string is matched literally. Instead, update the filter and comment to match only "mymodule". skip news (since this is a doc fix) Signed-off-by: Kevin Locke <kevin@kevinlocke.name> * bpo-42272: add warning filter doc changes to NEWS Signed-off-by: Kevin Locke <kevin@kevinlocke.name> (cherry picked from commit 8136606769661c103c46d142e52ecbbbb88803f6) Co-authored-by: Kevin Locke <kevin@kevinlocke.name>
* [3.10] gh-93217: fix some issues in man page and --help (GH-93219) (#93261)Éric2022-05-291-3/+7
|
* gh-92240 : Include release dates for "What's New In Python 3.X" (GH-92937)Miss Islington (bot)2022-05-291-0/+2
| | | | | | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com> (cherry picked from commit 877ad7b3b2778a305d3989d58ebd68cb01baf26e) Co-authored-by: georgically <40323509+georgically@users.noreply.github.com>
* gh-92839: fixed typo in _bisectmodule.c (line 131) (GH-92849) (#93321)Miss Islington (bot)2022-05-281-0/+1
|
* [3.10] gh-91924: Fix __ltrace__ for non-UTF-8 stdout encoding (#93214)Victor Stinner2022-05-251-0/+2
| | | | | | | | | | Fix __ltrace__ debug feature if the stdout encoding is not UTF-8. If the stdout encoding is not UTF-8, the first call to lltrace_resume_frame() indirectly sets lltrace to 0 when calling unicode_check_encoding_errors() which calls encodings.search_function(). Add test_lltrace.test_lltrace() test.
* [3.10] gh-83245: Raise BadZipFile instead of ValueError when reading a ↵Miss Islington (bot)2022-05-251-0/+2
| | | | | | | | | | | corrupt ZIP file (GH-32291) (GH-93140) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com> (cherry picked from commit 202ed2506c84cd98e9e35621b5b2929ceb717864) Co-authored-by: Sam Ezeh <sam.z.ezeh@gmail.com> Automerge-Triggered-By: GH:serhiy-storchaka
* gh-93065: Fix HAMT to iterate correctly over 7-level deep trees (GH-93066) ↵Miss Islington (bot)2022-05-242-0/+6
| | | | | | | | | | | | (GH-93146) Also while there, clarify a few things about why we reduce the hash to 32 bits. Co-authored-by: Eli Libman <eli@hyro.ai> Co-authored-by: Yury Selivanov <yury@edgedb.com> Co-authored-by: Łukasz Langa <lukasz@langa.pl> (cherry picked from commit c1f5c903a7e4ed27190488f4e33b00d3c3d952e5)
* gh-93061: Mark as artificial: backwards jump after async for (GH-93120)Dennis Sweeney2022-05-231-0/+1
|
* gh-93010: InvalidHeaderError used but nonexistent (GH-93015)Miss Islington (bot)2022-05-231-0/+1
| | | | | | | | * fix issue 93010 Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> (cherry picked from commit 71abeb0895f7563dc5ac4b4f077a8f87dab57e7a) Co-authored-by: oda-gitso <105083118+oda-gitso@users.noreply.github.com>
* gh-92984: Explicitly disable incremental linking for Windows Release and PGO ↵Miss Islington (bot)2022-05-191-0/+1
| | | | | | | builds (GH-92985) (cherry picked from commit 38feffa09c74d9a853745908b7813903bae33b96) Co-authored-by: David Machaj <46852402+dmachaj@users.noreply.github.com>
* [3.10] bpo-28249: fix `lineno` location for empty `DocTest` instances ↵Łukasz Langa2022-05-191-0/+2
| | | | | | | | | | (GH-30498) (#92981) (cherry picked from commit 8db2b3b6878aba9f12844526bce966b7eed81aee) Co-authored-by: Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com> Co-authored-by: Łukasz Langa <lukasz@langa.pl> Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
* bpo-45393: help() on operator precedence has misleading entries (GH-31246) ↵Miss Islington (bot)2022-05-191-0/+2
| | | | | | | (GH-92966) (cherry picked from commit fb082c2fc5a925085b179e63ca10b7f60b356d2f) Co-authored-by: Zackery Spytz <zspytz@gmail.com>
* gh-92670: Skip test_shutil.TestCopy.test_copyfile_nonexistent_dir on AIX ↵Miss Islington (bot)2022-05-191-0/+3
| | | | | | | (GH-92718) (cherry picked from commit 654032ac5f6982b36d45e024037f37fb65166aed) Co-authored-by: Ayappan Perumal <ayappap2@in.ibm.com>
* bpo-40838: document `getdoc`, `getmodule`, `getsourcefile` in `inspect` ↵Miss Islington (bot)2022-05-181-0/+2
| | | | | | | | | returns `None` (GH-30575) Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> (cherry picked from commit b86d783a4eff96306f315acf9a6f1aca85d47fc3) Co-authored-by: Nikita Sobolev <mail@sobolevn.me>
* bpo-39829: Fix `__len__()` is called twice in list() constructor (GH-31816)Miss Islington (bot)2022-05-182-0/+2
| | | | | | | (cherry picked from commit 2153daf0a02a598ed5df93f2f224c1ab2a2cca0d) This patch fixes gh-87740 too. Co-authored-by: Crowthebird <78076854+thatbirdguythatuknownot@users.noreply.github.com>
* gh-92530: Fix an issue that occurred after interrupting ↵Miss Islington (bot)2022-05-161-0/+2
| | | | | | | | | | | threading.Condition.notify (GH-92534) (GH-92830) If Condition.notify() was interrupted just after it released the waiter lock, but before removing it from the queue, the following calls of notify() failed with RuntimeError: cannot release un-acquired lock. (cherry picked from commit 70af994fee7c0850ae859727d9468a5f29375a38) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* Check result of utc_to_seconds and skip fold probe in pure Python (GH-91582)Miss Islington (bot)2022-05-142-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `utc_to_seconds` call can fail, here's a minimal reproducer on Linux: TZ=UTC python -c "from datetime import *; datetime.fromtimestamp(253402300799 + 1)" The old behavior still raised an error in a similar way, but only because subsequent calculations happened to fail as well. Better to fail fast. This also refactors the tests to split out the `fromtimestamp` and `utcfromtimestamp` tests, and to get us closer to the actual desired limits of the functions. As part of this, we also changed the way we detect platforms where the same limits don't necessarily apply (e.g. Windows). As part of refactoring the tests to hit this condition explicitly (even though the user-facing behvior doesn't change in any way we plan to guarantee), I noticed that there was a difference in the places that `datetime.utcfromtimestamp` fails in the C and pure Python versions, which was fixed by skipping the "probe for fold" logic for UTC specifically — since UTC doesn't have any folds or gaps, we were never going to find a fold value anyway. This should prevent some failures in the pure python `utcfromtimestamp` method on timestamps close to 0001-01-01. There are two separate news entries for this because one is a potentially user-facing change, the other is an internal code correctness change that, if anything, changes some error messages. The two happen to be coupled because of the test refactoring, but they are probably best thought of as independent changes. Fixes GH-91581 (cherry picked from commit 83c0247d47b99f4571e35ea95361436e1d2a61cd) Co-authored-by: Paul Ganssle <1377457+pganssle@users.noreply.github.com>
* [3.10] gh-92311: Let frame_setlineno jump over listcomps (GH-92717)Dennis Sweeney2022-05-121-0/+1
|
* bpo-42627: Fix incorrect parsing of Windows registry proxy settings (GH-26307)Miss Islington (bot)2022-05-121-0/+1
| | | | | (cherry picked from commit b69297ea23c0ab9866ae8bd26a347a9b5df567a6) Co-authored-by: 狂男风 <CrazyBoyFeng@Live.com>
* [3.10] gh-91810: ElementTree: Use text file's encoding by default in XML ↵Miss Islington (bot)2022-05-111-0/+5
| | | | | | | | | | | | | declaration (GH-91903) (GH-92664) ElementTree method write() and function tostring() now use the text file's encoding ("UTF-8" if not available) instead of locale encoding in XML declaration when encoding="unicode" is specified. (cherry picked from commit 707839b0fe02ba2c891a40f40e7a869d84c2c9c5) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com> Automerge-Triggered-By: GH:serhiy-storchaka
* bpo-46785: Fix race condition between os.stat() and unlink on Windows (GH-31858)Itai Steinherz2022-05-102-0/+2
| | | | | | * [3.10] bpo-46785: Fix race condition between os.stat() and unlink on Windows (GH-31858). (cherry picked from commit 39e6b8ae6a5b49bb23746fdcc354d148ff2d98e3) Co-authored-by: Itai Steinherz <itaisteinherz@gmail.com>
* bpo-13553: Document tkinter.Tk args (GH-4786)Miss Islington (bot)2022-05-101-0/+1
| | | | | (cherry picked from commit c56e2bb9949c95ec8911cd5554b07044a564796f) Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* bpo-38056: overhaul Error Handlers section in codecs documentation (GH-15732)Miss Islington (bot)2022-05-091-0/+1
| | | | | | | | | | | | | * Some handlers were wrongly described as text-encoding only, but actually they can also be used in text-decoding. * Add more description to each handler. * Add two REPL examples. * Add indexes for Error Handler's name. Co-authored-by: Kyle Stanley <aeros167@gmail.com> Co-authored-by: Victor Stinner <vstinner@python.org> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> (cherry picked from commit 5bc2390229bbcb4f13359e867fd8a140a1d5496b) Co-authored-by: Ma Lin <animalize@users.noreply.github.com>
* Fix use of the default role in a news entry. (#92500)Ezio Melotti2022-05-081-1/+1
|
* [3.10] gh-90622: Do not spawn ProcessPool workers on demand via fork method. ↵Gregory P. Smith2022-05-081-0/+4
| | | | | | | | | | | (GH-91598) (#92497) Do not spawn ProcessPool workers on demand when they spawn via fork. This avoids potential deadlocks in the child processes due to forking from a multithreaded process.. (cherry picked from commit ebb37fc3fdcb03db4e206db017eeef7aaffbae84) Co-authored-by: Gregory P. Smith <greg@krypto.org>
* [3.10] gh-92448: Update the documentation builder to render the GitHub issue ↵Dong-hee Na2022-05-087-8/+8
| | | | (GH-92449). (GH-92457)
* [3.10] gh-92112: Fix crash triggered by an evil custom `mro()` (GH-92113) ↵Jelle Zijlstra2022-05-071-0/+1
| | | | | | | (#92370) (cherry picked from commit 85354ed78c0edb6d81a2bd53cabc85e547b8b26e) Co-authored-by: Alexey Izbyshev <izbyshev@ispras.ru>
* NEWS: Reorder items by section (GH-92373)Miss Islington (bot)2022-05-066-214/+214
| | | | | | They caused duplicated sections. (cherry picked from commit 9b491ae04c900579ec82776aacdf71b2fd1e9d6a) Co-authored-by: Inada Naoki <songofacandy@gmail.com>
* [3.10] gh-80254: Disallow recursive usage of cursors in `sqlite3` converters ↵Erlend Egeberg Aasland2022-05-051-0/+2
| | | | | | | | | | | | (#92274) * [3.10] gh-80254: Disallow recursive usage of cursors in `sqlite3` converters (#29054) (cherry picked from commit f629dcfe835e349433e4c5099381d668e8fe69c8) Co-authored-by: Sergey Fedoseev <fedoseev.sergey@gmail.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> * Fix ref leak in pysqlite_cursor_iternext
* gh-92036: Fix gc_fini_untrack() (GH-92037)Miss Islington (bot)2022-05-041-0/+5
| | | | | | | | | | | Fix a crash in subinterpreters related to the garbage collector. When a subinterpreter is deleted, untrack all objects tracked by its GC. To prevent a crash in deallocator functions expecting objects to be tracked by the GC, leak a strong reference to these objects on purpose, so they are never deleted and their deallocator functions are not called. (cherry picked from commit 14243369b5f80613628a565c224bba7fb3fcacd8) Co-authored-by: Victor Stinner <vstinner@python.org>
* bpo-47029: Fix BrokenPipeError in multiprocessing.Queue at garbage ↵Miss Islington (bot)2022-05-041-0/+4
| | | | | | | collection and explicit close (GH-31913) (cherry picked from commit dfb1b9da8a4becaeaed3d9cffcaac41bcaf746f4) Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
* bpo-29890: Test IPv*Interface construction with tuple argument (GH-30862)Miss Islington (bot)2022-05-031-0/+2
| | | | | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> (cherry picked from commit b295a92c50b128e494f47c28f12b8e9eac2927ea) Co-authored-by: Humbled Drugman <humbled.drugman@gmail.com>
* bpo-46415: Use f-string for ValueError in ↵Miss Islington (bot)2022-05-031-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | ipaddress.ip_{address,network,interface} helper functions (GH-30642) `IPv*Network` and `IPv*Interface` constructors accept a 2-tuple of (address description, netmask) as the address parameter. When the tuple-based address is used errors are not propagated correctly through the `ipaddress.ip_*` helper because of the %-formatting now expecting several arguments: In [7]: ipaddress.ip_network(("192.168.100.0", "fooo")) ... TypeError: not all arguments converted during string formatting Compared to: In [8]: ipaddress.IPv4Network(("192.168.100.0", "foo")) ... NetmaskValueError: 'foo' is not a valid netmask Use an f-string to make sure the error is always properly formatted. Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> (cherry picked from commit 52dc9c3066bcdc67a7a45d41cf158ecb1434d5f3) Co-authored-by: Thomas Cellerier <thomascellerier@gmail.com>