You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A dataclass could be a generic class and a specialized version of it could be used as a field type.
There is no theoretical reason to not support this, but in practice it turns out to be rather tricky to properly support, in terms of the amount of code and tests required. The problem being that we'd have to substitute type arguments properly, including across base classes and collection types (like Iterable[T] where we'd have to substitute str for T).
I haven't run into a scenario yet where this feature is needed, so for now it has low priority.
The text was updated successfully, but these errors were encountered:
A dataclass could be a generic class and a specialized version of it could be used as a field type.
There is no theoretical reason to not support this, but in practice it turns out to be rather tricky to properly support, in terms of the amount of code and tests required. The problem being that we'd have to substitute type arguments properly, including across base classes and collection types (like
Iterable[T]
where we'd have to substitutestr
forT
).I haven't run into a scenario yet where this feature is needed, so for now it has low priority.
The text was updated successfully, but these errors were encountered: