iMerica / dj-rest-auth

Authentication for Django Rest Framework
https://dj-rest-auth.readthedocs.io/en/latest/index.html
MIT License
1.62k stars 302 forks source link

Social login: EMAIL_AUTHENTICATION_AUTO_CONNECT raises an exception #599

Open jonasN5 opened 3 months ago

jonasN5 commented 3 months ago

The following line will cause an exception in Django AllAuth when combined with EMAIL_AUTHENTICATION_AUTO_CONNECT: True: https://github.com/iMerica/dj-rest-auth/blob/23f097cebcc8ecef886b2ac7869cc1d51f66f90e/dj_rest_auth/social_serializers.py#L68

If the SocialApp is defined in the settings and not in the database, the app object should not be associated to the Token object.