-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
UX: Reloading pages forces the users to login #37
Comments
@osala-eng once PR #36 is merged can you take a look at this one please. |
Currently the To persist the auth state we could make use of the browsers local storage to store the Sould I go ahead with this? |
Probably needs a server-side component to make sure it's validated instead of trusting the client-side alone. Or something like https://pypi.org/project/streamlit-cookies-manager/ where we could encrypt values |
Okay, Let me use this. |
this still feels like a bug with with the way we are using this. I've not looked into it so might be wrong. |
Seems like their naming and implementation here is a bit poor. https://discuss.streamlit.io/t/why-session-state-is-not-persisting-between-refresh/32020 |
|
Doesn't feel bad enough so far to justify a rebuild now (given where we are). But we should start introducing a FastAPI in parallel for other uses cases (like chrome ext) with a view of moving the web UI later. Note just learnt this is also the cause of login screen when navigating links adding in MD. |
@osala-eng using JWT would probably avoid having to read/write user context from the database. |
@osala-eng so it looks like the following two are the 3rd party components for cookie management. Forum chat seems to imply that they are secure. Also, the first one looked like it sets the We should be able to mitigate replay attacks pretty easily I think by adding a timestamp or previous token and checking etc. but we can address that in a separate PR. Feature toggling is the short term mitigation.
FWIW - I did dig into the streamlit server and runtime code. I was also not able to see a way to set headers server side. The web server instance singleton is simply not exposed, even internally. The server init method doesn't even return and instance of the tornado webserver. |
Describe the bug
After login if you hit refresh in the browser you have to login.
Clicking on these manage documents links also open in a new window and force the user to login again
To Reproduce
Steps to reproduce the behavior:
Expected behavior
User remains logged in until the session expires or explicit logout action. Refresh any page shout not force a user to login. It should reload the page as expected.
Screenshots
If applicable, add screenshots to help explain your problem.
Environment (please complete the following information):
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: