[snaps] License information from the store not available

Bug #1555567 reported by David Planella
88
This bug affects 12 people
Affects Status Importance Assigned to Milestone
Software Center Agent
New
Undecided
Unassigned
snapd
Confirmed
High
Unassigned
snapd-glib
Confirmed
Medium
Unassigned
gnome-software (Ubuntu)
Fix Released
High
Unassigned

Bug Description

While the store (and its API) has a field to specify the app's license, it seems to be ignored somewhere on its way to the client.

As an example, ubuntu-calculator-app.ubuntucoredev has GPL3 set as its license in the store, yet in GNOME Software it is tagged as "non-free" when listed in a search. Clicking on the package details in GNOME Software, the license type is shown as "Unknown".

David Planella (dpm)
tags: added: sdoc
Revision history for this message
Will Cooke (willcooke) wrote :
tags: added: gnome-software
Revision history for this message
Robert Ancell (robert-ancell) wrote :

snapd is not providing any license information, see bug 1555569 for an example of what information we get.

Changed in gnome-software (Ubuntu):
status: New → Triaged
importance: Undecided → Medium
David Planella (dpm)
information type: Private → Public
Will Cooke (willcooke)
tags: added: trello-import
Will Cooke (willcooke)
tags: removed: trello-import
Revision history for this message
John Lenton (chipaca) wrote :

I can confirm snappy receives the license information from the store, and promptly forgets about it.

Ooops.

Changed in snappy:
status: New → Confirmed
importance: Undecided → High
Revision history for this message
Robert Ancell (robert-ancell) wrote :

I had an attempt at solving this in snapd with the attached patch. This passes through the "license" field from the store [1] and can make a search in gnome-software show this license field.

However, this field doesn't exist for installed snaps. This is because the snap metadata doesn't contain this field and instead contains differently defined license fields [2] (it refers to a license file, not a string).

This needs some design input to progress. It seems to me that one of the following needs to occur:

- The license file that is referred in the snap YAML would have to be copied into the store database. This file could then be accessed either from the store or from a locally installed snap. This has the downsides that common license (e.g. GPL) are hard to match (requires checking the whole license file) and extra data would need to be downloaded (as opposed to a short string).

- The snap YAML would gain the license field as used in the store. The existing license file could remain for non-common / complex licenses. The downside of this is that existing snaps might have a license set in the store but not in the .snap file (searching in gnome-software would show a license but after install it would not).

[1] http://search.apps.ubuntu.com/docs/#package
[2] http://snapcraft.io/docs/build-snaps/syntax

Changed in gnome-software (Ubuntu):
importance: Medium → High
tags: added: patch
summary: - License information from the store not being used
+ [snaps] License information from the store not available
Changed in snapd-glib:
status: New → In Progress
importance: Undecided → Medium
Revision history for this message
Leo Arias (elopio) wrote :

Hey Robert, any progress here?

Harald's post became popular today: https://apachelog.wordpress.com/2017/01/30/kde-applications-in-ubuntu-snap-store/

Sadly, it has a prominent picture of this bug too :)

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

I'm not working on this patch, it really needs input from the Snappy/Store architects as to how they want this to work.

Leo Arias (elopio)
Changed in snapd-glib:
status: In Progress → Confirmed
Cris Dywan (kalikiana)
description: updated
Revision history for this message
Robert Ancell (robert-ancell) wrote :

SRUing a fix to remove license warning and just say "Unknown" in bug 1662750.

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

Mailing list discussion about using SPDX license tags:
https://lists.ubuntu.com/archives/snapcraft/2017-January/002774.html

Revision history for this message
Robert Ancell (robert-ancell) wrote :
Revision history for this message
Robert Ancell (robert-ancell) wrote :
Revision history for this message
Duncan Lithgow (duncan-lithgow) wrote :

Ubuntu 19.04

Gnome-calculator (GPL-3.0+) and kbrunch (GPL-2.0+) from the snap Store show their license as 'Free'. The bug mentioned in #1 is marked as fix released.

I'm going to be bold and go ahead and mark this bug as fix released.

Changed in gnome-software (Ubuntu):
status: Triaged → Fix Released
Michael Vogt (mvo)
affects: snappy → snapd
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.