Hi guys,

In one of our views, we're getting the error below:

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/django/core/servers/
basehttp.py", line 278, in run
    self.result = application(self.environ, self.start_response)
  File "/usr/lib/python2.5/site-packages/django/core/servers/
basehttp.py", line 635, in __call__
    return self.application(environ, start_response)
  File "/usr/lib/python2.5/site-packages/django/core/handlers/
wsgi.py", line 243, in __call__
    response = middleware_method(request, response)
  File "/usr/lib/python2.5/site-packages/django/contrib/sessions/
middleware.py", line 35, in process_response
    request.session.save()
  File "/usr/lib/python2.5/site-packages/django/contrib/sessions/
backends/db.py", line 53, in save
    session_data = self.encode(self._get_session
(no_load=must_create)),
  File "/usr/lib/python2.5/site-packages/django/contrib/sessions/
backends/base.py", line 88, in encode
    pickled = pickle.dumps(session_dict, pickle.HIGHEST_PROTOCOL)
UnpickleableError: Cannot pickle <type 'ImagingCore'> objects

By outputting debug strings, I've found out that this error occurs
after the view gets read and before the output to the browser.

'ImagingCore' here might be referencing to PIL (Python Imaging
Library) images which are stored in memory which are in turn are
stored in one of the objects which are stored into request.session in
this particular view.

I can confirm that the other parts of the view which does not process
the images are ok.

Versions used:
Django-1.0.2-final
we're using the development server that comes with django

So my question is: I'm wodering if there are any restrictions to the
data types which we can store in request.sessions?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to