Authorization backend function do_auth called twice #1084
Unanswered
grindnoise
asked this question in
Q&A
Replies: 1 comment
-
@grindnoise Any specific reason you wanted to write a custom Apple backend? Since the article was published in November 2019, support for Apple sign-in has been added (March 2020). |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I've implemented apple sign-in following this article using subclass:
https://github.com/truffls/sign-in-with-apple-using-django/blob/master/backend.md
Code:
Authorization succeeds during first call, i receive access token from apple, new entries in Users & User social auths tables are created but after that function

do_auth
is called one more time causing duplicate entry:The very time user logs in - new entry in Users & User social auths tables created.

During the second call id_token is empty because apple's authorization code is one time token. So
SOCIAL_AUTH_PIPELINE in settings.py now are commented, I tried different variants.
Can somebody help me?
Beta Was this translation helpful? Give feedback.
All reactions