PedroBern / django-graphql-auth

Django registration and authentication with GraphQL.
https://django-graphql-auth.readthedocs.io/en/latest/
MIT License
329 stars 106 forks source link

Package does not support custom user model. #72

Open udemezue01 opened 3 years ago

udemezue01 commented 3 years ago

I have been using this package for a little while now and I have some issues.

My customer user models have the following fields defined.

  1. Full name.

  2. Email

But when I installed this package I was given this error which states.

Unknown field(s) (last_name, first_name) specified for User

I do not have a last name and first name field specified in my custom user model, How do I override this ???

vadolasi commented 3 years ago

I went through a similar case and modified the settings: REGISTER_MUTATION_FIELDS (https://django-graphql-auth.readthedocs.io/en/latest/settings/#register_mutation_fields) and USER_NODE_FILTER_FIELDS (https://django-graphql-auth.readthedocs.io/en/latest/settings/#user_node_filter_fields) fixed the error.

udemezue01 commented 3 years ago

okay

udemezue01 commented 3 years ago

Let me try and see it that works

aecallahan commented 3 years ago

I was having this same issue but setting https://django-graphql-auth.readthedocs.io/en/latest/settings/#user_node_filter_fields to not include username fixed my problem, thanks!

udemezue01 commented 3 years ago

alright, I will try it once more, if I am able to fix it, thanks