Re: [xml] using "raise" in Python error handler callbacks

On Thu, Mar 31, 2005 at 10:25:41PM +0100, Andrew McDermott wrote:
Whilst experimenting with the Python bindings I noticed that exceptions 
are not propagated when using registerErrorHandler().  If I run the 
following I get the error message:

      /etc/passwd : failed to parse.

However, there is no Traceback for the "raise".  Is this correct?

import libxml2
import sys

  You have
    Python calling C calling Python.
the internal exception in the callback does not cross the C boundary
I don't see how this could work without disastrous side effects like
memory leaks or general instability in the program.


Daniel Veillard      | Red Hat Desktop team
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]