Login state not properly cleared after session timeout

Open
#1,822 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
typescript

Research direction

No files, tests, or entry points are named. Start by reproducing the timeout, then trace the frontend session and routing behavior when accessing datasets or collections. Done means an expired session clears the logged-in state, redirects to login, and a successful re-login returns to the dataset overview.

Written by the indexing model from the issue text.

Description

bug DCS
Summary

After a session times out, the frontend does not properly clear the login state. Instead, it still displays the user as logged in and does not forward to the login page initially. This can lead to some very confusing states in the FE, where it might be unclear for the user what the problem is.

Steps to Reproduce

Log into frontend and let the session expire, try to access datasets or other collections afterwards

Current Behaviour

See screenshots below

Expected Behaviour

FE should check for session timeout and redirect to the login page if necessary. After timeout, the user should not be displayed as logged in anymore

Extra Details

Image
After session timeout, clicking on a dataset: Get a 404 instead of being forwarded to login page

Image
Go back to datasets overview, no entries visible despite still showing "admin" logged in (no public dataset entries in this toy instance)

Image
After trying to go to another collection from the right side menu (here published-data, others untested): 401 Unauthorized, forward to login page (but still showing "admin" as logged in!)

Image
After logging in again: Success message, but still stuck on login screen (not forwarded to dataset overview entrypoint). Can click "Log in" repeatedly without being forwarded, could be very confusing for a user.

Dominant language
TypeScript
Stars
29
Forks
44
Avg merge
20h 2m
Merged PRs (30d)
20

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from SciCatProject/frontend

All issues in SciCatProject/frontend

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.