Library resolution issue on Ubuntu - how do I figure out which library is causing my error?



  • Hi,
    I have a Qt application (built on ubuntu) that works well when built as an executable. When I build it as a library it also works well when linked against a main() program.
    When I run the .so file from python (I wrapped it using Cython), I get a bunch of the below errors and there are scrollbars missing from the GUI which I assume is related to these errors. Given the code works when called from a main() I assume this has something to do with pythons library resolution.
    Cognizant that this is a qt forum, does anyone know which library is causing this error or how I can work this out?
    (ldd on the .so does not help me - I do get the full library to all paths here, but when the .so is loaded by python the paths are not respected).

    Thanks!
    Soren

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed

    (python:22663): Gtk-CRITICAL **: IA__gtk_widget_style_get: assertion 'GTK_IS_WIDGET (widget)' failed


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    Looks like somehow the GTK style plugin is loaded through python. One alternative might be to check with PyQt to see how they do their integration with Python.

    Hope it helps


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.