What about this?
This allows me to continue using `Enum`, but forces me to check whether the object I'm serializing has a `_to_db` method.
class MyEnum(Enum): VALUE = auto() def _to_db(self) -> Self: return self.value