After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 793268 - debug-viewer: crash when loading model in timeline
debug-viewer: crash when loading model in timeline
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-devtools
git master
Other Linux
: Normal normal
: 1.13.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2018-02-07 17:44 UTC by Philippe Normand
Modified: 2018-02-08 15:30 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Philippe Normand 2018-02-07 17:44:47 UTC
Traceback (most recent call last):
  • File "./gst-debug-viewer", line 68 in <module>
    main ()
  • File "./gst-debug-viewer", line 65 in main
    GstDebugViewer.run ()
  • File "/home/phil/gst-build/subprojects/gst-devtools/debug-viewer/GstDebugViewer/Main.py", line 82 in main
    paths=Paths)
  • File "/home/phil/gst-build/subprojects/gst-devtools/debug-viewer/GstDebugViewer/Common/Main.py", line 506 in main
    options["main"](options)
  • File "/home/phil/gst-build/subprojects/gst-devtools/debug-viewer/GstDebugViewer/GUI/__init__.py", line 42 in main
    app.run()
  • File "/home/phil/gst-build/subprojects/gst-devtools/debug-viewer/GstDebugViewer/GUI/app.py", line 135 in run
    Common.Main.MainLoopWrapper(Gtk.main, Gtk.main_quit).run()
  • File "/home/phil/gst-build/subprojects/gst-devtools/debug-viewer/GstDebugViewer/Plugins/Timeline.py", line 316 in do_draw
    self.__update_params()
  • File "/home/phil/gst-build/subprojects/gst-devtools/debug-viewer/GstDebugViewer/Plugins/Timeline.py", line 420 in __update_params
    model.get(tree_iter, model.COL_TIME, model.COL_THREAD))
  • File "/usr/lib/python2.7/dist-packages/gi/overrides/Gtk.py", line 901 in get
    values.append(self.get_value(treeiter, col))
TypeError: unknown type (null)


I tracked the issue down to the "thread" column model handling. If the thread id isn't converted to an integer, there's no crash:

diff --git a/debug-viewer/GstDebugViewer/Data.py b/debug-viewer/GstDebugViewer/Data.py
index 567c018..090b2c0 100644
--- a/debug-viewer/GstDebugViewer/Data.py
+++ b/debug-viewer/GstDebugViewer/Data.py
@@ -392,7 +392,7 @@ class LogLine (list):
         # PID.
         line[1] = int(line[1])
         # Thread.
-        line[2] = int(line[2], 16)
+        # line[2] = int(line[2], 16)
         # Level (this is handled in LineCache).
         line[3] = 0
         # Line.

I'm really not a GTK+ expert but this might be a bug elsewhere, perhaps in python-gobject. I use version 3.26.1-2 on Debian Testing FWIW.
Comment 1 Tim-Philipp Müller 2018-02-08 15:30:18 UTC
Presumably fixed by:

Author: Olivier Crête <olivier.crete@collabora.com>
Date:   Thu Feb  8 08:20:55 2018 -0700

debug-viewer; Store thread as long instead of int

On 64-bit platforms, the thread id can be over 2^32 so use a long
to handle it.

If not, please re-open, thanks!