Use with mypy
To provide better errors check you should use mypy with pydantic plugin
Please use notation introduced in version 0.4.0.
| Python | |
|---|---|
1 | |
Note that above example is not using the type hints, so further operations with mypy might fail, depending on the context.
Preferred notation should look liked this:
| Python | |
|---|---|
1 | |