Commit Graph

4553 Commits

Author SHA1 Message Date
Alex Waygood
67f377898b Add process_group argument to subprocess.{run, call, check_call, check_output} (#8125) 2022-06-21 07:44:20 -07:00
Alex Waygood
0740d1c48e asyncio.gather: Add overload for if no positional arguments are provided (#8126) 2022-06-21 15:31:40 +01:00
Alex Waygood
a01e0260b3 Add pipesize argument to subprocess.{run, call, check_call, check_output} (#8124) 2022-06-21 05:59:26 -07:00
Alex Waygood
cad42c7c7b asyncio.gather: Remove default values for return_exceptions: bool overloads (#8123) 2022-06-21 05:57:06 -07:00
Alex Waygood
f9e24680c3 Add new-in-3.9 parameters to subprocess.{run, call, check_call, check_output} (#8071) 2022-06-21 04:35:50 -07:00
KotlinIsland
35a59f6aa7 typing.AwaitableGenerator: add type_check_only (#8115) 2022-06-20 21:01:09 -07:00
Alex Waygood
c6de37df53 Overhaul socket stubs on Windows and MacOS (#8106)
Reduce the `socket` allowlists for these platforms to a handful of missing constants
2022-06-20 20:11:50 +01:00
Alex Waygood
538621e91b unittest.case: tighter annotations for various assertions (#8077) 2022-06-20 18:49:57 +02:00
Lefteris Karapetsas
01efba913f dbapi2 set_progress_handler should return integer (#8109)
dbapi2 set_progress_handler callback should return an int according to the
stdlib documentation: https://docs.python.org/3/library/sqlite3.html#sqlite3.Connection.set_progress_handler

Fixes #8105
2022-06-20 13:42:58 +02:00
Shantanu
34579f1edf socket: add TCP_KEEPALIVE (#8100)
bpo-34932

Co-authored-by: hauntsaninja <>
2022-06-19 17:57:07 +01:00
Alex Waygood
411d85feeb socket.AddressFamily: Fix AF_LINK (#8103)
Slipped through the net in #8099
2022-06-19 09:10:33 +01:00
Shantanu
b7f8d847be socket: consistency between constants and enums (#8099)
This matches what happens at runtime, from Enum._convert_
Helps with #8098. Closes #5696.
2022-06-19 08:57:55 +01:00
John Villalovos
fc69e0053a imaplib: fix exception types (#8095)
Closes #8094
2022-06-17 23:45:10 -07:00
Alex Waygood
6b0c8df9ec Upgrade pyright, improve pyright config files (#8072) 2022-06-16 18:50:50 +01:00
Prometheus3375
91d6383d9d Change return type of XMLPullParser.read_events() (#8076) 2022-06-14 19:15:29 +01:00
Alex Waygood
01d5e28ff7 Fix miscellaneous invalid TypeVar usages (#8074) 2022-06-14 08:48:41 -07:00
Alex Waygood
4941ac0263 Use the Any trick for xml.etree.ElementTree.getroot() (#8069)
Closes #7770
2022-06-14 18:31:19 +03:00
Alex Waygood
5add91d6bb unittest: Improve self.assert(Not)AlmostEqual(s) (#8066) 2022-06-14 18:24:51 +03:00
Alex Waygood
60c2733ca8 subprocess.(check_)call: add text argument new in 3.7 (#8070) 2022-06-14 01:54:16 +01:00
Alex Waygood
1828ba2045 builtins.sum: Items in the iterable must support addition with int if no start value is given (#8000) 2022-06-13 11:25:38 +01:00
Alex Waygood
67828bd598 xml.etree.ElementTree.Element: remove inheritance from MutableSequence (#8056) 2022-06-13 12:22:28 +02:00
Alex Waygood
1be5918baa Use _typeshed.IdentityFunction more consistently (#8063) 2022-06-12 16:56:14 -07:00
Alex Waygood
1aa5663f9e Add __setattr__ to logging.LogRecord (#8064) 2022-06-12 12:04:22 -07:00
Oleg Höfling
8bb18aa541 add undocumented attributes for threading.Timer (#8059) 2022-06-12 20:34:56 +03:00
Alex Waygood
55eb19d1bd Improve csv.DictReader (#8061) 2022-06-12 17:02:05 +03:00
Alex Waygood
b5802d0bbe Add tkinter._test (#8062)
Fixes #7903
2022-06-12 16:58:39 +03:00
Alex Waygood
16281bb04f Improve turtle.Vec2D (#8058)
Co-authored-by: Akuli <akuviljanen17@gmail.com>
2022-06-12 15:53:14 +03:00
Kyle Altendorf
a750a42c65 Remove Generic from sqlite3.Row (#8036)
Introduced in https://github.com/python/typeshed/pull/7641.  Removal discussed at https://github.com/python/typeshed/issues/8027.
2022-06-11 06:53:22 -07:00
Pamela Fox
b4c3e2c3e1 Concrete return type for SymbolTable.get_identifiers (#8054) 2022-06-10 17:20:50 +02:00
Lee
8f77471d62 tkinter: remove unnecessary _MenuIndex TypeAlias (#8023) 2022-06-08 09:23:54 +01:00
Alex Waygood
e7a5b7a762 Fix various __all__-related errors and omissions (#8031) 2022-06-07 23:29:55 +01:00
Alex Waygood
591593c85f Simplify __all__ for modules beginning with 'm' to 't' (#8028) 2022-06-07 20:14:15 +01:00
Alex Waygood
b88ea4a499 Simplify __all__ for unittest and xml.etree (#8029) 2022-06-07 12:03:52 -07:00
Alex Waygood
e88a182573 Simplify __all__ definitions in modules beginning with 'a' to 'l' (#8026) 2022-06-07 15:40:48 +02:00
Sebastian Rittau
214bf15dce Use "all +=" instead of duplicating the branches (#7865) 2022-06-07 13:32:19 +02:00
Alex Waygood
9db96967cc asyncio.sslproto: More updates for py311 (#8022)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-06-06 15:12:22 -07:00
Alex Waygood
43a9ab08d7 Always use TypeAlias when assigning to Any (#8021) 2022-06-05 18:16:20 -07:00
Jim Bosch
a2ba0c8a00 use __new__ instead of __init__ for frozenset (#8019) 2022-06-04 08:31:13 -07:00
Alex Waygood
0ce825b5a8 Add unittest features new in Python 3.11 (#8020)
python/cpython@086c6b1
2022-06-04 16:27:52 +01:00
Lee
87893f3512 tkinter: annotate Listbox. (#8006)
Co-authored-by: Akuli <akuviljanen17@gmail.com>
2022-06-03 18:08:03 +03:00
Jelle Zijlstra
56c8cbb314 Add GenericAlias.__typing_unpacked_tuple_args__ (#8015)
Fixes #8014 

python/cpython#92484
2022-06-03 08:26:41 +01:00
Alex Waygood
acc0167dc1 Fix several new-in-3.11 stubtest errors (#7973) 2022-06-02 18:07:38 -07:00
Alex Waygood
6355cba923 Python 3.11: re.TEMPLATE is back in beta 2 (#8007) 2022-06-01 14:50:37 +02:00
Graham Bleaney
8c434e05d6 Add PEP 675 LiteralString overloads to str class (#7725)
Co-authored-by: Sebastian Rittau <srittau@rittau.biz>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
2022-05-31 21:09:34 -07:00
pranavrajpal
8f33ff9e9d Add __setstate__ for BaseException (#7987) 2022-05-30 11:33:55 +02:00
hamdanal
b151e0c5a7 Make usage in argparse.HelpFormatter._format_usage optional (#7983)
closes #7982
2022-05-29 15:21:20 -07:00
Alex Waygood
d4eba8b5ce builtins.sum: Add overload for bool special case (#7975)
Closes #7974
2022-05-28 11:14:10 -07:00
Alex Waygood
ceccc655db Introduce _typeshed.GenericPath and _typeshed.AnyStr_co (#7970) 2022-05-27 19:02:00 +01:00
Jelle Zijlstra
c35ec8ba89 contextlib: Remove explicit base class from ExitStack (#7963)
Fixes #7961
2022-05-27 09:19:18 -07:00
Alex Waygood
c05731c46f tempfile.pyi: readability improvements (#7959)
The name `_DirT` implies that it is a `TypeVar`, but it isn't; it's a generic `TypeAlias` that can be parameterised with a `TypeVar`. Rename it to just `_Dir` instead.

Also, use aliases instead of repeating incredibly long Literal annotations six times.
2022-05-27 08:52:44 +01:00