Bileto device-upgrade reboots device even when no packages could be installed

Bug #1621924 reported by Andrea Bernabei
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Phablet Tools
New
Undecided
Unassigned

Bug Description

Installed: 1.2.1+16.04.20160906-0ubuntu1

How to reproduce:
1) Try device-upgrade from a PPA that has correctly built but which is still waiting for the repo to be published

Expected outcome:
a warning from Bileto that no packages could be downloaded from the PPA

Actual outcome:
the device is rebooted, the user thinks the PPA installed successfully, but it hasn't.

Related branches

Andrea Bernabei (faenil)
affects: bileto → phablet-tools
Changed in phablet-tools:
assignee: nobody → Robert Bruce Park (robru)
Revision history for this message
Robert Bruce Park (robru) wrote :

Hi, please try out this version of the script and let me know if it works for you:

http://bazaar.launchpad.net/~robru/phablet-tools/use-ticket-number/view/head:/bileto

If so, let me know and I'll release it.

Thanks.

Revision history for this message
Andrea Bernabei (faenil) wrote :

hi Robert, would that not reboot even when the system upgrades some packages which are however not coming from the PPA?

i.e. PPA has nothing, but apt dist-upgrade still finds new packages from the archives so upgrades those and the phone reboots

Revision history for this message
Robert Bruce Park (robru) wrote :

Indeed. I've updated it to check that something was downloaded from the PPA, can you please confirm it works? Try this:

1. Run the script on a new ticket, confirm packages install and device reboots
2. Run the script a second time on the same ticket, confirm that no update and no reboot happens.

Thanks.

Revision history for this message
Robert Bruce Park (robru) wrote :

Ok I've pushed some changes that introduce the following behavior:

1. Before upgrading anything, it makes a list of all packages installed from the PPA to be installed, including versions.

2. It attempts to do the upgrade, which may fail for whatever reason (binaries not published yet, or maybe it succeeds but there was nothing to install anyway)

3. It then makes a new list of all packages + versions installed from that PPA,

4. It diffs those two lists and only reboots if a difference was found.

Please try the steps in comment #3 with the script in comment #1 and let me know if that works for you.

Revision history for this message
Andrea Bernabei (faenil) wrote :

Here is the output of the tests you requested :)

1st: Install a valid silo (1938 in this case). The phone rebooted as expected.

Please find the output of the command attached

Revision history for this message
Andrea Bernabei (faenil) wrote :

2nd: install silo 1938 again

Result: no reboot

Please find the log attached

Revision history for this message
Andrea Bernabei (faenil) wrote :

3rd: try installing the silo without network access

Result: no reboot

Please find the log attached

Revision history for this message
Robert Bruce Park (robru) wrote :

Ok, this fix is released, I don't have permission to close the bug though.

Changed in phablet-tools:
assignee: Robert Bruce Park (robru) → nobody
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.