Django 3.2 incompatible
iurisilvio opened this issue · 2 comments
iurisilvio commented
Django 3.2 implemented signer.sign_object
, that fails with django-cryptography TimestampSigner
.
To reproduce, call messages.error(request, 'foo')
in a request.
Traceback (most recent call last):
File "django/core/handlers/exception.py", line 47, in inner
response = get_response(request)
File "django/utils/deprecation.py", line 119, in __call__
response = self.process_response(request, response)
File "django/contrib/messages/middleware.py", line 23, in process_response
unstored_messages = request._messages.update(response)
File "django/contrib/messages/storage/base.py", line 128, in update
return self._store(messages, response)
File "django/contrib/messages/storage/fallback.py", line 48, in _store
messages = storage._store(messages, response, remove_oldest=False)
File "django/contrib/messages/storage/cookie.py", line 124, in _store
encoded_data = self._encode(messages)
File "django/contrib/messages/storage/cookie.py", line 165, in _encode
return self.signer.sign_object(messages, serializer=MessageSerializer, compress=True)
AttributeError: 'TimestampSigner' object has no attribute 'sign_object'
iurisilvio commented
I created the #58 PR fixing that and other Django 3.2 issues.
georgemarshall commented
Fixed in #68