Skip to content

Fix DjangoObjectType deprecation warnings#430

Open
ponas wants to merge 2 commits into
torchbox:mainfrom
ponas:fix/djangoobjecttype-fields-exclude
Open

Fix DjangoObjectType deprecation warnings#430
ponas wants to merge 2 commits into
torchbox:mainfrom
ponas:fix/djangoobjecttype-fields-exclude

Conversation

@ponas

@ponas ponas commented May 23, 2026

Copy link
Copy Markdown

The following warnings were emitted from graphene-django:

DeprecationWarning: Creating a DjangoObjectType without either the `fields` or the `exclude` option is deprecated. Add an explicit `fields = '__all__'` option on DjangoObjectType CollectionObjectType to use all fields
DeprecationWarning: Defining `exclude_fields` is deprecated in favour of `exclude`.

Fixed by:

  • explicitly setting fields = "__all__"
  • setting exclude instead of exclude_fields

Closes #355

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.

Creating a DjangoObjectType without either the fields or the exclude option is deprecated

1 participant