python dataclasses
[Python typing](https://texonom.com/python-typing-d8c1bb7425ab4187a0e969c59f1f3ad5) [Python Class](https://texonom.com/python-class-63e99105c920449ab52f08a86efed565) 


```typefrom dataclasses import dataclassfrom datetime import date@dataclassclass User:    id: int    name: str    birthdate: date    admin: bool = False```
auto generate [Python Object Member](https://texonom.com/python-object-member-ba4eb0b805e646fc87f885119988313a) 
- [Python object.__repr__()](https://texonom.com/python-objectrepr-5d95b45e1ce045d1b97f56ab5a246045) 
- [Python object.__init__()](https://texonom.com/python-objectinit-b7a9b878e8464205bdd1b91d97c83b2b) 
- [Python object.__eq__()](https://texonom.com/python-objecteq-f6e058fac9ed479faa4be68965b5754a) 


### Immutable
```type@dataclass(frozen=True)```


### Order
```type@dataclass(order=True)```


### Hash Key
```type@dataclass(unsafe_hash=True)```


### Default value for dynamic type is error
```type@dataclass(unsafe_hash=True)class User:    id: int    name: str    birthdate: date    admin: bool = False    friends: List[int] = []```



[Python attrs](https://texonom.com/python-attrs-24749cae00924c65bc131168a4cf0156)



> [[파이썬] 데이터 클래스 사용법 (dataclasses 모듈)](https://www.daleseo.com/python-dataclasses/)





