Software tab is empty on clean 19.04 install

Bug #1824188 reported by Alan Pope 🍺🐧🐱 🦄
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
gnome-initial-setup (Ubuntu)
Fix Released
High
Andrea Azzarone
snapd (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Did a clean install of Ubuntu 19.04.
Rebooted into the new installation.
Started using it, and after a short while the gnome initial setup appeared.
I went through each step, but the final one "You're ready to go!" should have some software listed from the snap store, but doesn't.

I have a working internet connection (I'm filing list bug from it)

See screenshot

ProblemType: Bug
DistroRelease: Ubuntu 19.04
Package: gnome-initial-setup 3.32.1-1ubuntu1
ProcVersionSignature: Ubuntu 5.0.0-8.9-generic 5.0.1
Uname: Linux 5.0.0-8-generic x86_64
NonfreeKernelModules: nvidia_modeset nvidia
ApportVersion: 2.20.10-0ubuntu26
Architecture: amd64
CurrentDesktop: ubuntu:GNOME
Date: Wed Apr 10 17:13:41 2019
InstallationDate: Installed on 2019-04-10 (0 days ago)
InstallationMedia: Ubuntu 19.04 "Disco Dingo" - Alpha amd64 (20190410)
SourcePackage: gnome-initial-setup
UpgradeStatus: No upgrade log present (probably fresh install)

Related branches

Revision history for this message
Alan Pope 🍺🐧🐱 🦄 (popey) wrote :
Revision history for this message
Will Cooke (willcooke) wrote :

Confirmed this on a fresh install. If you re-run g-i-s after the first time (by deleting ~/.config/gnome-initial-setup-done) then the applications are populated as expected.

Changed in gnome-initial-setup (Ubuntu):
status: New → Confirmed
tags: added: rls-dd-incoming
Changed in gnome-initial-setup (Ubuntu):
importance: Undecided → High
Revision history for this message
Will Cooke (willcooke) wrote :

Apr 10 19:51:54 test-VirtualBox gnome-initial-s[1775]: Failed to get featured snaps: Failed to read from snapd: Error receiving data: Connection reset by peer

Revision history for this message
Will Cooke (willcooke) wrote :

snapd journal:

-- Logs begin at Thu 2019-04-11 09:59:05 BST, end at Thu 2019-04-11 09:59:56 BST. --
Apr 11 09:59:27 test-VirtualBox snapd[630]: daemon.go:611: gracefully waiting for running hooks
Apr 11 09:59:27 test-VirtualBox snapd[630]: daemon.go:613: done waiting for running hooks
Apr 11 09:59:28 test-VirtualBox systemd[1]: snapd.service: Succeeded.
Apr 11 09:59:28 test-VirtualBox systemd[1]: snapd.service: Service RestartSec=100ms expired, scheduling restart.
Apr 11 09:59:28 test-VirtualBox systemd[1]: snapd.service: Scheduled restart job, restart counter is at 1.
Apr 11 09:59:28 test-VirtualBox systemd[1]: Stopped Snappy daemon.
Apr 11 09:59:28 test-VirtualBox systemd[1]: Starting Snappy daemon...
Apr 11 09:59:28 test-VirtualBox snapd[2022]: AppArmor status: apparmor is enabled and all features are available
Apr 11 09:59:28 test-VirtualBox snapd[2022]: daemon.go:379: started snapd/2.38+19.04 (series 16; classic) ubuntu/19.04 (amd64) linux/5.0.0-8-generic.
Apr 11 09:59:28 test-VirtualBox systemd[1]: Started Snappy daemon.
~

Revision history for this message
John Lenton (chipaca) wrote :

Presumably this is a 19.04 installed (not live) from http://cdimage.ubuntu.com/daily-live/20190410/disco-desktop-amd64.iso ?

Revision history for this message
Will Cooke (willcooke) wrote :

Correct, this is on first log in of a newly installed 19.04.

Revision history for this message
John Lenton (chipaca) wrote :

By editing /target/etc/environment and setting SNAPD_DEBUG=1 etc before rebooting into the new system, I get http://paste.ubuntu.com/p/jTQb2YHhq3/

You can see there snapd coming up and seeding the system, and you can also watch as pid 724 (snapd-seeded.service) polling, waiting for the seeding to be done. Grep for pid=724 to follow this one.

That seeding gets marked as done on the line

Apr 11 12:04:29 ubuntu snapd[2115]: daemon.go:296: DEBUG: pid=724;uid=0;socket=/run/snapd.socket; GET /v2/snaps/system/conf?keys=seed.loaded 37.034783ms 200

and then 724 stops, as it should. Right after it you start getting pid=3635 lines, which correspond to gnome-software (via a line in syslog saying «gnome-software[3635]: disabled plugins: dpkg, dummy, repos, epiphany»). gnome-software successfully queries snapd for featured and installed snaps (and if you start the gui, they're right there).

However you can _also_ see a pid=1825. That pid corresponds to gnome-initial-setup.

The single pid=1825 entry arrives _before snapd has seeded the system_, and in particular just as snapd has scheduled a restart. I can only assume that gnome-initial-setup gets back the list of snaps, then tries to do a find for featured snaps and fails (because snapd is restarting), and that is the point where it logs

Apr 11 12:03:46 ubuntu gnome-initial-s[1825]: Failed to get featured snaps: Failed to read from snapd: Error receiving data: Connection reset by peer

note that this is racy, and gnome-initial-setup could just as well have logged 'Failed to get installed snaps' when the initial query fails, but succeeded to get the featured snaps (and then would go on to break in interesting ways as it tries to look things up in a nil container).

In any case, two solutions:

1. retry queries when you get an error from querying snapd (as opposed to an error response). This is what the 'snap' client does: retries every 250ms for up to 5s.

2. wait for snapd to be loaded

even with (2), (1) should probably be done anyway (but it'll be harder to hit).

Changed in snapd (Ubuntu):
status: New → Invalid
Revision history for this message
John Lenton (chipaca) wrote :

(note that between my 'i can only assume' line and my line talking about 'Failed to installed snaps', i got the source of gnome-initial-setup -- i should've changed the wording but forgot)

Revision history for this message
John Lenton (chipaca) wrote :

One way we could enforce (2) above, I think, would be to have snapd.seeded.service have Before=multi-user.target.

Andrea Azzarone (azzar1)
Changed in gnome-initial-setup (Ubuntu):
status: Confirmed → In Progress
assignee: nobody → Andrea Azzarone (azzar1)
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gnome-initial-setup - 3.32.1-1ubuntu2

---------------
gnome-initial-setup (3.32.1-1ubuntu2) disco; urgency=medium

  * d/p/0001-Add-Ubuntu-mode-with-special-pages.patch:
    - Retry getting the list of featured snaps in case of failure. (LP: #1824188)
  * d/p/0001-Ensure-stamp-file-if-the-user-quit-the-wizard.patch:
  * d/p/0001-Make-summary-page-explicitly-request-navigation-butt.patch:
  * d/p/0008-Ubuntu-location-default.patch:
    - Patches refreshed automatically by gbp.

 -- Andrea Azzarone <email address hidden> Fri, 12 Apr 2019 17:17:35 +0000

Changed in gnome-initial-setup (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.