Crash when no results

Bug #1050154 reported by James Westby
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
txpkgme
Fix Committed
High
Jonathan Lange

Bug Description

Summary
-------
No results foundMedian run time: Traceback (most recent call last):
  File "/home/jw2328/devel/txpkgme/trunk/bin/summarize-data", line 22, in <module>
    sys.exit(main())
  File "/home/jw2328/devel/txpkgme/trunk/txpkgme/reports.py", line 216, in main
    args.show_urls)
  File "/home/jw2328/devel/txpkgme/trunk/txpkgme/reports.py", line 199, in report_on_subunit
    w('%0.2fs\n' % (median(iter_times(results))),)
  File "/home/jw2328/devel/txpkgme/trunk/txpkgme/reports.py", line 63, in median
    return xs[i]
IndexError: list index out of range

Revision history for this message
Jonathan Lange (jml) wrote :

Need to raise an exception and then catch it in the report. median([]) is undefined.

Changed in txpkgme:
assignee: nobody → Jonathan Lange (jml)
James Westby (james-w)
Changed in txpkgme:
status: Triaged → Fix Committed
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.