Ticket #21404: 21404.diff

File 21404.diff, 1.4 KB (added by Tim Graham, 10 years ago)
  • docs/releases/1.6.txt

    diff --git a/docs/releases/1.6.txt b/docs/releases/1.6.txt
    index c72f1fb..ca0b00b 100644
    a b For backwards compatibility, this setting defaulted to using :mod:`pickle`  
    807807in Django 1.5.3, but we've changed the default to JSON in 1.6. If you upgrade
    808808and switch from pickle to JSON, sessions created before the upgrade will be
    809809lost. While JSON serialization does not support all Python objects like
    810 :mod:`pickle` does, we highly recommend using JSON-serialized sessions. Also,
    811 as JSON requires string keys, you will likely run into problems if you are
    812 using non-string keys in ``request.session``. See the
    813 :ref:`session_serialization` documentation for more details.
     810:mod:`pickle` does, we highly recommend using JSON-serialized sessions. Be
     811aware of the following when checking your code to determine if JSON
     812serialization will work for your application:
     813
     814* JSON requires string keys, so you will likely run into problems if you are
     815  using non-string keys in ``request.session``.
     816* Setting session expiration by passing ``datetime`` values to
     817  :meth:`~django.contrib.sessions.backends.base.SessionBase.set_expiry` will
     818  not work as ``datetime`` values are not serializable in JSON. You can use
     819  integer values instead.
     820
     821See the :ref:`session_serialization` documentation for more details.
    814822
    815823Object Relational Mapper changes
    816824~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Back to Top