[MMTK] MMTKError class hierarchy

Konrad Hinsen hinsen@cnrs-orleans.fr
Tue, 13 Apr 1999 16:24:34 +0200

> Would it be useful to introduce a generic MMTKError class and derive from
> that so that we could find more meaningful identifiers which make debugging
> (and error reporting) easier? 

I don't think the error object is really the important part. An error
hierarchy is useful for dealing with specific errors in a program, but
not for human consumption. An informative text would be much more
helpful, even if the error is something unspecific such as ValueError.

I have never found much need for catching specific errors in my
programs (but maybe others did?). Informative error messages would of
course be nice, but also a lot of work to add. In fact, MMTK does very
little explicit error checking at the moment, because most errors will
ultimately lead to some exception anyway. But of course these are
exactly the error messages that Lutz finds "not very easy to
decipher". For obvious reasons, I have much less difficulties with
them ;-)

How about this: whenever anyone finds an error message that's hard to
understand, send me the traceback (and some information about the
context, of course), and I'll see if I can provide a more intellegible
error message to be included in the next release. It helps if you already
figured out what the cause of the error was!

Konrad Hinsen                            | E-Mail: hinsen@cnrs-orleans.fr
Centre de Biophysique Moleculaire (CNRS) | Tel.: +33-
Rue Charles Sadron                       | Fax:  +33-
45071 Orleans Cedex 2                    | Deutsch/Esperanto/English/
France                                   | Nederlands/Francais