default exception handler

Martin von Loewis loewis at informatik.hu-berlin.de
Sun Jul 9 06:25:26 EDT 2000


Johannes Zellner <johannes at zellner.org> writes:

> is it possible to install a default exception handler?
> E.g. if the interactive py shell gets a NameError I'd
> like it to call my own handler.

You could *replace* the interactive shell, take all input from the
user, execute it, and then do with exceptions whatever you want. This
is how IDLE works.

Regards,
Martin




More information about the Python-list mailing list