Coredump: python 1.5.2
Mark Hammond
MHammond at skippinet.com.au
Thu Jul 8 04:04:54 EDT 1999
Toby J Sargeant wrote in message
<19990708142614.A3595 at longford.cs.monash.edu.au>...
>The following code causes a coredump under python 1.5.2
I dont suppose you wondered why the stack trace was so huge? :-)
>
>class Stuffed:
> def __getattr__(self,key):
> print self
>
>print Stuffed()
_Before_ the "print self" line (but not on the same line!) add a:
print "in getattr for", key
And it should become obvious why it bombs. Why Python's built-in recursion
check mechanism doesnt kick in on your platform and prevent the coredump is
something I can't possibly answer!
Mark.
More information about the Python-list
mailing list