mozilla / mozilla-django-oidc

A django OpenID Connect library
https://mozilla-django-oidc.readthedocs.io
Mozilla Public License 2.0
449 stars 168 forks source link

document how to deal with custom user model (email-only) #482

Closed wimfeijen closed 11 months ago

wimfeijen commented 1 year ago

Hi,

As far as I can see, OIDCAuthenticationBackend.create_user will fail if we are dealing with a user with no username.

We should probably document how to deal with a custom user model.

For example, I am dealing with a usermodel with no username and only email. What I did was overwrite create_user in MyOIDCBackend.

akatsoulas commented 11 months ago

Thank you for filing this issue. It should be fixed via #508. Please reopen if this is not the case.