Catching a non-Exception object (KeyboardInterrupt)

Hrvoje Niksic hniksic at xemacs.org
Mon Feb 4 09:07:36 EST 2008


Michael Goerz <answer654 at 8439.e4ward.com> writes:

> when I try to catch ctrl+c with
>
> except KeyboardInterrupt:
>
> pychecker tells me
>
> Catching a non-Exception object (KeyboardInterrupt)

Looks like a pychecker bug.  It might be confused by KeyboardInterrupt
being derived not from Exception, but from BaseException.



More information about the Python-list mailing list