#13977: Indeterministic PicklingError
------------------------------------+---------------------------------------
          Reporter:  etam           |         Owner:  nobody
            Status:  new            |     Milestone:        
         Component:  Serialization  |       Version:  1.2   
        Resolution:                 |      Keywords:        
             Stage:  Unreviewed     |     Has_patch:  0     
        Needs_docs:  0              |   Needs_tests:  1     
Needs_better_patch:  0              |  
------------------------------------+---------------------------------------
Changes (by aweakley):

  * needs_tests:  0 => 1

Comment:

 There seems to be more detail about this specific instance here:
 http://stackoverflow.com/questions/3292383/django-mod-wsgi-picklingerror-
 while-saving-object

 This page indicates that pickle for certain types of object may be fragile
 with mod_wsgi:
 http://code.google.com/p/modwsgi/wiki/IssuesWithPickleModule

 If the decimal module came to be reloaded somehow between the creation of
 the Decimal instance and the attempt to pickle it, then that might give
 this error:

 {{{
 >>> import decimal
 >>> three = decimal.Decimal(3)
 >>> cPickle.dumps(three)
 "cdecimal\nDecimal\np1\n(S'3'\ntRp2\n."
 >>> reload(decimal)
 <module 'decimal' from
 
'/opt/local/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/decimal.pyc'>
 >>> cPickle.dumps(three)
 Traceback (most recent call last):
   File "<stdin>", line 1, in <module>
 cPickle.PicklingError: Can't pickle <class 'decimal.Decimal'>: it's not
 the same object as decimal.Decimal

 }}}

 We need some more information about the server environment and wsgi setup
 before we could write a test case that could reproduce the problem.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/13977#comment:3>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

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

Reply via email to