summaryrefslogtreecommitdiff
path: root/django/contrib/sessions/backends
AgeCommit message (Collapse)Author
2026-02-21Fixed #36899 -- Implemented SessionBase.__bool__.Amar
2025-07-23Refs #36500 -- Rewrapped long docstrings and block comments via a script.django-bot
Rewrapped long docstrings and block comments to 79 characters + newline using script from https://github.com/medmunds/autofix-w505.
2025-07-23Removed double spaces after periods and within phrases.Sarah Boyce
2025-02-18Refs #36005 -- Used datetime.UTC alias instead of datetime.timezone.utc.Mariusz Felisiak
datetime.UTC was added in Python 3.11.
2024-03-13Fixed #34901 -- Added async-compatible interface to session engines.Jon Janzen
Thanks Andrew-Chen-Wang for the initial implementation which was posted to the Django forum thread about asyncifying contrib modules.
2024-03-12Removed unused clean() method in file-based session.Mariusz Felisiak
Unused since its introduction in bcf7e9a9fe037eff4d5dea0cdd8c35104590e1a8.
2024-03-12Used SessionBase.__setitem__() in setdefault().Mariusz Felisiak
2024-02-21Fixed #34806 -- Made cached_db session backend resilient to cache write errors.Sulabh Katila
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
2023-01-18Refs #34233 -- Used str.removeprefix()/removesuffix().Mariusz Felisiak
2022-03-24Refs #32365 -- Removed internal uses of utils.timezone.utc alias.Carlton Gibson
Remaining test case ensures that uses of the alias are mapped canonically by the migration writer.
2022-02-07Refs #33476 -- Reformatted code with Black.django-bot
2022-01-13Optimized SessionBase.get_expire_at_browser_close().Adam Johnson
2022-01-13Refs #29708 -- Made SessionBase store expiry as string.Adam Johnson
2021-05-12Fixed #32366 -- Updated datetime module usage to recommended approach.Nick Pope
- Replaced datetime.utcnow() with datetime.now(). - Replaced datetime.utcfromtimestamp() with datetime.fromtimestamp(). - Replaced datetime.utctimetuple() with datetime.timetuple(). - Replaced calendar.timegm() and datetime.utctimetuple() with datetime.timestamp().
2021-01-14Refs #31274 -- Removed support for the pre-Django 3.1 encoding format of ↵Mariusz Felisiak
sessions. Per deprecation timeline.
2021-01-14Refs #15902 -- Stopped set_language() storing user's language in the session.Mariusz Felisiak
Per deprecation timeline.
2020-08-19Fixed #31895 -- Fixed crash when decoding invalid session data.Mariusz Felisiak
Thanks Matt Hegarty for the report. Regression in d4fff711d4c97356bd6ba1273d2a5e349326eb5f.
2020-08-07Fixed #31864 -- Fixed encoding session data during transition to Django 3.1.Mariusz Felisiak
Thanks אורי for the report.
2020-03-02Fixed #31274 -- Used signing infrastructure in SessionBase.encode()/decode().Claude Paroz
Thanks Mariusz Felisiak and Florian Apolloner for the reviews.
2019-05-21Fixed #28763 -- Allowed overriding the session cookie age with ↵Hasan Ramezani
SessionStore.get_session_cookie_age().
2019-02-14Refs #15902 -- Deprecated storing user's language in the session.Claude Paroz
2019-02-06Removed unnecessary type() calls for class methods.Jon Dufresne
2019-01-28Fixed #30137 -- Replaced OSError aliases with the canonical OSError.Jon Dufresne
Used more specific errors (e.g. FileExistsError) as appropriate.
2019-01-27Removed default mode='r' argument from calls to open().Jon Dufresne
2018-10-03Refs #27795 -- Removed force_bytes() usage in sessions.Jon Dufresne
SessionBase.decode() is the inverse operation to SessionBase.encode(). As SessionBase.encode() always returns a string, SessionBase.decode() should always be passed a string argument. Fixed the file backend, which was the only backend still passing a bytestring.
2018-06-28Fixed #29514 -- Reverted "Used datetime.timezone.utc instead of pytz.utc for ↵Tim Graham
better performance." This reverts commit 27ca5ce19f5f184018a61611c1bc319113b1d107 due to a regression.
2018-03-20Used datetime.timezone.utc instead of pytz.utc for better performance.Sergey Fedoseev
2018-01-12Fixed #28996 -- Simplified some boolean constructs and removed trivial ↵Дилян Палаузов
continue statements.
2018-01-03Fixed #28982 -- Simplified code with and/or.Дилян Палаузов
2018-01-03Fixed #28984 -- Made assorted code simplifications.Tim Graham
2017-12-08Made session loading in cached_db engine more DRY.Jozef
2017-12-07Fixed #28906 -- Removed unnecessary bool() calls.Tim Graham
2017-11-07Fixed #28769 -- Replaced 'x if x else y' with 'x or y'.Дилян Палаузов
2017-09-07Reverted "Fixed #27818 -- Replaced try/except/pass with contextlib.suppress()."Tim Graham
This reverts commit 550cb3a365dee4edfdd1563224d5304de2a57fda because try/except performs better.
2017-07-29Avoided creation of temporary sets.Sergey Fedoseev
2017-06-28Fixed #27818 -- Replaced try/except/pass with contextlib.suppress().Mads Jensen
2017-05-03Fixed #28167 -- Fixed cache backend's SessionStore.exists() if session_key ↵Tim Graham
is None.
2017-04-27Refs #27795 -- Replaced many force_text() with str()Claude Paroz
Thanks Tim Graham for the review.
2017-04-17Fixed #28066 -- Prevented SessionBase.cycle_key() from discarding data.InvalidInterrupt
2017-03-04Refs #27656 -- Updated remaining docstring verbs according to PEP 257.Anton Samarchyan
2017-02-04Refs #27656 -- Updated django.contrib docstring verb style according to PEP 257.Anton Samarchyan
2017-01-25Refs #23919 -- Replaced super(ClassName, self) with super().chillaranand
2017-01-25Refs #23919 -- Replaced errno checking with PEP 3151 exceptions.Tim Graham
2017-01-19Refs #23919 -- Removed SessionBase.iterkeys(), itervalues(), iteritems().Srinivas Reddy Thatiparthy
These methods only work on Python 2.
2017-01-19Refs #23919 -- Stopped inheriting from object to define new style classes.Simon Charette
2017-01-18Refs #23919 -- Removed most of remaining six usageClaude Paroz
Thanks Tim Graham for the review.
2017-01-18Refs #23919 -- Removed encoding preambles and future importsClaude Paroz
2016-08-08Fixed #26764 -- Fixed Session.cycle_key() crash on unaccessed session.Adam Zapletal
2016-04-20Fixed #26520 -- Fixed a regression where SessionBase.pop() didn't return a ↵Tobias Kroenke
KeyError.
2016-04-08Fixed E128 flake8 warnings in django/.Tim Graham