Skip to content

Fix schema generation for nested serializers #1177

New issue

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

Merged
merged 2 commits into from
Sep 19, 2023
Merged

Fix schema generation for nested serializers #1177

merged 2 commits into from
Sep 19, 2023

Conversation

arttuperala
Copy link
Contributor

Description of the Change

Fixes schema generation for Serializer when it's used as a nested serializer inside another serializer or as a child of a ListField. Previously it'd use the full JSON:API serializer schema even though it doesn't render the "type", "id", "attributes", etc. fields in the response.

Checklist

  • PR only contains one change (considered splitting up PR)
  • unit-test added
  • documentation updated
  • CHANGELOG.md updated (only for user relevant changes)
  • author name in AUTHORS

Copy link
Member

@sliverc sliverc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome. Thanks for your work. LGTM.

@sliverc sliverc merged commit ed5a999 into django-json-api:main Sep 19, 2023
@arttuperala arttuperala deleted the subserializer-schema branch September 19, 2023 06:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants