Results 1 to 2 of 2

Thread: Qt plug-in for GLib event loop based application

  1. #1
    Join Date
    Mar 2008
    Posts
    27
    Thanks
    1
    Thanked 3 Times in 3 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Qt plug-in for GLib event loop based application

    I am working on a PyQt 4 front-end for a python application that uses the GLib event loop itself. How should I fix it so that it works? Right now I get this Python GDB backtrace when I try to process something with the python core application after the GUI is loaded (and the Qt event loop is running)

    Qt Code:
    1. login.py, __init__
    2. login.py, show
    3. login.py, signin
    4. Signing in to account
    5. 65.54.239.210
    6. login.py, onConnecting: Connecting to server...
    7.  
    8. Program received signal SIGSEGV, Segmentation fault.
    9. [Switching to Thread 0x7fb7cc4986e0 (LWP 21603)]
    10. 0x00000000004d44bd in PyFrame_New ()
    11. (gdb) bt
    12. #0 0x00000000004d44bd in PyFrame_New ()
    13. #1 0x0000000000489c76 in PyEval_EvalCodeEx ()
    14. #2 0x00000000004d51f8 in ?? ()
    15. #3 0x00000000004191ea in ?? ()
    16. #4 0x000000000041b370 in _PyObject_CallFunction_SizeT ()
    17. #5 0x00007fb7ca9a7233 in ?? () from /var/lib/python-support/python2.5/gtk-2.0/gobject/_gobject.so
    18. #6 0x00007fb7ca0af262 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
    19. #7 0x00007fb7ca0b2516 in ?? () from /usr/lib/libglib-2.0.so.0
    20. #8 0x00007fb7ca0b29af in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
    21. #9 0x00007fb7c3e423af in QEventDispatcherGlib::processEvents () from /usr/lib/libQtCore.so.4
    22. #10 0x00007fb7c435f72f in ?? () from /usr/lib/libQtGui.so.4
    23. #11 0x00007fb7c3e18585 in QEventLoop::processEvents () from /usr/lib/libQtCore.so.4
    24. #12 0x00007fb7c3e186db in QEventLoop::exec () from /usr/lib/libQtCore.so.4
    25. #13 0x00007fb7c3e1a729 in QCoreApplication::exec () from /usr/lib/libQtCore.so.4
    26. #14 0x00007fb7c5141c87 in ?? () from /usr/lib/python2.5/site-packages/PyQt4/QtGui.so
    27. #15 0x00000000004895bb in PyEval_EvalFrameEx ()
    28. #16 0x0000000000488b77 in PyEval_EvalFrameEx ()
    29. #17 0x0000000000488b77 in PyEval_EvalFrameEx ()
    30. #18 0x000000000048a376 in PyEval_EvalCodeEx ()
    31. #19 0x000000000048a492 in PyEval_EvalCode ()
    32. #20 0x00000000004abdce in PyRun_FileExFlags ()
    33. #21 0x00000000004ac069 in PyRun_SimpleFileExFlags ()
    34. #22 0x00000000004145ad in Py_Main ()
    35. #23 0x00007fb7cb6bd1c4 in __libc_start_main () from /lib/libc.so.6
    36. #24 0x0000000000413b29 in _start ()
    37. (gdb)
    To copy to clipboard, switch view to plain text mode 

    Do I have to use the GLib event loop in PyQt4? I'm lost.
    Thanks. I hope someone can help me.

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,012 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt plug-in for GLib event loop based application

    This backtrace shows the program fails on Python (or PyQt) code, not Glib code. I don't think the event loop has anything to do with this.

Similar Threads

  1. Workload in a QThread blocks main application's event loop ?
    By 0xBulbizarre in forum Qt Programming
    Replies: 14
    Last Post: 9th April 2006, 21:55

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.