summaryrefslogtreecommitdiffstats
path: root/Misc
Commit message (Collapse)AuthorAgeFilesLines
...
* bpo-42854: Correctly use size_t for _ssl._SSLSocket.read and ↵Miss Islington (bot)2021-07-231-0/+3
| | | | | | | | | _ssl._SSLSocket.write (GH-27271) (GH-27308) (cherry picked from commit 83d1430ee5b8008631e7f2a75447e740eed065c1) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com> Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* bpo-42747: Remove Py_TPFLAGS_HAVE_AM_SEND and make ↵Miss Islington (bot)2021-07-231-0/+4
| | | | | | | | | | | | | | | Py_TPFLAGS_HAVE_VERSION_TAG no-op (GH-27260) (GH-27306) * Remove code that checks Py_TPFLAGS_HAVE_VERSION_TAG The field is always present in the type struct, as explained in the added comment. * Remove Py_TPFLAGS_HAVE_AM_SEND The flag is not needed, and since it was added in 3.10 it can be removed now. (cherry picked from commit a4760cc32d9e5dac7be262e9736eb30502cd7be3) Co-authored-by: Petr Viktorin <encukou@gmail.com>
* bpo-29298: Fix crash with required subparsers without dest (GH-3680) (GH-27303)Miss Islington (bot)2021-07-231-0/+2
| | | | | (cherry picked from commit 17575f73ce2cb9f3a4eb4cc416c690f9a4e7205c) Co-authored-by: Anthony Sottile <asottile@umich.edu>
* bpo-44653: Support typing types in parameter substitution in the union type. ↵Miss Islington (bot)2021-07-221-0/+1
| | | | | | | (GH-27247) (#27296) (cherry picked from commit 2e3744d50b6e30ea24351e55b4352dcc58fd469e) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* bpo-44708: Only re-run test methods that match names of previously failing ↵Miss Islington (bot)2021-07-221-0/+2
| | | | | | | | | | | | | | test methods (GH-27287) (GH-27290) * Move to a static argparse.Namespace subclass * Roughly annotate runtest.py * Refactor libregrtest to use lossless test result objects * Only re-run test methods that match names of previously failing test methods * Adopt tests to cover test method name matching Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com> (cherry picked from commit f1afef5e0d93d66fbf3c9aaeab8b3b8da9617583) Co-authored-by: Łukasz Langa <lukasz@langa.pl>
* bpo-44704: Make Set._hash consistent with frozenset.__hash__ (GH-27281) ↵Miss Islington (bot)2021-07-221-0/+1
| | | | (GH-27282)
* bpo-30511: Add note on thread safety to shutil.make_archive() (GH-26933) ↵Miss Islington (bot)2021-07-211-0/+2
| | | | | | | | (GH-27274) Co-authored-by: Łukasz Langa <lukasz@langa.pl> (cherry picked from commit 64f54b7ccd49764b0304e076bfd79b5482988f53) Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
* bpo-44566: resolve differences between asynccontextmanager and ↵Miss Islington (bot)2021-07-201-0/+1
| | | | | | | contextmanager (GH-27024) (#27266) (cherry picked from commit 7f1c330da31c54e028dceaf3610877914c2a4497) Co-authored-by: Thomas Grainger <tagrain@gmail.com>
* bpo-44353: Refactor typing.NewType into callable class (GH-27250) (#27258)Miss Islington (bot)2021-07-201-0/+2
| | | | | (cherry picked from commit 965dd76e9060e27e2253ba8c8d21a142b178720d) Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com>
* bpo-44524: Add missed __name__ and __qualname__ to typing module objects ↵Miss Islington (bot)2021-07-191-0/+2
| | | | | | | | (GH-27237) (#27246) Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com> (cherry picked from commit bce1418541a64a793960182772f985f64afbfa1a) Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com>
* bpo-27513: email.utils.getaddresses() now handles Header objects (GH-13797) ↵Miss Islington (bot)2021-07-191-0/+3
| | | | | | | | | | | (GH-27242) getaddresses() should be able to handle a Header object if passed one. Co-authored-by: Łukasz Langa <lukasz@langa.pl> (cherry picked from commit 89f4c34797de2f0e5045da2b97c1c8cbbb42fbb2) Co-authored-by: Zackery Spytz <zspytz@gmail.com>
* bpo-44490: Improve typing module compatibility with types.Union (GH-27048) ↵Ken Jin2021-07-191-0/+3
| | | | | | | (#27222) (cherry picked from commit bf89ff96e6ba21bb52b8597b5e51e8ffc57e6589) Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com>
* [3.10] bpo-44561: Update hyperlinks in Doc/distributing/index.rst (GH-27032) ↵Miss Islington (bot)2021-07-191-0/+3
| | | | | | | | | | | | | | | (GH-27234) * Update hyperlinks in Doc/distributing/index.rst Update three expired hyperlinks. Closes [bpo-44561](). (cherry picked from commit b494685b2548489efcc66993cc6c13b027ce3b26) Co-authored-by: Steven Hsu <hsuhaochun@gmail.com> Automerge-Triggered-By: GH:ncoghlan
* bpo-44633: Fix parameter substitution of the union type with wrong types. ↵Miss Islington (bot)2021-07-181-0/+2
| | | | | | | | | (GH-27218) (GH-27224) A TypeError is now raised instead of returning NotImplemented. (cherry picked from commit 3ea5332a4365bdd771286b3e9692495116e9ceef) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* [3.10] bpo-44490: Add __parameters__ and __getitem__ to types.Union ↵Serhiy Storchaka2021-07-171-0/+2
| | | | | | | | | | | (GH-26980) (GH-27207) Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com> Co-authored-by: Guido van Rossum <gvanrossum@gmail.com>. (cherry picked from commit c45fa1a5d9b419cf13ad4b5a7cb453956495b83e) Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com> Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
* bpo-41249: Fix postponed annotations for TypedDict (GH-27017) (#27204)Miss Islington (bot)2021-07-171-0/+2
| | | | | | | | | | This fixes TypedDict to work with get_type_hints and postponed evaluation of annotations across modules. This is done by adding the module name to ForwardRef at the time the object is created and using that to resolve the globals during the evaluation. Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com> (cherry picked from commit 889036f7ef7290ef15b6c3373023f6a35387af0c) Co-authored-by: Germán Méndez Bravo <german.mb@gmail.com>
* bpo-44655: Include the name of the type in unset __slots__ attribute errors ↵Miss Islington (bot)2021-07-171-0/+2
| | | | | | | | | (GH-27199) (GH-27201) (cherry picked from commit f783428a2313a729ca8b539c5a86ff114b9ff375) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com> Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* bpo-44655: Don't include suggestions for attributes that are the same as the ↵Miss Islington (bot)2021-07-161-0/+2
| | | | | | | missing one (GH-27197) (GH-27198) (cherry picked from commit 6714dec5e104bdee4a0ed4d9966de27d1bfa1e3d) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* bpo-44647: Add a permanent Unicode-valued env var to regrtest (GH-27187) ↵Miss Islington (bot)2021-07-161-0/+4
| | | | | | | (#27191) (cherry picked from commit 7915c96ffd7ddc5cb6d54015ee4c31255a416892) Co-authored-by: Łukasz Langa <lukasz@langa.pl>
* bpo-40897:Give priority to using the current class constructor in ↵Miss Islington (bot)2021-07-161-0/+2
| | | | | | | | `inspect.signature` (GH-27177) (#27189) Co-authored-by: Łukasz Langa <lukasz@langa.pl> (cherry picked from commit 6aab5f9bf303a8e4cd8377fabcdcb499e0541f9a) Co-authored-by: Weipeng Hong <hongweichen8888@sina.com>
* [3.10] bpo-44636: Collapse union of equal types (GH-27178) (GH-27181)Serhiy Storchaka2021-07-161-0/+1
| | | | | | | | The result of `int | int` is now `int`. Fix comparison of the union type with non-hashable objects. `int | str == {}` no longer raises a TypeError. (cherry picked from commit d9f923280f204204f8703756aef4f655b579b4b8)
* bpo-44646: Fix the hash of the union type. (GH-27179) (#27180)Miss Islington (bot)2021-07-161-0/+2
| | | | | | | | | It no longer depends on the order of arguments. hash(int | str) == hash(str | int) Co-authored-by: Jack DeVries <58614260+jdevries3133@users.noreply.github.com> (cherry picked from commit aeaa553d650786afc6e68df1f4813ae1a5b71d05) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* bpo-42073: allow classmethod to wrap other classmethod-like descriptors ↵Miss Islington (bot)2021-07-151-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (GH-27115) (GH-27162) Patch by Erik Welch. bpo-19072 (GH-8405) allows `classmethod` to wrap other descriptors, but this does not work when the wrapped descriptor mimics classmethod. The current PR fixes this. In Python 3.8 and before, one could create a callable descriptor such that this works as expected (see Lib/test/test_decorators.py for examples): ```python class A: @myclassmethod def f1(cls): return cls @classmethod @myclassmethod def f2(cls): return cls ``` In Python 3.8 and before, `A.f2()` return `A`. Currently in Python 3.9, it returns `type(A)`. This PR make `A.f2()` return `A` again. As of GH-8405, classmethod calls `obj.__get__(type)` if `obj` has `__get__`. This allows one to chain `@classmethod` and `@property` together. When using classmethod-like descriptors, it's the second argument to `__get__`--the owner or the type--that is important, but this argument is currently missing. Since it is None, the "owner" argument is assumed to be the type of the first argument, which, in this case, is wrong (we want `A`, not `type(A)`). This PR updates classmethod to call `obj.__get__(type, type)` if `obj` has `__get__`. Co-authored-by: Erik Welch <erik.n.welch@gmail.com> (cherry picked from commit b83861f0265e07207a6ae2c49c40fa8f447893f2)
* Fix osx_framework_user include to match distutils (GH-27093) (GH-27159)Miss Islington (bot)2021-07-151-0/+2
| | | | | (cherry picked from commit 28544609cb2a79d8d7ea5a54714d723669ef2adb) Co-authored-by: Tzu-ping Chung <uranusjr@gmail.com>
* [3.10] bpo-44635: Convert None to NoneType in the union type constructor ↵Serhiy Storchaka2021-07-151-0/+1
| | | | | | (GH-27136). (GH-27142) (cherry picked from commit b81cac05606c84958b52ada09f690463a3c7e949)
* [3.10] bpo-44589: raise a SyntaxError when mapping patterns have duplicate ↵Miss Islington (bot)2021-07-151-0/+2
| | | | | | | | | | literal keys (GH-27131) (GH-27157) (cherry picked from commit 2693132292b2acf381ac6fa729bf3acf41d9d72b) Co-authored-by: Jack DeVries <58614260+jdevries3133@users.noreply.github.com> Automerge-Triggered-By: GH:brandtbucher
* bpo-34932: Add socket.TCP_KEEPALIVE for macOS (GH-25079)Miss Islington (bot)2021-07-141-0/+1
| | | | | (cherry picked from commit d59d7374a364c4e5c2b9a83d8e4543ee494285b8) Co-authored-by: Shane Harvey <shnhrv@gmail.com>
* bpo-44608: Fix memory leak in _tkinter._flatten() (GH-27107)Miss Islington (bot)2021-07-141-0/+2
| | | | | | if it is called with a sequence or set, but not list or tuple. (cherry picked from commit f572cbf1faab33d9afbbe3e95738ed6fbe6e48e6) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* bpo-44606: Fix __instancecheck__ and __subclasscheck__ for the union type. ↵Miss Islington (bot)2021-07-141-0/+1
| | | | | | | | | | | | (GH-27120) * Fix issubclass() for None. E.g. issubclass(type(None), int | None) returns now True. * Fix issubclass() for virtual subclasses. E.g. issubclass(dict, int | collections.abc.Mapping) returns now True. * Fix crash in isinstance() if the check for one of items raises exception. (cherry picked from commit 81989058de381108dfd0a4255b93d4fb34417002) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* bpo-44572: On Windows, disconnect STDIN in platform._syscmd_ver() to prevent ↵Miss Islington (bot)2021-07-131-0/+1
| | | | | | | erroneous STDIN consumption (GH-27092) (GH-27124) (cherry picked from commit 0ee0a740e12ec8568aafa033aa6bb08b265afe26) Co-authored-by: Konstantin-Glukhov <glukhov.k@gmail.com>
* bpo-38741: Definition of multiple ']' in header configparser (GH-17129) (#27110)Miss Islington (bot)2021-07-131-0/+1
| | | | | | | Co-authored-by: Jason Killen <jason.killen@windsorcircle.com> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> (cherry picked from commit 2924bb1a566977efd45f335d6a94cd84d8047edf) Co-authored-by: jsnklln <jsnklln@gmail.com>
* bpo-44472: Fix ltrace functionality when exceptions are raised (GH-26822) ↵Miss Islington (bot)2021-07-131-0/+1
| | | | | | | | | (GH-26830) (cherry picked from commit 06cda808f149fae9b4c688f752b6eccd0d455ba4) Co-authored-by: Pablo Galindo <Pablogsal@gmail.com> Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
* bpo-44613: Make importlib.metadata non-provisional (GH-27101) (#27106)Miss Islington (bot)2021-07-131-0/+1
| | | | | | | | | * importlib.metadata is no longer provisional as of 3.10 * Add NEWS entry (cherry picked from commit f6954cdfc50060a54318fb2aea4d80408381243a) Co-authored-by: Barry Warsaw <barry@python.org> Co-authored-by: Barry Warsaw <barry@python.org>
* [Enum] add news entry for enum module reversion (GH-27099)Ethan Furman2021-07-121-0/+1
|
* bpo-43219: shutil.copyfile, raise a less confusing exception instead of ↵Miss Islington (bot)2021-07-101-0/+4
| | | | | | | | IsADirectoryError (GH-27049) Fixes the misleading IsADirectoryError to be FileNotFoundError. (cherry picked from commit 248173cc0483a9ad9261353302f1234cf9eb2ebe) Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
* Python 3.10.0b4v3.10.0b4Pablo Galindo2021-07-1044-85/+437
|
* bpo-44317: Improve tokenizer errors with more informative locations ↵Miss Islington (bot)2021-07-101-0/+1
| | | | | | | (GH-26555) (GH-27079) (cherry picked from commit f24777c2b329974b69d2a3bf5cfc37e0fcace36c) Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com>
* [3.10] bpo-44446: support lineno being None in traceback.FrameSummary ↵Pablo Galindo2021-07-081-0/+1
| | | | | | | | | | | | | (GH-26781) (GH-27072) As of 088a15c49d99ecb4c3bef93f8f40dd513c6cae3b, lineno is None instead of -1 if there is no line number. Signed-off-by: Filipe Laíns <lains@riseup.net>. (cherry picked from commit 91a8f8c16ca9a7e2466a8241d9b41769ef97d094) Co-authored-by: Filipe Laíns <lains@riseup.net> Co-authored-by: Filipe Laíns <lains@riseup.net>
* bpo-44582: Accelerate mimetypes.init on Windows with a native accelerator ↵Miss Islington (bot)2021-07-081-0/+2
| | | | | | | (GH-27059) (cherry picked from commit bbf2fb6c7ae78f40483606f467739a58cd747270) Co-authored-by: Steve Dower <steve.dower@python.org>
* bpo-44558: Match countOf `is`/`==` treatment to c (GH-27007)Miss Islington (bot)2021-07-071-0/+2
| | | | | (cherry picked from commit 6bd3ecfc272b122b55a6adec50dd7a7c868f262f) Co-authored-by: Rupert Tombs <rupert.tombs@gmail.com>
* bpo-44558: Make the implementation consistency of operator.indexOf (GH-27012)Miss Islington (bot)2021-07-051-0/+2
| | | | | (cherry picked from commit 09302405d22e86884d6058226790c0cdf5b72f14) Co-authored-by: Dong-hee Na <donghee.na@python.org>
* bpo-41486: zlib uses an UINT32_MAX sliding window for the output buffer ↵Miss Islington (bot)2021-07-051-0/+3
| | | | | | | | | | | | | | | | | | | (GH-26143) * zlib uses an UINT32_MAX sliding window for the output buffer These funtions have an initial output buffer size parameter: - zlib.decompress(data, /, wbits=MAX_WBITS, bufsize=DEF_BUF_SIZE) - zlib.Decompress.flush([length]) If the initial size > UINT32_MAX, use an UINT32_MAX sliding window, instead of clamping to UINT32_MAX. Speed up when (the initial size == the actual size). This fixes a memory consumption and copying performance regression in earlier 3.10 beta releases if someone used an output buffer larger than 4GiB with zlib.decompress. Reviewed-by: Gregory P. Smith (cherry picked from commit a9a69bb3ea1e6cf54513717212aaeae0d61b24ee) Co-authored-by: Ma Lin <animalize@users.noreply.github.com>
* bpo-44562: Remove invalid PyObject_GC_Del from error path of ↵Miss Islington (bot)2021-07-041-0/+2
| | | | | | | types.GenericAlias … (GH-27016) (cherry picked from commit d33943a6c368c2184e238019c63ac7a267da5594) Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
* [3.10] bpo-34266: [pdb] handle ValueError from shlex.split() (GH-26656) ↵Irit Katriel2021-07-031-0/+1
| | | | | | | (GH-27006) (cherry picked from commit d968a638fcbf9030c999cfacd4c9bf0656e779c4) Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
* bpo-44553 : Implement GC methods for types.Union (GH-26993)Miss Islington (bot)2021-07-031-0/+2
| | | | | (cherry picked from commit 1097384ce964dd63686b1aac706cd0fa764c2dc9) Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
* [3.10] bpo-30256: [doc] Fix formatting error in news (GH-26994) (GH-26998)Irit Katriel2021-07-021-1/+1
|
* bpo-34798: [doc] clearer presentation of pprint.PrettyPrinter constru… ↵Miss Islington (bot)2021-07-021-0/+1
| | | | | | | (GH-26967) (GH-26990) (cherry picked from commit 943e77d42d3f84b581f32c05f1fc8c05366b8ed3) Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
* bpo-30256: Add manager_owned keyword arg to AutoProxy (GH-16341) (#26987)Miss Islington (bot)2021-07-022-0/+3
| | | | | | | Co-authored-by: Jordan Speicher <jordan@jspeicher.com> (cherry picked from commit 85b920498b42c69185540ecc2f5c4907fd38d877) Co-authored-by: finefoot <33361833+finefoot@users.noreply.github.com>
* bpo-44535: Enable building with Visual Studio 2022 on Windows (GH-26962)Miss Islington (bot)2021-06-301-0/+1
| | | | | (cherry picked from commit d3a95c1b6eacbbbd92c294744e7ed41932f3f63e) Co-authored-by: Steve Dower <steve.dower@python.org>
* bpo-41180: Replace marshal code.__new__ audit event with marshal.load[s] and ↵Steve Dower2021-06-301-0/+5
| | | | marshal.dumps (GH-26970)