Add handler for snap: URLs

Bug #1621971 reported by Jeremy Bícha
20
This bug affects 2 people
Affects Status Importance Assigned to Milestone
gnome-software (Ubuntu)
Fix Released
Wishlist
Robert Ancell
Xenial
Fix Released
Wishlist
Robert Ancell
Yakkety
Fix Released
Wishlist
Robert Ancell

Bug Description

[Impact]
We want GNOME Software to be able to open snap:// URLs. This allows us to embed links in webpages to snaps (like apt://).

[Test Case]
1. Run gnome-software snap://moon-buggy

Observed result:
Get error about unknown URL.

Expected result:
GNOME Software is opened showing the information for moon-buggy and ability to install.

[Regression Potential]
Backported change from master has potential to break other URL handling. Other URLs tested (apt:// appstream://) to confirm they still work.

Jeremy Bícha (jbicha)
description: updated
Changed in gnome-software (Ubuntu):
status: New → Triaged
Revision history for this message
Matthias Klumpp (ximion) wrote :

IMHO this is really unnecessary, the only thing it adds is a snappy-proprietary URL handler, while Snappy could just as well use the appstream:// handler (it would just need to search for the AppStream-IDs Snappy provides then, and could have a fallback to names)

description: updated
Changed in gnome-software (Ubuntu Xenial):
importance: Undecided → Wishlist
Changed in gnome-software (Ubuntu Yakkety):
importance: Undecided → Wishlist
Changed in gnome-software (Ubuntu Xenial):
status: New → Triaged
Changed in gnome-software (Ubuntu Yakkety):
status: New → Triaged
Changed in gnome-software (Ubuntu Xenial):
assignee: nobody → Robert Ancell (robert-ancell)
Changed in gnome-software (Ubuntu Yakkety):
assignee: nobody → Robert Ancell (robert-ancell)
Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Jeremy, or anyone else affected,

Accepted gnome-software into yakkety-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/gnome-software/3.20.1+git20170208.0.a34b091-0ubuntu1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in gnome-software (Ubuntu Yakkety):
status: Triaged → Fix Committed
tags: added: verification-needed
Changed in gnome-software (Ubuntu Xenial):
status: Triaged → Fix Committed
Revision history for this message
Brian Murray (brian-murray) wrote :

Hello Jeremy, or anyone else affected,

Accepted gnome-software into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/gnome-software/3.20.1+git20170208.0.a34b091-0ubuntu1~xenial1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

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

I've enabled proposed and upgraded everything, but I'm getting an error:

gnome-software version: Installed: 3.20.1+git20170208.0.a34b091-0ubuntu1~xenial1

xdg-open snap://moon-buggy
gvfs-open: snap://moon-buggy: error opening location: The specified location is not supported

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

Ooops, hit post before saying:

I haven't set this to verification-failed yet, because maybe I'm doing something wrong.

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

For the record I've done a "update-desktop-database" and it made no difference.

Revision history for this message
Jeremy Bícha (jbicha) wrote :

It works for me with Ubuntu GNOME 16.04.2. After installing the updated gnome-software and gnome-software-common, I ran pkill gnome-software (or you could log out and back in to stop the gnome-software background service). And then ran xdg-open snap://moon-buggy

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

I installed a fresh Xenial VM and tried again. I'm still getting that same error.

Revision history for this message
Jeremy Bícha (jbicha) wrote :

With Ubuntu (Unity) 16.10.2, the test case fails.

I got the test case to work by uninstalling ubuntu-software (but leaving gnome-software installed)

tags: added: verification-failed
removed: verification-needed
Revision history for this message
Mateusz Stachowski (stachowski-mateusz) wrote :

I couldn't get it to work in 16.04.2 and 16.10.

Also I noticed that there is a new package snapd-xdg-open. It wasn't installed so I thought that's what is missing. But after installing that package I still only got errors.

Revision history for this message
Robert Ancell (robert-ancell) wrote :

Sorry, I thought I had updated the description, it should read:

$ gnome-software snap://moon-buggy

I'm not 100% sure the correct way to make the snap links work by default. It works if you edit /usr/share/applications/defaults.list (from desktop-file-utils). I'll do a separate SRU for this change.

description: updated
Revision history for this message
Robert Ancell (robert-ancell) wrote :

Also, you are correct in that you have to kill gnome-software or restart your machine for the changes to take effect.

Revision history for this message
Robert Ancell (robert-ancell) wrote :

Opened bug 1666100 about desktop-file-utils fix.

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

Confirming that gnome-software snap://foo works as described.

tags: added: verification-done
removed: verification-failed
Revision history for this message
Jeremy Bícha (jbicha) wrote :

I think the issue is that because there are two .desktops that register "snap://" when ubuntu-software is installed, the system needs to be told which one to use.

I agree with marking this verification-done and hope that the SRU for desktop-file-utils is handled quickly so it doesn't confuse users who think that snap:// URLs should start working as soon as this update is installed.

Revision history for this message
Robie Basak (racb) wrote :

Is this fixed in Zesty? Current status is Triaged.

Revision history for this message
Robie Basak (racb) wrote :

14:01 <jbicha> rbasak: good catch, it was fixed in gnome-software 3.23.90 but zesty is still at 3.22.5 so we need to backport that patch

OK, let's remove verification-done for now to prevent accidents.

tags: removed: verification-done
Will Cooke (willcooke)
Changed in gnome-software (Ubuntu):
assignee: nobody → Robert Ancell (robert-ancell)
Changed in gnome-software (Ubuntu):
status: Triaged → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gnome-software - 3.22.6-0ubuntu2

---------------
gnome-software (3.22.6-0ubuntu2) zesty; urgency=medium

  * debian/patches/0014-snap-URL.patch:
    - Add handler for snap:// URLs (LP: #1621971)

 -- Robert Ancell <email address hidden> Tue, 14 Mar 2017 12:36:41 +1300

Changed in gnome-software (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Jeremy Bícha (jbicha) wrote :

I confirm that xdg-open snap://moon-buggy works with gnome-software 3.22.6-0ubuntu2 in Ubuntu GNOME 17.04 which was the last thing needed for this bug to be marked verified.

tags: added: verification-done xenial yakkety
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gnome-software - 3.20.1+git20170208.0.a34b091-0ubuntu1~xenial1

---------------
gnome-software (3.20.1+git20170208.0.a34b091-0ubuntu1~xenial1) xenial; urgency=medium

  * New upstream snapshot from the wip/ubuntu branch at
    git://git.gnome.org/gnome-software.
    - Hide 3rd party / non-free license warnings and just show as "Unknown"
      (LP: #1662750)
    - Add handler for snap:// URLs (LP: #1621971)
    - Hide .desktop file from startup applications (LP: #1662749)

 -- Robert Ancell <email address hidden> Wed, 08 Feb 2017 20:07:16 +1300

Changed in gnome-software (Ubuntu Xenial):
status: Fix Committed → Fix Released
Revision history for this message
Brian Murray (brian-murray) wrote : Update Released

The verification of the Stable Release Update for gnome-software has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package gnome-software - 3.20.1+git20170208.0.a34b091-0ubuntu1

---------------
gnome-software (3.20.1+git20170208.0.a34b091-0ubuntu1) yakkety; urgency=medium

  * New upstream snapshot from the wip/ubuntu branch at
    git://git.gnome.org/gnome-software.
    - Hide 3rd party / non-free license warnings and just show as "Unknown"
      (LP: #1662750)
    - Add handler for snap:// URLs (LP: #1621971)
    - Hide .desktop file from startup applications (LP: #1662749)
  * debian/control:
    - Update Vcs-Bzr link

 -- Robert Ancell <email address hidden> Wed, 08 Feb 2017 20:07:16 +1300

Changed in gnome-software (Ubuntu Yakkety):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.