Eric Traut
0b3494f712
Replaced parameter name "self" with "cls" for a few class methods ( #4393 )
...
* Replaced parameter name "self" with "cls" for a few class methods. Pyright emits a warning if a class method doesn't follow the PEP 8 standard where the first parameter is named "cls" for a class method. This change eliminates these warnings.
* Missed a file.
Co-authored-by: Eric Traut <erictr@microsoft.com >
2020-08-06 09:09:21 +02:00
Eric Traut
04c74640f0
Removed imported symbols that are not accessed or re-exported ( #4387 )
...
Co-authored-by: Eric Traut <erictr@microsoft.com >
2020-08-05 22:49:17 -07:00
Jelle Zijlstra
5d553c9584
apply black and isort ( #4287 )
...
* apply black and isort
* move some type ignores
2020-06-28 13:31:00 -07:00
Rune Tynan
a9e4ddaf29
Add _py_abc stubs ( #4129 )
2020-05-29 00:26:18 +02:00
Shantanu
e56adddc48
dataclasses: change hash to unsafe_hash, add a minor overload ( #3892 )
...
Co-authored-by: hauntsaninja <>
2020-04-03 17:23:05 -07:00
Rune Tynan
e3ddfd46b4
Fix missing type for dataclasses ( #3708 )
...
* Add missing return type to make_dataclass
* Fix consistency check
2020-02-02 21:58:15 -08:00
Sebastian Rittau
256b3ce8ab
Remove a bunch of unused imports ( #3323 )
2019-10-08 07:59:32 -07:00
Benjamin Woodruff
3272307933
Make dataclasses.Field.metadata non-optional ( #3094 )
...
If `metadata` is `None` the Field constructor replaces it with an empty
mapping object, so this value can never be None.
https://github.com/python/cpython/blob/v3.7.3/Lib/dataclasses.py#L243
2019-06-28 18:28:50 -07:00
Sebastian Rittau
006a79220f
Flake8 fixes ( #2549 )
...
* Fix over-indented continuation lines
* Fix under-indented continuation lines
* Fix whitespace around default operator problems
* Limit line lengths
* Fix inconsistent files
2018-10-24 07:20:53 -07:00
Sebastian Kreft
c96812425a
Overload the definitions of dataclasses.asdict and dataclasses.astuple ( #2422 )
2018-09-06 22:14:28 -07:00
Jelle Zijlstra
94ab32ba59
Fix abstract classes for Python 3 ( #2239 )
...
* add metaclass=ABCMeta to some classes
* mark some more classes as explicitly abstract
* make some more classes concrete
2018-06-16 10:18:54 -07:00
Jelle Zijlstra
c5bc3bd7fa
make contextvars.Context instantiable ( #2119 )
...
Part of #1476 .
2018-06-11 14:03:02 -07:00
Ivan Levkivskyi
7dd4d0882d
Update return type of dataclasses.field ( #2197 )
2018-06-05 16:57:20 +01:00
George King
66226ab2d7
Preliminary implementation of stdlib/3.7/dataclasses.pyi. ( #1944 )
2018-05-30 12:57:02 -07:00
Ethan Smith
db9246b3e5
Fix importlib.resources for mypy ( #2130 )
2018-05-15 10:34:56 -04:00
Jelle Zijlstra
200273edeb
add stub for importlib.resources ( #1993 )
...
Part of #1965
2018-03-28 18:44:40 -07:00
Jelle Zijlstra
bfe0b06953
add stub for contextvars.pyi ( #1968 )
...
Part of #1965 .
2018-03-21 15:16:14 -07:00