session.auto and objects that cannot be pickled leads to headache

Jonathan Taylor <jonathan.taylor-H217xnMUJC0sA/[email protected]>
Newsgroups gmane.comp.python.spyce.general
Message-ID <[email protected]>
Hi,

I just finished tracking down a very annoying bug.  It turned out that
I had changed one of my objects to use an instancemethod  (e.g.

class O:
  def __init__(self):
    bar = foo

  def foo(self):
    # do something
    pass

which when you try to pickle an object of this type you get an error
complaining about the instancemethod.  However, from what I can tell
if o is an object of type O then doing:

session.auto['blah'] = o

does not give any exception, but in fact resets auto to None.  I think
we should change this so that the developer has a better idea of whats
going on.  We should probabally bubble up the same error message that
pickle gives.

Thoughts,
Jon.


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_idv37&alloc_id865&op=click
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.