-
Notifications
You must be signed in to change notification settings - Fork 319
SerializerMethodField - dict with known keys #184
Copy link
Copy link
Closed
Labels
enhancementNew feature or requestNew feature or requestfix confirmation pendingissue has been fixed and confirmation from issue reporter is pendingissue has been fixed and confirmation from issue reporter is pendinglow priorityissues that would be nice to fix but have low impactissues that would be nice to fix but have low impact
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestfix confirmation pendingissue has been fixed and confirmation from issue reporter is pendingissue has been fixed and confirmation from issue reporter is pendinglow priorityissues that would be nice to fix but have low impactissues that would be nice to fix but have low impact
Hey, let's assume we have this field in a serializer:
Is there a way to represent it as:
I've tried:
typing.TypedDictas type hint toget_field- results in "Unknown type hint"@extend_schema_fieldaccepts only either serializer orOpenApiTypes. I don't see a way to editadditionalPropertiesforOpenApiTypes.OBJECT.Seems like a common problem to me. Any ideas?