atexit functionality

viszneki at viszneki at
Tue Apr 8 19:30:18 CEST 2003

I am not a member of the Python mailing list, I dont' have the time to read any 
mailing lists at the moment. So if someone could please respond to me 
personally, that would be great.

Generally speaking I have a lot of objects that clean themselves up before 
python actually exits, so I was wondering if a deregister function could be 

Rather than a deregister function, I thought about making the following 
modification to after _exithandlers.append((func,targs,kargs))

return _exithandlers[len(_exithandlers)]

My intention is to be able to store the returned value as a member variable in 
a class that registers its own cleanup functions. But if the class cleans 
itself up, the class could "clean up" its cleanup registration with atexit by 
saying something like del self.cleanup

I hope my ideas are well received! I think they will be because this 
modification is fully backward compatible, and doesn't introduce any negative 
side effects or anything like that.

Thanks for your time,
Donny Viszneki.

ps, could someone please personally respond to my email address 
viszneki at about any decisions made about my idea? thanks a lot. 

More information about the Python-list mailing list