snapのアプリケーションが更新されない?

先日snapパッケージの更新を手動で行ってうまく行かなかったのでメモしておきます.該当アプリケーションを終了してから更新すればうまく行きました.

snap版のFirefoxパッケージが少し古いです.
101.0.1-1 に対して 101.0-2 が入っています.

$ sudo snap refresh
All snaps up to date.
$ snap find firefox | grep \*
firefox               101.0.1-1      mozilla**     -      Mozilla Firefox web browser
$ snap info firefox
name:      firefox
summary:   Mozilla Firefox web browser
publisher: Mozilla✓
store-url: https://snapcraft.io/firefox
contact:   https://support.mozilla.org/kb/file-bug-report-or-feature-request-mozilla
license:   unset
description: |
  Firefox is a powerful, extensible web browser with support for modern web application
  technologies.
commands:
  - firefox
  - firefox.geckodriver
snap-id:      3wdHCAVyZEmYsCMFDE9qt92UV8rC8Wdk
tracking:     latest/stable/ubuntu-21.10
refresh-date: 6 days ago, at 15:52 JST
channels:
  latest/stable:    101.0.1-1    2022-06-09 (1443) 170MB -
  latest/candidate: 101.0.1-1    2022-06-09 (1443) 170MB -
  latest/beta:      102.0b5-2    2022-06-09 (1439) 170MB -
  latest/edge:      103.0a1      2022-06-09 (1442) 180MB -
  esr/stable:       91.10.0esr-1 2022-05-31 (1391) 161MB -
  esr/candidate:    91.10.0esr-1 2022-05-23 (1391) 161MB -
  esr/beta:         ↑
  esr/edge:         ↑
installed:          101.0-2                 (1406) 170MB -

手動で更新しても最新だと言われて更新されません.

$ sudo snap refresh
All snaps up to date.
$ snap find firefox | grep \*
firefox               101.0.1-1      mozilla**     -      Mozilla Firefox web browser

snapの更新時間を制限しているのでこれのせいかと思って解除してもだめです.

$ snap refresh --time (1)
timer: 01:00-05:59
last: today at 01:00 JST
next: tomorrow at 01:00 JST
$ sudo snap unset system refresh.timer (2)
$ snap refresh --time (3)
timer: 00:00~24:00/4
last: today at 01:00 JST
next: today at 22:48 JST
$ sudo snap get system (4)
Key      Value
refresh  {...}
seed     {...}
system   {...}
$ sudo snap refresh
All snaps up to date.
$ snap find firefox | grep \*
firefox               101.0.1-1      mozilla**     -      Mozilla Firefox web browser
  1. 01:00〜05:59 に更新するようになっている
  2. 更新時間を解除して既定値に
  3. 24時間更新可能になっている
  4. 後の設定は既定値

以下のページを見るとsnapアプリケーション起動中にはアップデート行わないオプションを実験中というのを見かけました.記事は2年以上前のものです.もう実装されているのかも?

書いてある設定は見当たりません.

$ sudo snap get core experimental.refresh-app-awareness
error: snap "core" has no "experimental" configuration option

Firefoxをkillしてから snap refresh を試すとアップデートがうまく行きました.

$ pgrep firefox
302750
$ pkill firefox
$ pgrep firefox
$ sudo snap refresh
firefox 101.0.1-1 from Mozilla✓ refreshed
$ snap find firefox | grep \*
firefox               101.0.1-1      mozilla**     -      Mozilla Firefox web browser

この辺りの設定はいじった覚えがないので,既定値がsnapアプリ起動中には更新を行わないようになっているようです.とりあえずはアプリケーションを終了してからrefreshでしょうか.

環境
$ dpkg-query -W snapd
snapd   2.55.3+22.04ubuntu1
$ snap find firefox | grep \*
firefox               101.0.1-1      mozilla**     -      Mozilla Firefox web browser
$ lsb_release -dr
Description:    Ubuntu Kinetic Kudu (development branch)
Release:        22.10
$ arch
x86_64

コメントを残す

メールアドレスが公開されることはありません。 が付いている欄は必須項目です

To respond on your own website, enter the URL of your response which should contain a link to this post's permalink URL. Your response will then appear (possibly after moderation) on this page. Want to update or remove your response? Update or delete your post and re-enter your post's URL again. (Find out more about Webmentions.)