UpdatePaused signal always returns percentage=0

Bug #1274131 reported by Diego Sarmentero
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu system image
Fix Released
High
Barry Warsaw
ubuntu-download-manager (Ubuntu)
New
Undecided
Unassigned

Bug Description

When you pause the download of the system image in the client the progress bar shows 0%, this was working properly using the mock service: system-image-dbus --testing=..., but it seems not to behave properly when testing it IRL, probably the service is sending the UpdatePaused signal with an incorrect value.

Tags: client

Related branches

Barry Warsaw (barry)
tags: added: client
Barry Warsaw (barry)
Changed in ubuntu-system-image:
status: New → Triaged
Barry Warsaw (barry)
Changed in ubuntu-system-image:
importance: Undecided → Medium
Revision history for this message
Barry Warsaw (barry) wrote :

I suspect this is really a bug in the u-d-m. Progress numbers are plumbed straight through from u-d-m to the s-i D-Bus API. u-d-m sends s-i `progress` signals with two values, the number of received bytes and the total number of bytes to download. We take those numbers directly from the u-d-m signal and send them on to s-i-dbus clients via the UpdateProgress signal. The numbers are completely unchanged, so that's why I think this is really a bug in u-d-m.

Revision history for this message
Barry Warsaw (barry) wrote :

Oh, and of course the mock service doesn't use u-d-m. :)

Revision history for this message
Diego Sarmentero (diegosarmentero) wrote :

I'm getting this in the system-image-update logs:

[systemimage] Jun 18 15:45:07 2014 (2373) EMIT UpdateProgress(2, 0)
[systemimage] Jun 18 15:45:07 2014 (2373) EMIT UpdatePaused(0)

Revision history for this message
Barry Warsaw (barry) wrote :

Reboot.

UpdatePaused signal is sent when u-d-m sends s-i a `paused` signal. The pause signal coming from u-d-m contains only a boolean, so we don't (currently) have access to the percentage, thus we have nothing more reasonable to send in this case. Ideally, u-d-m would send us the percentage in its paused signal, but if that's not possible (either technically, or because it would be an API rev for u-d-m), then I will investigate whether it's feasible to dig that number out of information received previously from u-d-m.

summary: - When pressing pause in the client, the progress bar changes to 0%
+ UpdatePaused signal always returns percentage=0
Changed in ubuntu-system-image:
importance: Medium → Wishlist
importance: Wishlist → Medium
importance: Medium → High
milestone: none → 2.3
Barry Warsaw (barry)
Changed in ubuntu-system-image:
status: Triaged → In Progress
assignee: nobody → Barry Warsaw (barry)
Barry Warsaw (barry)
Changed in ubuntu-system-image:
status: In Progress → Fix Committed
Revision history for this message
Manuel de la Peña (mandel) wrote :

The process of the download is the excat same as the last one that was sent. I think that the pause signal should not send the percentage, I can add a property to get such information that can be qeuried.

Revision history for this message
Barry Warsaw (barry) wrote :

Thanks Manuel. Right now, I'm keeping track of the information coming from progress signals, and then calculating the percentage myself. It's a bit awkward but it works. I agree that changing the API of the pause signal is probably not a great idea. (Rev'ing D-Bus APIs is a pain. ;). A property that can be queried would be nice, but given the workaround, it's not critical.

Barry Warsaw (barry)
Changed in ubuntu-system-image:
status: Fix Committed → Fix Released
no longer affects: ubuntu-download-manager
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.