We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
help_text
Help text is not displayed in the following case:
class Serializer(serializers.ModelSerializer): field = serializers.SerializerMethodField('_field', help_text="field info") def _field(self, obj) -> list[dict]: return []
generates openapi.yml:
openapi.yml
field: description: field info type: array items: type: object
The description key is missing in the items dict.
description
items
Don't know
The text was updated successfully, but these errors were encountered:
As a workaround, the following seems to work:
@swagger_serializer_method(serializers.ListField( child=serializers.JSONField(help_text="field info"), # or `help_text=field.help_text` )) def _field(self, obj) -> list[dict]: return []
Sorry, something went wrong.
No branches or pull requests
Bug Report
Description
Help text is not displayed in the following case:
generates
openapi.yml
:The
description
key is missing in theitems
dict.Is this a regression?
Don't know
Minimal Reproduction
Stack trace / Error message
Your Environment
The text was updated successfully, but these errors were encountered: