pybootchartgui gives ZeroDivisionError when parsing the tgz file generated by a beagleboard

Bug #619026 reported by Ricardo Salveti
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
pybootchartgui (Ubuntu)
Fix Released
Undecided
Ricardo Salveti

Bug Description

Binary package hint: pybootchartgui

When running pybootchartgui against a bootchart tgz file generated by a Beagleboard device, it gives the following error:

rsalveti@evatp:/tmp/beagle$ bootchart --format=png --crop-after=compiz,metacity,mutter,kwin,xfwm4 --annotate=ureadahead,mountall,hostname,hwclock --annotate=Xorg --annotate=gdm-session-worker --output="/tmp" beagle-maverick-alpha3-maverick-20100816-1.tgz
** Message: pygobject_register_sinkfunc is deprecated (GtkWindow)
** Message: pygobject_register_sinkfunc is deprecated (GtkInvisible)
** Message: pygobject_register_sinkfunc is deprecated (GtkObject)
parsing 'beagle-maverick-alpha3-maverick-20100816-1.tgz'
parsing 'header'
parsing 'proc_stat.log'
parsing 'proc_diskstats.log'
parsing 'proc_ps.log'
warning: no parent for pid '2' with ppid '0'
merged 0 logger processes
pruned 102 process, 0 exploders, 53 threads, and 9 runs
False
Traceback (most recent call last):
  File "/usr/bin/bootchart", line 23, in <module>
    sys.exit(main())
  File "/usr/lib/pymodules/python2.6/pybootchartgui/main.py", line 137, in main
    render()
  File "/usr/lib/pymodules/python2.6/pybootchartgui/main.py", line 128, in render
    batch.render(writer, res, options, filename)
  File "/usr/lib/pymodules/python2.6/pybootchartgui/batch.py", line 41, in render
    draw.render(ctx, options, *res)
  File "/usr/lib/pymodules/python2.6/pybootchartgui/draw.py", line 282, in render
    draw_chart(ctx, IO_COLOR, True, chart_rect, [(sample.time, sample.util) for sample in disk_stats], proc_tree)
  File "/usr/lib/pymodules/python2.6/pybootchartgui/draw.py", line 201, in draw_chart
    yscale = float(chart_bounds[3]) / max(y for (x,y) in data)
ZeroDivisionError: float division

Distro: Maverick
Package: pybootchartgui 0+r141-0ubuntu1

The bootchart tgz file used is attached.

ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: pybootchartgui 0+r141-0ubuntu1
ProcVersionSignature: Ubuntu 2.6.35-14.20-generic 2.6.35
Uname: Linux 2.6.35-14-generic x86_64
Architecture: amd64
Date: Tue Aug 17 00:25:43 2010
InstallationMedia: Ubuntu 10.04 LTS "Lucid Lynx" - Release amd64 (20100427.1)
ProcEnviron:
 LANG=en_US.utf8
 SHELL=/bin/bash
SourcePackage: pybootchartgui

Revision history for this message
Ricardo Salveti (rsalveti) wrote :
Revision history for this message
Ricardo Salveti (rsalveti) wrote :

Attaching the debdiff with a very simple fix.

The problem happens because at a BeagleBoard device (or Panda) we usually use the mmcblk disk as the root device, and this is not included at the DISK_REGEX used by pybootchartgui.

This patch was also submitted upstream.

tags: added: armel ubuntu-sponsors
Revision history for this message
Ricardo Salveti (rsalveti) wrote :

With the patch it works fine:

rsalveti@evatp:/tmp/beagle$ bootchart --format=png --crop-after=compiz,metacity,mutter,kwin,xfwm4 --annotate=ureadahead,mountall,hostname,hwclock --annotate=Xorg --annotate=gdm-session-worker --output="/tmp" beagle-maverick-alpha3-maverick-20100816-1.tgz
** Message: pygobject_register_sinkfunc is deprecated (GtkWindow)
** Message: pygobject_register_sinkfunc is deprecated (GtkInvisible)
** Message: pygobject_register_sinkfunc is deprecated (GtkObject)
parsing 'beagle-maverick-alpha3-maverick-20100816-1.tgz'
parsing 'header'
parsing 'proc_stat.log'
parsing 'proc_diskstats.log'
parsing 'proc_ps.log'
warning: no parent for pid '2' with ppid '0'
merged 0 logger processes
pruned 102 process, 0 exploders, 53 threads, and 9 runs
False
bootchart written to '/tmp/beagle-maverick-alpha3-maverick-20100816-1.png'

Changed in pybootchartgui (Ubuntu):
assignee: nobody → Ricardo Salveti (rsalveti)
status: New → In Progress
tags: added: patch
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pybootchartgui - 0+r141-0ubuntu2

---------------
pybootchartgui (0+r141-0ubuntu2) maverick; urgency=low

  * Adding adding-mmcblk-block-devices.patch to make pybootchartgui run in
    devices like beagleboard. (LP: #619026)
 -- Ricardo Salveti de Araujo <email address hidden> Mon, 16 Aug 2010 22:56:36 -0300

Changed in pybootchartgui (Ubuntu):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.