UbuntuOne auth dialog is displayed when polkit auth dialog is dismissed

Bug #1721735 reported by Jean-Baptiste Lallement on 2017-10-06
This bug affects 3 people
Affects Status Importance Assigned to Milestone
gnome-software (Ubuntu)
Andrea Azzarone
snapd (Ubuntu)
Andrea Azzarone

Bug Description

With snapd 16-2.28.1 from the candidate channel

Test Case
1. With gnome-software, install a snap
2. When the polkit auth dialog is displayed, click "Cancel"

Actual result
The Ubuntu One authentication dialog is displayed

Expected result
The polkit authentication dialog is dismissed and the user returns to the main screen of gnome-software. The U1 dialog is not displayed

ProblemType: Bug
DistroRelease: Ubuntu 17.10
Package: gnome-software 3.26.0-0ubuntu3
ProcVersionSignature: Ubuntu 4.13.0-12.13-generic 4.13.3
Uname: Linux 4.13.0-12-generic x86_64
ApportVersion: 2.20.7-0ubuntu2
Architecture: amd64
CurrentDesktop: ubuntu:GNOME
Date: Fri Oct 6 12:05:54 2017
InstallationDate: Installed on 2013-09-03 (1493 days ago)
InstallationMedia: Ubuntu 13.10 "Saucy Salamander" - Alpha amd64 (20130902)
 gnome-software-plugin-flatpak N/A
 gnome-software-plugin-limba N/A
 gnome-software-plugin-snap 3.26.0-0ubuntu3
 PATH=(custom, no user)
SourcePackage: gnome-software
UpgradeStatus: No upgrade log present (probably fresh install)

Jean-Baptiste Lallement (jibel) wrote :
Jean-Baptiste Lallement (jibel) wrote :

Also note that after logging in with ubuntu one the application crashes.

Will Cooke (willcooke) on 2017-10-09
Changed in gnome-software (Ubuntu Artful):
assignee: nobody → Robert Ancell (robert-ancell)
Changed in gnome-software (Ubuntu Artful):
assignee: Robert Ancell (robert-ancell) → James Henstridge (jamesh)
importance: Undecided → High
status: New → Triaged
Robert Ancell (robert-ancell) wrote :

The cause of this is the Polkit failure is reported back via snapd as a general unauthorized failure. GNOME Software then attempts to do a snap login which is the old method of gaining authorization.

There seem to be two solutions to this:

1. snapd should report the auth failure with an error code so that GNOME Software can tell this is a Polkit failure and not a login credentials failure. James said this change was unlikely to be done in time for artful.

2. GNOME Software could stop attempting to login on an auth failure. This would mean that the Ubuntu One dialog is never shown for snaps, which is probably appropriate as Polkit covers this case. It means we can't see private snaps from GNOME Software (since we never prompt for login), but this was always going to be the case after we switched to Polkit. To handle private snaps we will have to rethink the UI to support optional login support.

I think the most appropriate solution is 2 with a versioned dependency on snapd. We probably can't do this until snapd lands in the archive?

Robert Ancell (robert-ancell) wrote :

James - any thoughts on this?

James Henstridge (jamesh) wrote :

I've got an (as yet unmerged) snapd branch to help with this:


It got a review yesterday, so should go in the next snapd release.

This is basically doing (1), returning a Forbidden error when the user dismisses the dialog.

Andrea Azzarone (azzar1) on 2018-03-06
Changed in gnome-software (Ubuntu):
assignee: James Henstridge (jamesh) → Andrea Azzarone (azzar1)
Changed in gnome-software (Ubuntu Artful):
assignee: James Henstridge (jamesh) → Andrea Azzarone (azzar1)
assignee: Andrea Azzarone (azzar1) → nobody
Changed in gnome-software (Ubuntu):
status: Triaged → In Progress
Andrea Azzarone (azzar1) on 2018-03-06
no longer affects: snap (Ubuntu)
no longer affects: snap (Ubuntu Artful)
Changed in snapd (Ubuntu):
assignee: nobody → Andrea Azzarone (azzar1)
status: New → In Progress
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in snapd (Ubuntu Artful):
status: New → Confirmed
Andrea Azzarone (azzar1) on 2019-01-17
no longer affects: snapd (Ubuntu Artful)
Changed in gnome-software (Ubuntu):
status: In Progress → Fix Released
Changed in gnome-software (Ubuntu Artful):
status: Triaged → Fix Released
Changed in snapd (Ubuntu):
status: In Progress → Fix Released
no longer affects: gnome-software (Ubuntu Artful)
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers