Comment 6 for bug 2031375

Revision history for this message
Guillermo Gonzalez (verterok) wrote :

Michael, Simon,

After some testing, and inspecting the channelmap for anbox-cloud-test our findings are:
 - there was a latest/stable channel, which was closed on 2022-11-10
 - the store will try to honor what snapd requests, in this case snapd is sending `tracking-channel: stable` in the refresh context (see attached refresh-context.json). This implicitly refers to latest/stable.
 - As there might be clients tracking latest/stable, the store response is for the last released revision in that channel: 338 (version 1.14.1-fix1) (see attached refresh-response.json) this is because we don't want to force a channel switch without the user explicitly requesting it to snapd.

Following the steps in the bug description, there is no tracking channel change:
$ snap list
Name Version Rev Tracking Publisher Notes
anbox-cloud-tests 1.14.1-fix1 338 - canonical✓ -

Related to this, Snapd seems to assume stable and latest/stable as tracking-channel for side-loaded and installed by revision snaps respectively. Is this the intended behavior? As illustrated by this bug it seems potentially unsafe if multiple tracks with incompatible versions are involved.

For the case of installed by revision, here is the example:
$ sudo snap install --revision=592 anbox-cloud-tests
anbox-cloud-tests 1.17.1-alpha.9+gitd9a1e82 from Canonical✓ installed

$ snap list
Name Version Rev Tracking Publisher Notes
anbox-cloud-tests 1.17.1-alpha.9+gitd9a1e82 592 latest/stable canonical✓ -