-
myusuf3 has quit
-
myusuf3 joined the channel
-
myusuf3 has quit
-
myusuf3 joined the channel
-
myusuf3 has quit
-
myusuf3 joined the channel
-
myusuf3
johtso ping
-
cadillac_ joined the channel
-
cadillac_
Hi myusuf3
-
myusuf3
cadillac_ ping
-
mitias?
-
so I have all the tables etc
-
but the create user pipeline step inconsistently returns wrong values
-
-
as you can see user is created.
-
it just worked fine
-
now I am going to try it again
-
i logged out
-
sign up again which should trigger login
-
and it failed.
-
as you can see in the comments in the create_user, the social object isn't always return
-
cadillac_
myusuf3: I see different emails in the tables
-
-
myusuf3
you are right
-
i copied wrong row
-
fixing
-
fixed
-
refresh
-
social object ends up going null
-
in the cases where it doesn't work.
-
cadillac_
I see that the user_id column in the social_auth_usersocialauth table is pointing to a different id than the one listed in the other table
-
myusuf3
again another fault of mine
-
i can show you in screencapture
-
it working sometimes
-
and other not
-
if you would like.
-
cadillac_
sure
-
myusuf3
hnm
-
made a video and learned something
-
when the is_new fails it creates a new user and deletes the old one
-
which is why I was getting inconsistent data for the gist
-
i recored a video showing you the flow
-
give me a second
-
cadillac_
deletes the user in the auth_users table?
-
myusuf3
yes
-
and creates a new one with new id
-
cadillac_
there's nothing in python-social-auth that deletes entries from auth_users table
-
myusuf3
not my auth_user
-
your table
-
in social auth table
-
cadillac_
how are you "logging out" in your tests?
-
myusuf3
yes
-
video incoming
-
cadillac_
what's the endpoint you call to logout
-
?
-
myusuf3
django.contrib.auth.views.logout
-
-
@cadillac_
-
^^
-
cadillac_
when you do "logout" is anything calling the disconnect api?
-
also, when you do "logout" is the user social auth entry in the db still present?
-
myusuf3
checking
-
it should be
-
just logged out its precent
-
wow the record is deleted when I successfully login
-
remember how I showed you logs in sometimes
-
when that went through it record gets deleted
-
looking for through
-
now
-
-
these are the only two pipeline steps in between
-
standard auth stuff and my custome stuff I previously linked
-
I dont sse anything that deletes
-
cadillac_ ^
-
cadillac_
right, there's nothing that deletes unless you are invoking the "disconnect" code
-
myusuf3: what happens if you disable your custom pipelines, like removing or renaming the setting to let the default one run
-
myusuf3
cadillac_ those are needed for traditional auth connects
-
which ones, I am not seeing where this is happening
-
do you guys hook into django.contrib.auth.views.logout\
-
cadillac_
no, we don't
-
I mean trying to rename `SOCIAL_AUTH_PIPELINE` into `DISABLED_SOCIAL_AUTH_PIPELINE`, let the normal pipeline run and see what's the behavior then
-
myusuf3
kk trying
-
give me a second
-
nothing happen
-
no login or user creations
-
cadillac_
nothing in the DB?
-
myusuf3
is create_user in the default flow?
-
nothing
-
cadillac_
-
myusuf3
putting in some breakpioints give me a second
-
you sure its nothing to do with complete/email post and stuff like that
-
I have to do default with my user_oassword in there
-
but its weird why create user isn't creating auth_user right?!
-
cadillac_
create_user will create the user unless it's identified that the user is already created
-
myusuf3
and that record would be in the auth_user table?
-
cadillac_
right
-
myusuf3
well the sky is red
-
and nothing works
-
any ideas here
-
cadillac_
no ideas here, I suggest an step-by-step debug from the starting point to determine where's the entry getting deleted
-
myusuf3
hmm but its doing something that you are saying it shouldn't do with default pipeline
-
right?
-
cadillac_
the delete?
-
myusuf3
yeah
-
how is that even happening?
-
cadillac_
that escapes my mind, there's nothing in PSA coded to do that
-
myusuf3
thanks, I will cotninue to look
-
but if you can think of anything, would be apprecaited.
-
cadillac_
I'll let you know if something comes to my mind
-
try enabling the output for the SQL queries getting run, that might point what's triggering that query
-
myusuf3
i could just turn on sql logs
-
kk cool
-
thanks.
-
thanks for taking the time.
-
cadillac_
no problem
-
myusuf3
cadillac_ ping
-
-
-
so it is being deleted on login
-
i found it.
-
thanks it was us.