[XML-SIG] SAX exceptions are odd

Martin v. Loewis martin@loewis.home.cs.tu-berlin.de
Fri, 6 Oct 2000 18:03:06 +0200

> So the problem is a bogus local configuration for shared libraries.
> On the one hand, I haven't installed Python properly, so I shouldn't
> expect things to work.  On the other hand, it would be helpful if
> unexpected exceptions could be reported.  Is there any way to provide
> an informative error message in this case?

One idea is that drivers should specifically distinguish between
"expected" import errors and unexpected ones, e.g.

class MissingFeature(ImportError):

Then, drivers should catch ImportError when they expect a failure, and
a plain (unexpected) ImportError would get through (*).

I can try to come up with a patch for that, as this is repeatedly
causing problems.


(*) Actually, we have to separate the case that the driver module
itself does not exist, and that processing it caused an
ImportError. That can be done by looking at sys.modules.