Infinite _pulse_helper callback loop in PackageStatusBar when adding GObject.timeout_add(500, self._pulse_helper)

Bug #1006926 reported by Natalia Bidart
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
software-center (Ubuntu)
Won't Fix
Medium
Unassigned

Bug Description

There is an infinite loop in the _pulse_helper method, caused by the sentence of GObject.timeout_add(500, self._pulse_helper) in the __init__ of the PackageStatusBar.

More details come from this chat with Michael:

(10:03:49 AM) nessita: mvo: the main issue is that self._pulse_helper never returns False
(10:04:02 AM) nessita: so the callback will live in the mainloop for ever
(10:04:58 AM) nessita: mvo: in the tests, this causes the "do_events" helper to process _pulse_helper lots of time... so each test takes longer and longer
(10:05:44 AM) mvo: nessita: ohhhh, good catch!
(10:06:26 AM) mvo: nessita: so we need fix the pulse helper to only start when needed and to actually stop or we disable it for the tests
(10:06:49 AM) nessita: mvo: right, though I wonder if this does not impact real usage of the USC
(10:07:03 AM) nessita: mvo: I don't think that callback is never disabled, no? (even in IRL)
(10:08:02 AM) mvo: nessita: unfortunately hanging around there as a sort of background thread :/
(10:08:23 AM) nessita: mvo: want me to fill a bug about this?
(10:09:19 AM) mvo: nessita: yes please with the background info that it causes the test issues you mentioned please

Revision history for this message
Gary Lasker (gary-lasker) wrote :

Setting as triaged as this is a development issue reported by a USC dev. Thanks!

Changed in software-center (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
Changed in software-center (Ubuntu):
status: Triaged → Won't Fix
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.