| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
(#104968)
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
|
|
|
|
|
|
| |
Remove raw asserts in test_typing.py (GH-104951)
(cherry picked from commit 2cb445635e99d4401949cabebd373288cfdd0138)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
|
|
|
|
|
|
|
|
| |
(gh-104971)
gh-104924: Fix `read()able` in `http.client` log messages (gh-104926)
(cherry picked from commit 6c81d7572edbe3a5800b1128e55a2dcef03cc13c)
Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net>
|
|
|
|
|
| |
(cherry picked from commit 46857d0b2a2ac6aeb6dcce2bf2c92ddf4abe7496)
Co-authored-by: Tomas R <tomas.roun8@gmail.com>
|
|
|
|
|
| |
(cherry picked from commit 705e387dd81b971cb1ee5727da54adfb565f61d0)
Co-authored-by: Stepfen Shawn <m18824909883@163.com>
|
|
|
|
|
|
|
| |
(GH-104681) (#104961)
(cherry picked from commit 2cf04e455d8f087bd08cd1d43751007b5e41b3c5)
Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Fix test_importlib.test_side_effect_import() (GH-104840)
Wait until the thread spawn by the import completes to avoid dangling
threads. With this fix, the following command no longer fails:
./python -m test --fail-env-changed test_importlib -m test_side_effect_import -F -j20
(cherry picked from commit 426950993f6a39cdf3f6a3333ac8b518833c7e61)
Co-authored-by: Victor Stinner <vstinner@python.org>
|
|
|
|
|
|
| |
gh-104874: Document NewType.__supertype__ (GH-104875)
(cherry picked from commit 41768a2bd3a8f57e6ce4e4ae9cab083b69817ec1)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
|
|
|
|
|
|
|
| |
In particular, it's important to test that is_typeddict(TypedDict)
returns False.
(cherry picked from commit 1497607a8e99f1103c40368dd5f9057f0146a520)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
|
|
|
|
| |
fixed by Apple in macOS 13.4. (GH-104885)
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-104767) (#104845)
gh-104719: IDLE - test existence of all tokenize references. (GH-104767)
Class editor.IndentSearcher contains all editor references to tokenize module.
Module io tokenize reference cover those other modules.
(cherry picked from commit e561c09975bf67ad8bb67c56a81e30a9165bcc84)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
safety gh-104518 (#104785)
Move all of the Python C API calls into the parent process up front
instead of doing PyLong_AsLong and PyErr_Occurred and PyTuple_GET from
the post-fork/vfork child process.
Much of this was long overdue. We shouldn't have been using PyTuple and
PyLong APIs within all of these low level functions anyways.
This is a backport of c649df6 for #104518 and the tiny adjustment in d1732fe #104697.
Backporting this allows backporting of the real bug fix that requires it.
Co-authored-by: Gregory P. Smith [Google] <greg@krypto.org>
|
|
|
|
|
|
| |
[3.12] gh-104271: Fix auto() fallback in case of mixed type Enum (GH-104279)
(cherry picked from commit f4e2049f14d40c1b893c68530eec5e341cf3d929)
Co-authored-by: Itamar Ostricher <itamarost@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Set up gcc-10 for ASAN CI as the existing config's default 9.x does not
play well with `vfork()`.
<!--
Thanks for your contribution!
Please read this comment in its entirety. It's quite important.
GH- Pull Request title
It should be in the following format:
```
gh-NNNNN: Summary of the changes made
```
Where: gh-NNNNN refers to the GitHub issue number.
Most PRs will require an issue number. Trivial changes, like fixing a
typo, do not need an issue.
GH- Backport Pull Request title
If this is a backport PR (PR made against branches other than `main`),
please ensure that the PR title is in the following format:
```
[X.Y] <title from the original PR> (GH-NNNN)
```
Where: [X.Y] is the branch name, e.g. [3.6].
GH-NNNN refers to the PR number from `main`.
-->
<!-- gh-issue-number: gh-103726 -->
* Issue: gh-103726
<!-- /gh-issue-number -->
(cherry picked from commit 83305808000e03cbad31ac3e9ef65454fb409282)
Co-authored-by: Dong-hee Na <donghee.na@python.org>
|
|
|
|
|
|
|
|
|
|
| |
(GH-104193) (GH-104746)
howto/urllib2: remove link to an outdated french translation (GH-104193)
We now have our own translation and it's not outdated
(cherry picked from commit 151b6bfb5d9a15b6e2682e5a3008a3f9ec3086ae)
Co-authored-by: Mathieu Dupuy <deronnax@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-104537) (#104737)
Fix a race condition in the internal `multiprocessing.process` cleanup
logic that could manifest as an unintended `AttributeError` when calling
`BaseProcess.close()`.
(cherry picked from commit ef5d00a59207a63c6d5ae0d5d44054847d1bf3b5)
Co-authored-by: Luccccifer <lukezhang764@gmail.com>
Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
|
|
|
|
|
|
|
|
|
|
|
| |
staticmethod decorators (GH-103228) (#103499)
Fixes unittest.mock.patch not enforcing function signatures for methods
decorated with @classmethod or @staticmethod when patch is called with
autospec=True.
(cherry picked from commit 59e0de4903c02e72b329e505fddf1ad9794928bc)
Co-authored-by: Tomas R <tomas.roun8@gmail.com>
|
|
|
|
|
|
|
|
|
| |
(#103137)
Add IPv6 into to the docstring for socket.getsockname (GH-102961)
(cherry picked from commit ecc5441505cd7cb54f3d38409c732e2e9f102137)
Signed-off-by: Brian Haley <haleyb.dev@gmail.com>
Co-authored-by: Brian Haley <brianphaley@gmail.com>
|
|
|
|
| |
method (#104729) (#104730)
|
|
|
|
|
|
|
|
|
| |
(GH-103628) (#104687)
* gh-103606: Improve error message from logging.config.FileConfig (GH-103628)
(cherry picked from commit 152227b569c3a9b87fe0483706f704762ced6d75)
plus backport the followup exception change fix to that in #104701
|
|
|
|
|
|
|
|
| |
(#104727)
gh-104719: IDLE - delete useless monkeypatch of tokenize (GH-104726)
(cherry picked from commit 0c5e79bcdf99a6a07c65b0ea6d7701b6e041481c)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-104707) (#104721)
- AnyStr can be used in type annotations, contrary to the section header
- Unpack can also be used in annotations, and its use is not restricted
to generics. It makes more sense with other building blocks like Required.
- Protocol is not necessarily generic.
Also fix the indentation for two notes associated with Concatenate.
(cherry picked from commit ab71acd67b5b09926498b8c7f855bdb28ac0ec2f)
---------
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
|
|
|
|
|
|
| |
Corrected identifier (GH-104713)
(cherry picked from commit 60993ba8b4a04dfcf2d3067d919bcce160f01bd5)
Co-authored-by: William Sawyer <wmsawyer2609@gmail.com>
|
|
|
|
|
|
| |
(cherry picked from commit 99b641886a09252bbcf99a1d322fa8734f1ca30d)
Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
gh-101857: Allow xattr detection on musl libc (GH-101858)
Previously, we checked exclusively for `__GLIBC__` (AND'd with some other
conditions). Checking for `__linux__` instead should be fine.
This fixes using e.g. `os.listxattr()` on systems using musl libc.
Bug: https://bugs.gentoo.org/894130
(cherry picked from commit 8be8101bca34b60481ec3d7ecaea4a3379fb7dbb)
Co-authored-by: Sam James <sam@gentoo.org>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
|
|
|
|
|
|
|
|
| |
collection is undefined (GH-104699) (#104703)
gh-49174: document that the effect of calling gc.collect() during a collection is undefined (GH-104699)
(cherry picked from commit 30488fa22a8f63753192ae7f1d01665857764e45)
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
|
|
|
| |
(cherry picked from commit 2c97878bb8a09f5aba8bf413bb794f6efd5065df)
|
|
|
|
|
|
|
|
| |
gh-56276: Add tests to test_compare (GH-3199)
(cherry picked from commit 68ee8b3f15b744339c156bfeb583a414061ab22d)
Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net>
|
|
|
|
|
|
|
|
| |
gh-103987: fix several crashes in mmap module (GH-103990)
(cherry picked from commit ceaa4c3476ac49b5b31954fec53796c7a3b40349)
Co-authored-by: Prince Roshan <princekrroshan01@gmail.com>
Co-authored-by: sunmy2019 <59365878+sunmy2019@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
|
|
|
|
|
|
|
|
|
|
| |
ASAN is enabled (GH-104667) (#104673)
gh-104472: Skip `test_subprocess.ProcessTestCase.test_empty_env` if ASAN is enabled (GH-104667)
Skip test_subprocess.ProcessTestCase.test_empty_env if ASAN is enabled.
(cherry picked from commit c3f43bfb4bec39ff8f2c36d861a3c3a243bcb3af)
Co-authored-by: chgnrdv <52372310+chgnrdv@users.noreply.github.com>
|
|
|
|
|
|
|
|
| |
(GH-104661) (#104670)
docs: fix wrong indentation causing rendering error in dis page (GH-104661)
(cherry picked from commit 3bc94e678f2961eafc9d665898d73afc6204d314)
Co-authored-by: Nyakku Shigure <sigure.qaq@gmail.com>
|
|
|
|
|
|
|
|
|
| |
(#104665) (#104666)
gh-104659: Consolidate python examples in enum documentation (#104665)
(cherry picked from commit 3ac856e69734491ff8423020c700c9ae86ac9a08)
Co-authored-by: Thomas Hisch <t.hisch@gmail.com>
|
|
|
|
|
| |
(GH-104650)
Backport of GH-104579
|
|
|
|
|
| |
(#104636)
(cherry picked from commit 0589c6a4d3d822cace42050198cb9a5e99c879ad)
|
|
|
|
|
|
| |
gh-104645: fix error handling in marshal tests (GH-104646)
(cherry picked from commit ac56a854b418d35ad3838f3072604227dc718fca)
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
|
|
|
|
|
| |
(cherry picked from commit 9c5aa8967bd7c1b02fb1da055c6b3afcccbbb251)
Co-authored-by: Youfu Zhang <1315097+zhangyoufu@users.noreply.github.com>
|
|
|
|
|
|
|
|
|
|
| |
(GH-101831) (#104652)
Utilize new functions termios.tcgetwinsize() and termios.tcsetwinsize in test_pty.py.
(cherry picked from commit da2fb9264315dc30ac3012b4dbf5ba76d3f34433)
Co-authored-by: Soumendra Ganguly <67527439+8vasu@users.noreply.github.com>
Co-authored-by: Gregory P. Smith <greg@krypto.org>
|
|
|
|
|
| |
(cherry picked from commit fd04bfeaf7a4531120ad450dbd1afc121a2523ee)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
|
|
|
|
| |
(#104633)
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-104630) (#104632)
gh-104629: Don't skip test_clinic if _testclinic is missing (GH-104630)
Just skip the tests that depend on the _testclinic extension module;
we can still run the Python tests.
(cherry picked from commit 86ee49f469b84e4b746526a00d8191d0e374a268)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
|
|
|
|
|
|
| |
gh-104499: Fix typo. (GH-104598)
(cherry picked from commit c5b670efd1e6dabc94b6308734d63f762480b80f)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
|
|
|
|
|
|
| |
gh-104499: IDLE - fix completions for tk aqua 8.7 (GH-104591)
(cherry picked from commit 678bf57ed04b8c250f0bc031ebd264bece76e731)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
|
|
|
|
|
|
|
| |
stdin (GH-104586) (#104594)
(cherry picked from commit 7fc8e2d4627cdba5cb0075c9052ed6f4b6ecd36d)
Co-authored-by: Guido van Rossum <guido@python.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-102508) (#104575)
* gh-102153: Start stripping C0 control and space chars in `urlsplit` (GH-102508)
`urllib.parse.urlsplit` has already been respecting the WHATWG spec a bit GH-25595.
This adds more sanitizing to respect the "Remove any leading C0 control or space from input" [rule](https://url.spec.whatwg.org/GH-url-parsing:~:text=Remove%20any%20leading%20and%20trailing%20C0%20control%20or%20space%20from%20input.) in response to [CVE-2023-24329](https://nvd.nist.gov/vuln/detail/CVE-2023-24329).
---------
(cherry picked from commit 2f630e1ce18ad2e07428296532a68b11dc66ad10)
Co-authored-by: Illia Volochii <illia.volochii@gmail.com>
Co-authored-by: Gregory P. Smith [Google] <greg@krypto.org>
|
|
|
|
|
|
|
|
|
|
| |
(#104587)
gh-104496: IDLE - fix About for mixed tcl/tk versions (GH-104585)
Print both if they are different, as may happen in the future.
(cherry picked from commit aed643baa968b4959b830d37750080cac546fba7)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
|
|
|
|
|
|
|
|
| |
During the PEP 695 implementation at one point I made
TypeVar.__name__ return garbage, and all of test_typing passed.
So I decided to add a few more tests.
(cherry picked from commit 26931944dd8abd6554249239344fa62b789b9028)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
cases (GH-103863) (#104534)
Fix Zip64 extensions not being properly applied in some cases:
Fixes an issue where adding a small file to a `ZipFile`
object while forcing zip64 extensions causes an extra Zip64 record to be
added to the zip, but doesn't update the `min_version` or file sizes in
the primary central directory header.
Also fixed an edge case in checking if zip64 extensions are required:
This fixes an issue where if data requiring zip64 extensions was added
to an unseekable stream without specifying `force_zip64=True`, zip64
extensions would not be used and a RuntimeError would not be raised when
closing the file (even though the size would be known at that point).
This would result in successfully writing corrupt zip files.
Deciding if zip64 extensions are required outside of the `FileHeader`
function means that both `FileHeader` and `_ZipWriteFile` will always be
in sync. Previously, the `FileHeader` function could enable zip64
extensions without propagating that decision to the `_ZipWriteFile`
class, which would then not correctly write the data descriptor record
or check for errors on close.
If anyone is actually using `ZipInfo.FileHeader` as a public API without
explicitly passing True or False in for zip64, their own code may still be
susceptible to that kind of bug unless they make a similar change to
where the zip64 decision happens.
Fixes GH-103861
---------
.
(cherry picked from commit 798bcaa1eb01de7db9ff1881a3088603ad09b096)
Co-authored-by: Carey Metcalfe <carey@cmetcalfe.ca>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#104563)
gh-87474: Fix file descriptor leaks in subprocess.Popen (GH-96351)
This fixes several ways file descriptors could be leaked from `subprocess.Popen` constructor during error conditions by opening them later and using a context manager "fds to close" registration scheme to ensure they get closed before returning.
---------
(cherry picked from commit 3a4c44bb1e92802db64deec59cf8a68ad3973219)
Co-authored-by: cptpcrd <31829097+cptpcrd@users.noreply.github.com>
Co-authored-by: Gregory P. Smith [Google] <greg@krypto.org>
|
|
|
|
|
|
|
|
|
|
| |
(GH-104495) (#104569)
gh-104494: Update certain Tkinter pack/place tests for Tk 8.7 errors (GH-104495)
(cherry picked from commit 3cba61f111db9b5e8ef35632915309f81fff8c6c)
Co-authored-by: Christopher Chavez <chrischavez@gmx.us>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
|
|
|
|
|
|
|
|
|
| |
(GH-104517) (#104557)
gh-75367: Fix data descriptor detection in inspect.getattr_static (GH-104517)
(cherry picked from commit 5e9f471e7db30893fb3f42681f17fdcdb70069ee)
Co-authored-by: Furkan Onder <furkanonder@protonmail.com>
Co-authored-by: Carl Meyer <carl@oddbird.net>
|