Closed
Description
- Version: 5.10.0
- Python: 3.6
- OS: linux
What was wrong?
Many data like events are returned as an AttributeDict
, so that event['event']
and event.event
both work. The typings however inherit from TypedDict
, for example for EventData
, so that only event['event']
correctly typechecks, but not event.event
. This is annoying, as perfectly valid code does not pass typechecking.
How can it be fixed?
Somehow allow (similar to the AttributeDict for runtime) for every key to in the TypedDict
to bypass typechecking also for the attribute. I sadly do not know how to do this.
Metadata
Metadata
Assignees
Labels
No labels