From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id aP/PNuJYZF9YWQAA0tVLHw (envelope-from ) for ; Fri, 18 Sep 2020 06:51:14 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id CFB1MuJYZF9jfwAAbx9fmQ (envelope-from ) for ; Fri, 18 Sep 2020 06:51:14 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 4248C9404C8 for ; Fri, 18 Sep 2020 06:51:14 +0000 (UTC) Received: from localhost ([::1]:36320 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kJAEi-0002GT-8c for larch@yhetil.org; Fri, 18 Sep 2020 02:51:12 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:55162) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJAEY-0002Dw-TK for bug-guix@gnu.org; Fri, 18 Sep 2020 02:51:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:57180) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kJAEY-0007dN-Gl for bug-guix@gnu.org; Fri, 18 Sep 2020 02:51:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kJAEY-0004ly-Ef for bug-guix@gnu.org; Fri, 18 Sep 2020 02:51:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#43487: icecat store names in user profiles break bundled addons Resent-From: Mark H Weaver Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Fri, 18 Sep 2020 06:51:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 43487 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 43487@debbugs.gnu.org X-Debbugs-Original-To: bug-guix@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.160041180918281 (code B ref -1); Fri, 18 Sep 2020 06:51:02 +0000 Received: (at submit) by debbugs.gnu.org; 18 Sep 2020 06:50:09 +0000 Received: from localhost ([127.0.0.1]:40493 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kJADh-0004kn-2k for submit@debbugs.gnu.org; Fri, 18 Sep 2020 02:50:09 -0400 Received: from lists.gnu.org ([209.51.188.17]:58230) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kJADf-0004kf-Ak for submit@debbugs.gnu.org; Fri, 18 Sep 2020 02:50:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:54980) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJADf-0001jl-1y for bug-guix@gnu.org; Fri, 18 Sep 2020 02:50:07 -0400 Received: from world.peace.net ([64.112.178.59]:42996) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kJADd-0007Mo-3y for bug-guix@gnu.org; Fri, 18 Sep 2020 02:50:06 -0400 Received: from mhw by world.peace.net with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kJADQ-0006nx-Lx; Fri, 18 Sep 2020 02:49:52 -0400 From: Mark H Weaver Date: Fri, 18 Sep 2020 02:48:34 -0400 Message-ID: <87a6xn8tr6.fsf@netris.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=64.112.178.59; envelope-from=mhw@netris.org; helo=world.peace.net X-detected-operating-system: by eggs.gnu.org: First seen = 2020/09/18 02:49:53 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -2.3 (--) X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: "bug-Guix" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of bug-guix-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=bug-guix-bounces@gnu.org X-Spam-Score: -1.01 X-TUID: HnXu5GAHteCv The Guix build of IceCat-68 stores absolute file names of the form /gnu/store/=E2=80=A6-icecat-68.=E2=80=A6/* within user profiles in ~/.mozil= la/icecat/*. For example, ~/.mozilla/icecat/*/extensions.json contains store references of the forms: /gnu/store/=E2=80=A6-icecat-68.=E2=80=A6/lib/icecat/browser/features/*.xpi = and /gnu/store/=E2=80=A6-icecat-68.=E2=80=A6/lib/icecat/browser/extensions/*.xp= i. One effect is that IceCat's bundled extensions become non-functional after the referenced /gnu/store/=E2=80=A6-icecat-68.=E2=80=A6 store item is= deleted. This affects both the "builtin" extensions included in upstream Firefox (e.g. formautofill@=E2=80=A6 and screenshots@mozilla.org.xpi) as well as the more visible bundled extensions such as LibreJS and HTTPS Everywhere. One visual artifact is that the extension's buttons, that would normally appear to the right of the URL bar, are missing their icons and are therefore invisible, although if you hover over them they become highlighted. Creating a fresh profile will temporarily fix these problems, but only until the next time "guix gc" deletes the 'icecat' store item referenced. To temporarily fix these problems while retaining most of your user data, one option is to press the "Refresh IceCat=E2=80=A6" button in . Choosing this option will reset all your preferences and addons to the IceCat defaults, but allows you to preserve the rest of your data, including your bookmarks, browser history, cookies, saved passwords, and your open tabs. A proper fix will likely involve modifying the relevant code in IceCat to either avoid storing the full file names in extensions.json, or else to detect them on startup and automatically "refresh" them as needed. I looked at the Nix package for Firefox, hoping that they might have addressed this issue, but I found only one modification that looked promising, namely their 'env_var_for_system_dir.patch' which adds support for a MOZ_SYSTEM_DIR environment variable and sets the variable in their wrapper. I tried adding that to IceCat in Guix, but alas, it did not help with this issue. I guess that its purpose is to enable other Nix packages to provide Firefox extensions. This bug report is primarily about IceCat-68, where I've observed the failure modes described above many times, and worked around it by periodically "Refreshing IceCat" from . However, IceCat-78 is affected by this issue as well, at least in part. IceCat-78 also stores references to /gnu/store/=E2=80=A6-icecat-78.=E2=80= =A6/* within the user's profile, including in extensions.json. However, I haven't yet verified that the same failure mode occurs with its bundled extensions, because I've not yet allowed any of my icecat-78 store items to be reclaimed. It's possible that the addition of "--allow-addon-sideload" in Guix's IceCat 78 package might allow the bundled extensions to refresh themselves automatically. Mark