Better support for `ENUM`s
OliverHofkens opened this issue · comments
SQLAlchemy offers great support for ENUM
fields, mapping them from either a list of options or a Python Enum
.
OData-Query doesn't utilize this feature well enough, and currently just crashes if you try to use a non-existing ENUM
member.
This is partially solved in SQLAlchemy by passing validate_strings=True
to the ENUM
definition, which will raise LookupError
when an unknown enum member is used. So this might not be our concern.
One adjacent feature that would be cool is supporting OData's enum
type, which uses syntax like status eq PostStatus'DRAFT'
.