[ZODB-Dev] Persistent unhashable?

Christian Robottom Reis kiko@async.com.br
Tue, 3 Jul 2001 20:05:25 -0300 (BRT)


I'm trying to create a simple hash of persistent objects to other
persistent object. Something like:

class Foo(Persistence.Persistent):
 pass

class Bar(Persistence.Persistent):
 pass

f=Foo()
b=Bar()

a = {}
a.update( { f:b} )

raises an AttributeError: __hash__ error! Why?

Is this a known limitation of Persistent?

Take care,
--
/\/\ Christian Reis, Senior Engineer, Async Open Source, Brazil
~\/~ http://async.com.br/~kiko/ | [+55 16] 274 4311