Opened 6 years ago

Closed 6 years ago

#11171 closed (worksforme)

custom set_exipy is ignored server side when set to 0

Reported by: navigator93 Owned by: nobody
Component: contrib.sessions Version: 1.0
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


According to the docs, setting the request.session.set_expiry() function to a custom value of 0 should set the cookie to only expire at browser close. It does, in fact set the local cookie's expiry time to blank, however the session middleware (or maybe it is the session app itself), still logs out the user after the global cookie age has passed, effectively ignoring the custom parameter I set. Using a datetime in the future or a value for seconds higher than 0 works just fine. Just not the explicit 0 value.

Change History (1)

comment:1 Changed 6 years ago by russellm

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to worksforme
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.
Back to Top