Skip to content
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

Extend session periodically #1273

Merged
merged 2 commits into from Oct 21, 2023
Merged

Extend session periodically #1273

merged 2 commits into from Oct 21, 2023

Conversation

nicksellen
Copy link
Member

I noticed I get logged out from time to time, even though I'm actively using karrot, and it's annoying!

I found django only extends the session when you modify it, which we don't, after the initial creation, so it just runs to expiry (2 weeks).

There is a django option to save on every request, but that's a bit much, so I created a middleware to extend the session every hour, if you're still making requests to the site.

@nicksellen nicksellen merged commit 094c011 into master Oct 21, 2023
1 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant