| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
Fix an issue of concurrent.futures ProcessPoolExecutor shutdown hanging.
(cherry picked from commit 2dc94634b50f0e5e207787e5ac1d56c68b22c3ae)
Co-authored-by: yonatanp <yonatan.perry@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
|
|
|
|
|
|
| |
Add thrashcan macros to the deallocator of the filter objects to protect against deeply nested destruction of chains of nested filters.
(cherry picked from commit 66aa78cbe604a7c5731f074b869f92174a8e3b64)
Co-authored-by: Marta Gómez Macías <mgmacias@google.com>
|
|
|
|
|
|
|
|
| |
(gh-102230)
gh-95675: fix uid and gid at test_add_dir_getmember (gh-102207)
(cherry picked from commit 56e93c8020e89e1712aa238574bca2076a225028)
Co-authored-by: Seonkyo Ok <seonkyo.ok@linecorp.com>
|
|
|
|
|
|
|
|
| |
io.BytesIO (gh-102100) (#102118)
gh-101936: Update the default value of fp from io.StringIO to io.BytesIO (gh-102100)
(cherry picked from commit 0d4c7fcd4f078708a5ac6499af378ce5ee8eb211)
Co-authored-by: Long Vo <long.vo@linecorp.com>
|
|
|
|
|
|
| |
gh-95672 fix typo SkitTest to SkipTest (gh-102119)
(cherry picked from commit d5c7954d0c3ff874d2d27d33dcc207bb7356f328)
Co-authored-by: HyunKyun Moon <hyunkyun.moon@linecorp.com>
|
|
|
|
|
|
|
|
| |
for the binary mode (gh-102068) (#102099)
gh-101961 fileinput.hookcompressed should not set the encoding value for the binary mode (gh-102068)
(cherry picked from commit 6f25657b83d7a680a97849490f6e973b3a695e1a)
Co-authored-by: Gihwan Kim <gihwan.kim@linecorp.com>
|
|
|
|
|
| |
(cherry picked from commit e860e521ec0d84e175269aeb15cf24bd6053ad17)
Co-authored-by: Kirill <iam@python273.pw>
|
|
|
|
|
|
| |
The `movies[bisect(movies, 1960, key=by_year)]` will actually return only movies **after** 1960.
(cherry picked from commit 4317b25a2323ae4be04574e45de0e335c571c463)
Co-authored-by: prego <pedropregueiro@gmail.com>
|
|
|
|
|
| |
function load (GH-95521)
Co-authored-by: Derek Kim <ddkim1024@gmail.com>
|
|
|
|
|
|
|
|
| |
autoincrement (GH-9621) (#94015)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
(cherry picked from commit affa9f22cfd1e83a5fb413e5ce2feef9ea1a49ac)
Co-authored-by: itssme <itssme3000@gmail.com>
|
|
|
|
|
|
|
|
| |
(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-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)
|
|
|
|
|
|
|
| |
(cherry picked from commit 2153daf0a02a598ed5df93f2f224c1ab2a2cca0d)
This patch fixes gh-87740 too.
Co-authored-by: Crowthebird <78076854+thatbirdguythatuknownot@users.noreply.github.com>
|
|
|
|
|
|
| |
* [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>
|
|
|
|
|
|
|
| |
Co-authored-by: Andrew Kuchling <amk@amk.ca>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
(cherry picked from commit a74892cb2168d249d9a8c53fad605a5def9b41d4)
Co-authored-by: yyyyyyyan <24644216+yyyyyyyan@users.noreply.github.com>
|
|
|
|
|
| |
(cherry picked from commit 48269ea9fdbc5804f80962364f95e69097c417ba)
Co-authored-by: 180909 <734461790@qq.com>
|
|
|
|
|
| |
(cherry picked from commit a0db11b10fca0fee6bb2b8d6277e266bad8c0fdb)
Co-authored-by: Bader Zaidan <bader@zaidan.pw>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-31061) (GH-31821)
(Cherry-picked from 32bf3597922ac3f613989582afa2bff43bea8a2f.)
GH-26091 added the _typevar_types and _paramspec_tvars instance
variables to _GenericAlias. However, they were not propagated
consistently. This commit addresses the most prominent deficiency
identified in bpo-46581 (namely their absence from
_GenericAlias.copy_with), but there could be others.
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
|
|
|
|
|
|
| |
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
(cherry picked from commit 496c428de3318c9c5770937491b71dc3d3f18a6a)
Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-31384)
It fixes the "Text File Busy" OSError when using 'rmtree' on a
windows-managed filesystem in via the VirtualBox shared folder
(and possible other scenarios like a windows-managed network file
system).
(cherry picked from commit b77158b4da449ec5b8f682816a79d004fd65ed07)
Co-authored-by: Lital Natan <litaln@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The `module` parameter carries semantic information about the forward ref.
Forward refs are different if they refer to different module even if they
have the same name. This affects the `__eq__`, `__repr__` and `__hash__` methods.
Co-authored-by: Andreas Hangauer <andreas.hangauer@siemens.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit 6e7b813195f9bd6a2a15c1f00ef2c0180f6c751a)
Co-authored-by: aha79 <34090357+aha79@users.noreply.github.com>
Automerge-Triggered-By: GH:JelleZijlstra
|
|
|
|
|
| |
(cherry picked from commit 60705cff70576482fea31dcafbf8a37cbb751ea5)
Co-authored-by: Tom Sparrow <793763+sparrowt@users.noreply.github.com>
|
|
|
|
|
|
|
|
| |
This addresses [bpo-45554]() by expanding the `exitcode` documentation to also describe what `exitcode` will be in cases of normal termination, `sys.exit()` called, and on uncaught exceptions.
Automerge-Triggered-By: GH:pitrou
(cherry picked from commit 3852269b91fcc8ee668cd876b3669eba6da5b1ac)
Co-authored-by: John Marshall <jmarshall@hey.com>
|
|
|
|
|
|
|
|
|
|
|
| |
The doctest module raised an error if a docstring contained an example that
attempted to access a classmethod property. (Stacking '@classmethod' on top of
`@property` has been supported since Python 3.9; see
https://docs.python.org/3/howto/descriptor.htmlGH-class-methods.)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
(cherry picked from commit b1302abcc8a4be5f39b4d60a1ce28032b77655b3)
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On non-Linux POSIX platforms, like FreeBSD or macOS,
the FD used to read a forked PTY may signal its exit not
by raising an error but by sending empty data to the read
syscall. This case wasn't handled, leading to hanging
`pty.spawn` calls.
Co-authored-by: Reilly Tucker Siemens <reilly@tuckersiemens.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 81ab8db235580317edcb0e559cd4c983f70883f5)
Co-authored-by: Zephyr Shannon <geoffpshannon@gmail.com>
|
|
|
|
|
|
|
|
| |
gen.throw. (GH-17658) (GH-27572)
Co-authored-by: Benjamin Peterson <benjamin@python.org>
(cherry picked from commit 83ca46b7784b7357d82ec47b33295e09ed7380cb)
Co-authored-by: Noah <33094578+coolreader18@users.noreply.github.com>
|
|
|
|
|
| |
(cherry picked from commit 28b6dc9dd5d1ce6f8aff7e06d4ef9afdc2bc8332)
Co-authored-by: Miguel Brito <5544985+miguendes@users.noreply.github.com>
|
|
|
|
|
|
|
|
|
|
| |
(GH-27488)
When sys.stdout.encoding is None compile_file will fall back to
sys.getdefaultencoding to encode/decode error messages.
Co-authored-by: Stefan Hoelzl <stefan.hoelzl@posteo.de>
Co-authored-by: Mickaël Schoentgen <contact@tiger-222.fr>
(cherry picked from commit 80f07076294bc09a55ed76d9bbf307404eef25e6)
|
|
|
|
|
|
| |
* [3.10] [Enum] improve test, add andrei kulakov to ACKS (GH-26726).
(cherry picked from commit cb2014f2077c92c35486bf0db7e646a68478a7a5)
Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
|
|
|
|
|
|
|
|
| |
BPO-42914 was not added to the What's New in GH-24864. This includes it in the "Improved Modules" section.
Automerge-Triggered-By: GH:gpshead
(cherry picked from commit 4846ea95d1a121df5e8081e2a290f63d1419cad8)
Co-authored-by: Wm. Keith van der Meulen <keith@wkeithvan.com>
|
|
|
|
|
|
|
|
|
| |
(GH-25967) (GH-26018)
(cherry picked from commit 2a031723eefcf6f1d678bbb4f6018610d43623c4)
Co-authored-by: dhoekstra2000 <douwe.hoekstra2512@gmail.com>
Co-authored-by: dhoekstra2000 <douwe.hoekstra2512@gmail.com>
|
|
|
|
|
|
|
| |
(GH-25947) (GH-25950)
(cherry picked from commit 329a47f0524e9d3f43f1e28c4f9e7c088662c030)
Co-authored-by: Linus Groh <mail@linusgroh.de>
|
|
|
|
|
|
|
|
|
|
| |
(#25893)
This documents in the tutorial docs the behavior of a finally clause in
case it should re-raise an exception but contains a
return/break/continue statement.
(cherry picked from commit a0b9915a8be98427432e13d8eb2207a8b9824179)
Co-authored-by: Roberto Hueso <robertohueso96@gmail.com>
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Accessing the following attributes will now fire PEP 578 style audit hooks as ("object.__getattr__", obj, name):
* PyTracebackObject: tb_frame
* PyFrameObject: f_code
* PyGenObject: gi_code, gi_frame
* PyCoroObject: cr_code, cr_frame
* PyAsyncGenObject: ag_code, ag_frame
Add an AUDIT_READ attribute flag aliased to READ_RESTRICTED.
Update obsolete flag documentation.
|
| |
|
|
|
|
|
| |
linear regression (#16813)
Co-authored-by: Tymoteusz Wołodźko <twolodzko+gitkraken@gmail.com
|
|
|
| |
Reported by Yahor Harunovich.
|
|
|
| |
This short PR exposes an openssl flag that wasn't exposed. I've also updated to doc to reflect the change. It's heavily inspired by 990fcaac3c428569697f62a80fd95ab4d4b93151.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Many servers in the cloud environment require SNI to be used during the
SSL/TLS handshake, therefore it is not possible to fetch their certificates
using the ssl.get_server_certificate interface.
This change adds an additional optional hostname argument that can be used to
set the SNI. Note that it is intentionally a separate argument instead of
using the host part of the addr tuple, because one might want to explicitly
fetch the default certificate or fetch a certificate from a specific IP
address with the specified SNI hostname. A separate argument also works better
for backwards compatibility.
Automerge-Triggered-By: GH:tiran
|
|
|
|
| |
* Add Arseny Boykov
* Add Matthias Urlichs
|
| |
|
| |
|
|
|
|
|
|
|
| |
bpo-43420: Implement standard transformations in + - * / that can often reduce the size of intermediate integers needed. For rationals with large components, this can yield dramatic speed improvements, but for small rationals can run 10-20% slower, due to increased fixed overheads in the longer-winded code. If those slowdowns turn out to be a problem, see the PR discussion for low-level implementation tricks that could cut other fixed overheads.
Co-authored-by: Tim Peters <tim.peters@gmail.com>
Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Flag members are now divided by one-bit verses multi-bit, with multi-bit being treated as aliases. Iterating over a flag only returns the contained single-bit flags.
Iterating, repr(), and str() show members in definition order.
When constructing combined-member flags, any extra integer values are either discarded (CONFORM), turned into ints (EJECT) or treated as errors (STRICT). Flag classes can specify which of those three behaviors is desired:
>>> class Test(Flag, boundary=CONFORM):
... ONE = 1
... TWO = 2
...
>>> Test(5)
<Test.ONE: 1>
Besides the three above behaviors, there is also KEEP, which should not be used unless necessary -- for example, _convert_ specifies KEEP as there are flag sets in the stdlib that are incomplete and/or inconsistent (e.g. ssl.Options). KEEP will, as the name suggests, keep all bits; however, iterating over a flag with extra bits will only return the canonical flags contained, not the extra bits.
Iteration is now in member definition order. If member definition order
matches increasing value order, then a more efficient method of flag
decomposition is used; otherwise, sort() is called on the results of
that method to get definition order.
``re`` module:
repr() has been modified to support as closely as possible its previous
output; the big difference is that inverted flags cannot be output as
before because the inversion operation now always returns the comparable
positive result; i.e.
re.A|re.I|re.M|re.S is ~(re.L|re.U|re.S|re.T|re.DEBUG)
in both of the above terms, the ``value`` is 282.
re's tests have been updated to reflect the modifications to repr().
|
| |
|
|
|
|
| |
There was a race condition in base64 in lazy initialization of multiple globals.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In Python 2, it was possible to use `except` with a nested tuple, and occasionally natural. For example, `zope.formlib.interfaces.InputErrors` is a tuple of several exception classes, and one might reasonably think to do something like this:
try:
self.getInputValue()
return True
except (InputErrors, SomethingElse):
return False
As of Python 3.0, this raises `TypeError: catching classes that do not inherit from BaseException is not allowed` instead: one must instead either break it up into multiple `except` clauses or flatten the tuple. However, the reference documentation was never updated to match this new restriction. Make it clear that the definition is no longer recursive.
Automerge-Triggered-By: GH:ericvsmith
|