Skip to content

Fix session inaccessible after logout#38862

Closed
potiuk wants to merge 52 commits intoapache:mainfrom
sudiptob2:fix-session-inaccessible-after-logout
Closed

Fix session inaccessible after logout#38862
potiuk wants to merge 52 commits intoapache:mainfrom
sudiptob2:fix-session-inaccessible-after-logout

Conversation

@potiuk
Copy link
Member

@potiuk potiuk commented Apr 9, 2024


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in newsfragments.

Ulada Zakharava and others added 30 commits April 4, 2024 18:15
…on dependencies in pyproject.toml.

Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
sudiptob2 and others added 11 commits April 4, 2024 18:16
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
Signed-off-by: sudipto baral <sudiptobaral.me@gmail.com>
There were two problem was with session handling:

* the get_session_cookie - did not get the right cookie - it returned
  "session" string. The right fix was to change cookie_jar into
  cookie.jar because this is where apparently TestClient of starlette
  is holding the cookies (visible when you debug)

* The client does not accept "set_cookie" method - it accepts passing
  cookies via "cookies" dictionary - this is the usual httpx client
  - see  https://www.starlette.io/testclient/ - so we have to set
  cookie directly in the get method to try it out

I added few more calls to show what's going on and to see that the
call works before logout

The other two tests shoudl be fixed similarly.
@boring-cyborg boring-cyborg bot added area:API Airflow's REST/HTTP API area:CLI area:db-migrations PRs with DB migration area:dev-tools area:providers area:UI Related to UI/UX. For Frontend Developers. area:webserver Webserver related Issues kind:documentation provider:fab labels Apr 9, 2024
@potiuk potiuk closed this Apr 9, 2024
@sudiptob2 sudiptob2 deleted the fix-session-inaccessible-after-logout branch April 9, 2024 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:API Airflow's REST/HTTP API area:CLI area:db-migrations PRs with DB migration area:dev-tools area:providers area:UI Related to UI/UX. For Frontend Developers. area:webserver Webserver related Issues kind:documentation provider:fab

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants