"QS" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]
>From the title, I assumed this was spam like others with similar titles -- and that the perl newsgroup, for instance, would have 'Does perl hate cathy? | I am new to python, and I encountered a weird problem. Observation: as you will learn, the form of the error message was different from the standard tracebacks one gets during program execution. This was a clue that it was a cleanup message and actually did make sense. Summary lessons. 1. What a Python interpreter does after it executes the last statement is undefined by the language spec. It could do absolutely nothing (and I wish some programs that wastefully spend minutes 'cleaning up' did just that!). CPython tries to do some cleanup when requested but the results are sometimes seemingly arbitrary. 2. If you use __del__, do so for a reason (and keeping a population count is one, though rare*), and explicitly delete the objects for which you want dependable behavior. *A population count is a good example of a class attribute. But it seems to be rare in practice because if one wants that, it seems that a population collection (with a len() method) is usually also wanted -- perhaps so one can iterate thru the population. 3. Experimenting with Python is a good way to learn. Keep it up! tjr -- http://mail.python.org/mailman/listinfo/python-list