Commit Graph

3585 Commits

Author SHA1 Message Date
Akuli
8454a48c5e allow file descriptors in os.stat wrapper functions (#6198) 2021-10-25 13:00:27 +03:00
ROHAN SALWAN
e38248e818 Fix type of importlib.machinery.ModuleSpec.loader (#6194) 2021-10-25 12:59:49 +03:00
Akuli
739cc27cc4 fix shutil.disk_usage() argument type (#6197) 2021-10-25 11:52:04 +02:00
ROHAN SALWAN
766f7e76ec Fix subprocess.list2cmdline: wrong type of the seq argument (#6190) 2021-10-25 12:06:55 +03:00
Bas van Beek
e4fa30e840 Use string literals for typing warnings actions (#6192) 2021-10-23 13:44:05 +02:00
Sebastian Rittau
b3f29b619b Remove unnecessary _Collection alias (#6188)
This was a remnant of Python 3.5 compatibility, where Collection did not
exists and _Collection was aliased to a dummy class.
2021-10-22 12:32:35 -07:00
Kyle Altendorf
12dd8d9718 AbstractEventLoop.run_in_executor() returns Future (#6187)
https://docs.python.org/3.10/library/asyncio-eventloop.html#asyncio.loop.run_in_executor
> This method returns a asyncio.Future object.
2021-10-22 10:50:42 -07:00
Akuli
53087be4eb get rid of tkinter._TkinterSequence type alias (#6181) 2021-10-18 10:22:01 +02:00
Akuli
5b03ad18cc tkinter.ttk.Treeview: more Literal[""] (#6182) 2021-10-16 18:41:52 +02:00
Omer Ozarslan
f3a345493c Make argparse._SubParsersAction generic (#6178) 2021-10-16 00:36:46 +03:00
Hasan Ramezani
3ba8c50d92 Add some attributes to http.client.HTTPResponse (#6176) 2021-10-15 16:46:39 +03:00
Akuli
994b69ef8f Use lowercase tuple where possible (#6170) 2021-10-14 17:18:19 -07:00
Jelle Zijlstra
5f386b0575 Make args to AsyncContextManager.__aexit__ positional-only (#6172)
We already do this for `ContextManager.__exit__`. Should fix microsoft/pyright#2435.
2021-10-14 17:15:57 -07:00
Marti Raudsepp
c38c03bab8 builtins: next() does not allow keyword args for default (#6169) 2021-10-14 09:51:58 +02:00
Akuli
75ca712f3c check_new_syntax.py: check nested annotations (#6167) 2021-10-14 00:28:38 +03:00
Akuli
e72a4034bf Cleanup: use lower-case list and dict, add a test (#6161) 2021-10-13 22:59:27 +03:00
Stefan Tatschner
7720f9b7df Add CAN_RAW_JOIN_FILTERS constant to socket stub (#6159)
This constant has been added in python 3.9.
2021-10-13 16:29:03 +02:00
Kevin Rose
3c8c2519b4 Fix small issues in ftplib (#6154) 2021-10-12 18:51:52 -07:00
David Robertson
498f1aa41d Mark sqlite3.Cursor.rowcount as an int (#6150) 2021-10-11 14:54:30 +02:00
Anton Grübel
e3ae2e9291 Add missing items and types in site.pyi (#6142)
Use `set` instead of `Iterable` for `known_paths` argument
2021-10-11 12:11:24 +02:00
KotlinIsland
b7d1d099d9 add TypeGuard to coroutines.iscoroutine (#6105)
make CoroutineType extend Coroutine
2021-10-09 17:01:36 +02:00
Théo Cavignac
e018ad66dc General object for sys.ps1 and sys.ps2 (#6139) 2021-10-09 15:38:39 +03:00
EXPLOSION
ca983cd319 Allow empty strings for show in tkinter.ttk.Treeview (#6135) 2021-10-09 11:17:02 +03:00
hardikpnsp
ee31999caf Add missing methods to ExtensionFileLoader (#6120)
Closes: #4769
2021-10-08 23:14:32 +02:00
Nikita Sobolev
373c4e582a traceback can be None in sys.excepthook (#6133) 2021-10-08 09:17:32 +00:00
Đỗ Quốc Vương
3c58736d01 Change type of backupCount from str to int (#6128) 2021-10-07 15:31:53 +02:00
Shantanu
55cf343ba9 zip: update for PEP 618 (#6123)
Resolves #6122

Co-authored-by: hauntsaninja <>
2021-10-06 12:54:47 -07:00
Kevin Rose
98dde9c364 Mark some contextlib method arguments as positional-only (#6118) 2021-10-05 19:41:52 -07:00
Kevin Rose
47e9788246 Add the rest of string.Template's class attributes (#6109) 2021-10-05 18:26:34 +02:00
Jake Bailey
b9ea346c14 Use overrides for IntFlag dunder-r methods (#6114) 2021-10-04 18:00:36 -07:00
Jake Bailey
4707e1d763 Fix use of unexported Pool type in multiprocessing.pool (#6111) 2021-10-04 17:20:24 -07:00
Anton Grübel
5f1adbfbd2 Add missing property in urllib.response, fix code types (#6108) 2021-10-04 16:01:33 -07:00
Peter Law
9b86402c77 pickle: use protocols instead of IO[bytes] (#6101) 2021-10-02 11:32:16 +03:00
Matthew Suozzo
947e851cf8 Remove typevar in mock.patch.multiple (#6090) 2021-09-30 19:14:10 +02:00
MapleCCC
b04512eaaa Fix return type of st2tuple() and STType.totuple() (#6091) 2021-09-30 09:35:38 +02:00
hardikpnsp
fe4062af54 Fix "value" types in dump and dumps (#6085) 2021-09-29 15:07:29 +02:00
Kumar Aditya
25ae5b8871 Add __await__, name, qualname to CoroutineType (#6087) 2021-09-29 14:07:09 +02:00
Matthew Suozzo
9efd6521be Fix unittest.mock.patch class decorator annotation. (#6070) 2021-09-29 09:27:47 +02:00
Luciano Ramalho
b99ddc1f2f change chained maps to MutableMapping (#6044)
Fixes #6042
2021-09-28 21:18:50 -07:00
Nikita Sobolev
4ac969ad2c Fixes __init__ of typing.NamedTuple (#6080)
Closes #6079
2021-09-28 20:42:27 -07:00
Zac Hatfield-Dodds
7cc5eb2950 StackSummary.extract() takes an Iterable (#6084) 2021-09-28 09:24:54 +02:00
Vincent Pelletier
4c0dccac0f Fold remaining custom stdlib *Buffer types into _typeshed. (#6082)
Add ctypes base type to WriteableBuffer.
Add a ReadOnlyBuffer type from fcntl.
Base ReadableBuffer on WriteableBuffer and ReadOnlyBuffer.
Use these types in fcntl and ctypes stubs.
2021-09-28 09:15:26 +02:00
Ju4tCode
328d09a9a5 Fix error type for inspect Parameter/Signature empty (#6073) 2021-09-27 13:49:22 +02:00
Nikita Sobolev
3bc309daaa Adds AM_STR and PM_STR to locale.py (#6065) 2021-09-24 10:51:33 +02:00
Estelle Poulin
15cec1da8e Change Traversable to be inline with pathlib.Path (#5818)
`pathlib.Path` objects are now valid `importlib.abc.Traversable`s.
2021-09-21 21:36:10 +03:00
Akuli
196f69b27e dict.__init__: support dict(string.split(sep) for string in iterable) (#6050) 2021-09-20 13:52:41 +02:00
KotlinIsland
1b5c4e1d57 Add support for dict.{keys,values,items}.mapping (#6039)
Co-authored-by: KotlinIsland <kotlinisland@users.noreply.github.com>
2021-09-19 22:30:14 -07:00
Anton Grübel
caa642dd3b improve typing in inspect (#6020) 2021-09-18 20:11:55 -07:00
Rebecca Chen
d74a5a9ef8 Add undocumented attribute multiprocessing.process.BaseProcess._identity (#6041)
A user filed an issue against pytype about this attribute being missing:
https://github.com/google/pytype/issues/1010. I determined its type from
the source code:
https://github.com/python/cpython/blob/3.9/Lib/multiprocessing/process.py.
2021-09-17 13:14:07 -07:00
SupImDos
e4c2c0f302 Add SysLogHandler.address attribute (#6037) 2021-09-14 13:58:02 +02:00