mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Fixed #3881 -- skip saving session when response status is 500
Saving session data is somewhat likely to lead into error when the status code is 500. It is guaranteed to lead into error if the reason for the 500 code is query error on PostgreSQL.
This commit is contained in:
@@ -423,6 +423,9 @@ cookie will be sent on every request.
|
||||
Similarly, the ``expires`` part of a session cookie is updated each time the
|
||||
session cookie is sent.
|
||||
|
||||
.. versionchanged:: 1.5
|
||||
The session is not saved if the response's status code is 500.
|
||||
|
||||
Browser-length sessions vs. persistent sessions
|
||||
===============================================
|
||||
|
||||
|
||||
Reference in New Issue
Block a user