You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When merge_into_access_token_payload() is called multiple times, each call makes a call to set_cookie() in supertokens_python/framework/flask/flask_response.py.
As a part of flask's default behaviour, flask appends Set-Cookie headers if a cookie with the same name is passed multiple time.
We would like to replace the older header with the latest sAccessToken.
I did not find a way to do it in flask, so as a fix we might have to keep track of the latest access_token in the SessionContainer.response_mutators list.
Override to reproduce the bug:
Post /signinup, the response should contain multiple sAccessToken cookies.
When
merge_into_access_token_payload()
is called multiple times, each call makes a call toset_cookie()
insupertokens_python/framework/flask/flask_response.py
.As a part of flask's default behaviour, flask appends
Set-Cookie
headers if a cookie with the same name is passed multiple time.We would like to replace the older header with the latest
sAccessToken
.I did not find a way to do it in flask, so as a fix we might have to keep track of the latest
access_token
in theSessionContainer.response_mutators
list.Override to reproduce the bug:
Post
/signinup
, the response should contain multiplesAccessToken
cookies.Affects
flask
, not tested with other frameworks.The text was updated successfully, but these errors were encountered: