Commit Graph

9 Commits

Author SHA1 Message Date
Utsav
6f943d43ea Added __class_getitem__ (#4695)
Resolves #4682

Co-authored-by: hauntsaninja <>
2020-10-22 14:05:04 -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
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
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
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