[PyQt] Exceptions in Python Implementations of Virtuals

Mathias.Born at gmx.de Mathias.Born at gmx.de
Wed Oct 1 21:00:06 BST 2014


What about non-Qt C++ libraries wrapped with sip?

Can we have an option to have an exception
thrown into the caller?

Best Regards,
Mathias

On 01.10.2014, 10:31:26 Phil Thompson wrote:

> So...

> For all exceptions raised by virtual reimplementations (and slots 
> connected to signals) PyQt will invoke an error handler that will check
> if sys.excepthook has been modified. If it has been modified then it 
> does nothing, otherwise it calls qFatal(). That should mean that "good"
> applications continue to work without changes.

> It will be possible to specify (in the .sip file) that an individual 
> virtual must not raise an unhandled exception. This would be implemented
> by explicitly calling abort() after calling the error handler.

> Phil
> _______________________________________________
> PyQt mailing list    PyQt at riverbankcomputing.com
> http://www.riverbankcomputing.com/mailman/listinfo/pyqt



More information about the PyQt mailing list