Shantanu and GitHub
f4787297e9
ast: update for py38 ( #3698 )
2020-02-01 09:25:56 -08:00
Shantanu and GitHub
1ca071a732
collections.Counter: fix default values, allow passing None ( #3699 )
2020-02-01 09:25:03 -08:00
Shantanu and GitHub
4d698711ea
various errors: fix base class ( #3702 )
2020-02-01 09:15:23 -08:00
Brian Maissy and GitHub
48d77d5f06
update SectionProxy.getint()/float/bool stubs to match those of ConfigParser ( #3687 )
2020-01-30 09:37:29 +01:00
Brian Maissy and GitHub
e5999ac76b
make stubs for configparser.getint()/float/bool accept a generically-typed fallback ( #3684 )
...
Closes #3681
2020-01-29 14:43:46 +01:00
Jan Verbeek and GitHub
95cafc0b7c
sys: Correct types of sys.displayhook, sys.excepthook and variants ( #3673 )
...
displayhook should accept any object, not just integers.
displayhook and excepthook may be assigned to, so they should be
Callable values rather than function definitions. That way it's fine
to assign a function with different argument names. Their dunder
variants are supposed to be constant.
2020-01-29 11:25:35 +01:00
Shantanu and GitHub
46d9b38fa1
json: mark kwonly args, improve decode ( #3679 )
...
* json: mark args as kwonly for py36 on
* json: add undocumented arg to JSONDecoder.decode
2020-01-29 11:20:08 +01:00
Shantanu and GitHub
437b6947eb
dbm: mark positional-only args ( #3674 )
2020-01-29 11:03:55 +01:00
Niklas Fiekas and Jelle Zijlstra
64fea9c543
asyncio: get_returncode() and get_pipe_transport() can return None ( #3663 )
2020-01-26 12:38:11 -08:00
Oleg Höfling and Sebastian Rittau
99d79696d7
accept optional extras in asyncio.BaseTransport init ( #3661 )
...
Signed-off-by: Oleg Höfling <oleg.hoefling@gmail.com >
2020-01-26 15:48:44 +01:00
Jason Gilholme and Sebastian Rittau
76b295a669
subprocess: Make stdin, stdout & stderr Optional for py3 to match py2 ( #3652 )
...
Closes : #3646
2020-01-26 15:21:58 +01:00
Shantanu and Sebastian Rittau
b972427ad4
configparser: fix various arguments ( #3632 )
...
* configparser: fix various arguments
* configparser.ConfigParser: inherit __init__
2020-01-26 13:51:04 +01:00
Shantanu and Jelle Zijlstra
fd7855185e
_thread: fix type of TIMEOUT_MAX ( #3657 )
2020-01-25 20:00:55 -08:00
Shantanu and Sebastian Rittau
d5851eca6f
io: minor fixes for arguments ( #3642 )
2020-01-24 09:22:19 +01:00
Shantanu and Sebastian Rittau
b732342333
subprocess: add endtime for py36 and below ( #3641 )
2020-01-23 15:11:54 +01:00
Shantanu and Sebastian Rittau
cae73edebf
http.cookies: add LegalChars for py36 and below ( #3639 )
2020-01-23 15:05:49 +01:00
Shantanu and Sebastian Rittau
7e6dbc4393
asyncio: fix various version availability ( #3638 )
2020-01-23 15:04:04 +01:00
Shantanu and Sebastian Rittau
8b241b5243
asyncio: fix SendfileNotAvailableError availability ( #3631 )
2020-01-22 17:27:58 +01:00
Shantanu and Sebastian Rittau
e3dfaa6608
hashlib: fix arguments ( #3626 )
...
* hashlib: fix argument names
* hashlib: add default values to scrypt, make args Optional
2020-01-22 10:20:40 +01:00
Shantanu and Jelle Zijlstra
e048dd2b3b
heapq: fix arguments ( #3645 )
...
* heapq: mark positional-only args
* heapq: fix types for args with default value None
2020-01-21 17:52:38 -08:00
Shantanu and Sebastian Rittau
b374154705
operator: mark positional-only args ( #3628 )
2020-01-20 09:01:02 +01:00
Shantanu and Sebastian Rittau
ba8b2585c6
ast: some fixes for py38 ( #3625 )
...
* ast: make parse args keyword-only
* ast: get_source_segment is py38 on
2020-01-20 08:50:59 +01:00
Andrew Svetlov and Sebastian Rittau
dfe289e43b
Fix local_addr type ( #3622 )
2020-01-19 19:32:20 +01:00
Shantanu and Sebastian Rittau
cc58bb0cb1
platform: update for py38 ( #3619 )
2020-01-16 19:13:00 +01:00
Alan Du and Sebastian Rittau
42d68dd765
Use overloads for more precise get_context type ( #3605 )
2020-01-15 18:43:46 +01:00
Erick and Sebastian Rittau
394ee4a9ae
added f_fsid: int to os.statvfs_result for >= 3.7 ( #3608 )
2020-01-13 20:08:59 +01:00
Anthony Sottile and Sebastian Rittau
910cfe4b83
Add msvcrt.locking() and associated constants ( #3607 )
2020-01-11 17:23:41 +01:00
Shantanu and Sebastian Rittau
b8299bd58a
http: update for py38 ( #3606 )
...
* http: add UNAVAILABLE_FOR_LEGAL_REASONS
* http.cookiejar: filename parameter now supports path-like
2020-01-11 17:20:46 +01:00
Rebecca Chen and Sebastian Rittau
3b3fc6a57f
Make os.statvfs_result inherit from typing.NamedTuple. ( #3603 )
2020-01-10 22:42:29 +01:00
Shantanu and Jelle Zijlstra
b25454a76c
signal: update for py38 ( #3602 )
2020-01-10 12:12:08 -08:00
Benjamin Peterson and Sebastian Rittau
fe236ed8b2
Add unittest.result.failfast. ( #3596 )
2020-01-09 20:39:10 +01:00
Daniel Farley and Rebecca Chen
955e9c7da4
Unify file descriptor definitions ( #3584 )
...
The _types module can house any common type defintions used throughout
the rest of typeshed to keep defintions in sync.
First candidate is file descriptors where anything with `fileno()`
method is accepted. There were several different implementations in
various files that can be unified.
2020-01-08 17:25:36 -08:00
Vury Leo and Sebastian Rittau
e7430508b0
Fix argument name of os.link/symlink ( #3590 )
2020-01-08 13:16:02 +01:00
hauntsaninja and Jelle Zijlstra
0505c100e1
inspect: update _ParameterKind for py38 ( #3587 )
2020-01-07 23:19:04 -08:00
Jens Hedegaard Nielsen and Sebastian Rittau
2cff4e615e
BaseHTTPRequestHandler is a subclass of StreamRequestHandler ( #3579 )
2020-01-06 15:00:31 +01:00
hauntsaninja and Sebastian Rittau
45688b936e
urllib: update for py38 ( #3574 )
...
* urllib.robotparser: add site_maps
* urllib.parse: add max_num_fields parameter
2020-01-05 16:17:23 +01:00
Daniel Farley and Sebastian Rittau
4fb4c80af7
Fix HTTPConnection timeout type ( #3565 )
...
`HTTPConnection` only passes timeout down to `socket.settimeout()` which is of type `Optional[float]` and has a specific action for `None`. `HTTPConnection` should support the same behavior
2020-01-05 16:11:22 +01:00
Mickaël Schoentgen and Sebastian Rittau
b4d1da03aa
Add missing Path.is_mount() introduced in Python 3.7 ( #3566 )
2020-01-05 16:04:52 +01:00
Faidon Liambotis and Jelle Zijlstra
d87a4ffe0b
socketserver.BaseRequestHandler: add missing hint ( #3524 )
...
Add hint for __init__().
Fixes #3523 .
2020-01-03 08:48:49 -08:00
Jeppe Fihl-Pearson and Jelle Zijlstra
fed3472e7c
Reflect Python 3.8 updates to the pathlib stdlib module ( #3568 )
2020-01-03 08:47:50 -08:00
Alex Grönholm and Sebastian Rittau
f5a1925e76
Corrected type for "data" in two methods ( #3562 )
...
The documentation states:
* datagram_received: "data is a bytes object containing the incoming data."
* pipe_data_received: "data is a non-empty bytes object containing the received data."
2019-12-29 16:03:53 +01:00
Batuhan Taşkaya and Sebastian Rittau
387ea1512a
Add ast.unparse ( #3557 )
2019-12-26 16:06:10 +01:00
Maarten ter Huurne and Jelle Zijlstra
703b01dd5e
Add __init__ to MappingView and its subclasses ( #3528 )
...
While these implementations don't matter for the 'typing' module
itself, these are also imported to serve as the implementations
for the 'collection.abc' module.
Fixes #3029
2019-12-21 14:45:17 -08:00
François Freitag and Sebastian Rittau
462f71a212
Remove unused type _HTTPResponse ( #3531 )
...
Unused since 8e7c32846f .
2019-12-21 21:48:17 +01:00
dave-shawley and Jelle Zijlstra
c44a556fb0
Add typestubs for the warnings module ( #3543 )
2019-12-21 12:29:34 -08:00
Rune Tynan and Jelle Zijlstra
0c563130fd
Add dbm stubs ( #3508 )
2019-12-21 12:25:37 -08:00
Jelle Zijlstra and GitHub
5021b30711
functools: remove first type param of cached_property ( #3553 )
...
Fixes #3547
This removes some type safety in exceptional cases, like code that interacts
directly with cached_property objects, but that seems like a price worth
paying.
2019-12-21 10:42:43 -08:00
layday and Jelle Zijlstra
e404e1592d
Preserve original type in total_ordering annotation ( #3552 )
...
See https://github.com/microsoft/pyright/issues/443
for reference.
2019-12-20 17:18:05 -08:00
Jan Verbeek and Sebastian Rittau
a705d59479
Add undocumented methods and make types more specific in 2/unittest ( #3550 )
2019-12-19 18:17:14 +01:00
Alois Klink and Sebastian Rittau
4766ca0846
Use Literal to improve SpooledTemporaryFile ( #3526 )
...
* Run black code formatter on tempfile.pyi
* Use Literal to improve SpooledTemporaryFile
Previously, SpooledTemporaryFile was always an AnyStr.
Now, we load a SpooledTemporaryFile[bytes] if we open in bytes mode,
and we load a SpooledTemporaryFile[str] if we open in str mode.
2019-12-05 08:04:53 +01:00