flavors / django-graphql-jwt

JSON Web Token (JWT) authentication for Graphene Django
https://django-graphql-jwt.domake.io
MIT License
820 stars 172 forks source link

Fix: graphql_auth incompatibility #297

Closed nrbnlulu closed 2 years ago

nrbnlulu commented 2 years ago

With the new release of gql_jwt all the output fields are required, therefore implementing custom output by the user is impossible because graphene will raise None on non field Error i.e:

image

And the desired result would be:

image

After making the changes in this graphql_auth PR tests are passing

Optional explanations:

  1. Because there should be a seperations between user errors and a developer errors, developer errors should not reach the user.
  2. Because if the mutation was successful i have no way to know that in a standard fashion.