From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id UCtBKoBwwmEOYgAAgWs5BA (envelope-from ) for ; Wed, 22 Dec 2021 01:25:36 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id uGQcJoBwwmHRawAA1q6Kng (envelope-from ) for ; Wed, 22 Dec 2021 00:25:36 +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 2B243137C4 for ; Wed, 22 Dec 2021 01:25:36 +0100 (CET) Received: from localhost ([::1]:45470 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mzpRn-0007bp-7N for larch@yhetil.org; Tue, 21 Dec 2021 19:25:35 -0500 Received: from eggs.gnu.org ([209.51.188.92]:56808) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mzpRH-0007bR-69 for bug-guix@gnu.org; Tue, 21 Dec 2021 19:25:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:44683) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mzpRG-00060f-Tj for bug-guix@gnu.org; Tue, 21 Dec 2021 19:25:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mzpRG-0006WC-HN for bug-guix@gnu.org; Tue, 21 Dec 2021 19:25:02 -0500 X-Loop: help-debbugs@gnu.org Subject: bug#52727: When logged as user, GUILE_LOAD_COMPILED_PATH points to the system cache instead of the user cache Resent-From: Denis 'GNUtoo' Carikli Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Wed, 22 Dec 2021 00:25:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 52727 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 52727@debbugs.gnu.org X-Debbugs-Original-To: bug-guix@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.164013264724987 (code B ref -1); Wed, 22 Dec 2021 00:25:02 +0000 Received: (at submit) by debbugs.gnu.org; 22 Dec 2021 00:24:07 +0000 Received: from localhost ([127.0.0.1]:56229 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mzpQM-0006Uw-RB for submit@debbugs.gnu.org; Tue, 21 Dec 2021 19:24:07 -0500 Received: from lists.gnu.org ([209.51.188.17]:46066) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mzpQI-0006UW-37 for submit@debbugs.gnu.org; Tue, 21 Dec 2021 19:24:05 -0500 Received: from eggs.gnu.org ([209.51.188.92]:56750) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mzpQH-0006rH-Tc for bug-guix@gnu.org; Tue, 21 Dec 2021 19:24:01 -0500 Received: from cyberdimension.org ([80.67.179.20]:52956 helo=gnutoo.cyberdimension.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_CHACHA20_POLY1305:256) (Exim 4.90_1) (envelope-from ) id 1mzpQE-0005uu-M2 for bug-guix@gnu.org; Tue, 21 Dec 2021 19:24:00 -0500 Received: from gnutoo.cyberdimension.org (localhost [127.0.0.1]) by cyberdimension.org (OpenSMTPD) with ESMTP id dfa67b1c for ; Wed, 22 Dec 2021 00:16:19 +0000 (UTC) Received: from primary_laptop (localhost [::1]) by gnutoo.cyberdimension.org (OpenSMTPD) with ESMTP id 82217847 for ; Wed, 22 Dec 2021 00:16:18 +0000 (UTC) Date: Wed, 22 Dec 2021 01:16:47 +0100 From: Denis 'GNUtoo' Carikli Message-ID: <20211222011647.2d41452f@primary_laptop> X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.24; i686-pc-linux-gnu) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="Sig_/A1=uo5dymzzmrWK016Pzs8="; protocol="application/pgp-signature"; micalg=pgp-sha256 Received-SPF: pass client-ip=80.67.179.20; envelope-from=GNUtoo@cyberdimension.org; helo=gnutoo.cyberdimension.org 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_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1640132736; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:resent-cc:resent-from:resent-sender: resent-message-id:list-id:list-help:list-unsubscribe:list-subscribe: list-post; bh=eslqmgDQeeS2jqAiwHZUOT7CJc1QbH+Z/+lND7FFCKc=; b=mqkYWNdZLONmWqj58lBymVTAc4nBLzUaYvTpDLvIAwo2uvfBqHuXh9XnMbjJw8/Olh4BKc +KRiPGkM/FQYh0ox03BGj09U9FRprCLd0emeq1pxktWGzyfNdEcI6UOsWz/1NnnrwlGYlr OgK2VPi9D9n9kHQsL4jAPvte8fXUk2S7ncuPUeOvyBUzf7k1TN79UUj3LEQAQtX0Q0l8FN qdTUVi5xqNtS0Mf8TMBUAMQK2FuwLbdCzv1Zhgp4mCcd+w9NnnoXVV7AUrPG15aULxHpQf ErBSJD1eRLNLhMGZZ9fo6NaODns8s7ZDNjLGVL0mMgSqBjlY1CuH8fsakxtjkQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1640132736; a=rsa-sha256; cv=none; b=l79btpQqQBsgxdc4kC2JuLKR9HzRIJ6B/x3NRRtSvfgpB3fYhQWawqNqh2Ry4IvvAZRMQA zMmVrcwQ2ADto+++YfBlJhqhxywkbYbM6Lm+/ztaGWKdOXaEVJUIneVT6HO/b5H5XVKLel h9PHadjDIwdp7pG6AZTl6ssxW0F4ao7s5HzEvQZbn1QM7j4SVf8Q7Lk/fJUux4olVNpkWs M2W4YsQ2I6E5VMdFFAaY2Wo85fVQsDrRC/m/hFdSwr02pPXmoipWr13c6gkT4fIyc+V49V tg/cgXHPSDplruDQAzN0jT+E64FF5f1zrdccfJq/2maqJXRDV5kJfIcMI7FkRA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -4.93 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 2B243137C4 X-Spam-Score: -4.93 X-Migadu-Scanner: scn0.migadu.com X-TUID: kH19upEw7MnZ --Sig_/A1=uo5dymzzmrWK016Pzs8= Content-Type: multipart/mixed; boundary="MP_/kRf5vb666t=zyDbZ7N_3w31" --MP_/kRf5vb666t=zyDbZ7N_3w31 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Hi, When running guix package -i hello as user (gnutoo) I have: > [gnutoo@primary_laptop ~]$ guix package -i hello > Backtrace: > In ice-9/boot-9.scm: > 222:29 19 (map1 (((gnu packages gnupg)) ((gnu packages golang)) =E2=80= =A6)) > 222:29 18 (map1 (((gnu packages golang)) ((gnu packages #)) (#) =E2=80= =A6)) > 222:29 17 (map1 (((gnu packages graphics)) ((gnu packages gtk)) =E2=80= =A6)) > 222:29 16 (map1 (((gnu packages gtk)) ((gnu packages guile)) (#) > =E2=80=A6)) 222:29 15 (map1 (((gnu packages guile)) ((gnu packages linux)= ) # > =E2=80=A6)) 222:29 14 (map1 (((gnu packages linux)) ((gnu packages #)) ((= =E2=80=A6)) > =E2=80=A6)) 222:29 13 (map1 (((gnu packages ncurses)) ((gnu packages nss)= ) # > =E2=80=A6)) 222:29 12 (map1 (((gnu packages nss)) ((gnu packages perl)) (= #) > =E2=80=A6)) 222:29 11 (map1 (((gnu packages perl)) ((gnu packages #)) ((= =E2=80=A6)) > =E2=80=A6)) 222:17 10 (map1 (((gnu packages perl-web)) ((gnu packages #))= # > =E2=80=A6)) 3326:17 9 (resolve-interface (gnu packages perl-web) #:selec= t _ > # =E2=80=A6) In ice-9/threads.scm: > 390:8 8 (_ _) > In ice-9/boot-9.scm: > 3252:13 7 (_) > In ice-9/threads.scm: > 390:8 6 (_ _) > In ice-9/boot-9.scm: > 3536:20 5 (_) > 2835:4 4 (save-module-excursion # ice-9/boo=E2=80=A6>) 3556:26 3 (_) > In unknown file: > 2 (primitive-load-path "gnu/packages/perl-web" > #) In gnu/packages/perl-web.scm: > 36:5 1 (_) > In ice-9/boot-9.scm: > 1685:16 0 (raise-exception _ #:continuable? _) >=20 > ice-9/boot-9.scm:1685:16: In procedure raise-exception: > Throw to key `record-abi-mismatch-error' with args `(abi-check "~a: > record ABI mismatch; recompilation needed" (#>) > ())'. However that works fine with sudo su: > [gnutoo@primary_laptop ~]$ sudo su > [root@primary_laptop gnutoo]# guix package -i hello > guix package: warning: Consider running 'guix pull' followed by > 'guix package -u' to get up-to-date packages and security updates. >=20 > The following package will be installed: > hello 2.10 >=20 > The following derivation will be built: > /gnu/store/ck96mk8hphd9k70a06y8ciqy0p3yp4qa-profile.drv >=20 > 0.1 MB will be downloaded > hello-2.10 52KiB > 444KiB/s 00:00 [##################] > 100.0% building CA certificate bundle... listing Emacs > sub-directories... building fonts directory... > building directory of Info manuals... > building profile with 1 package... > hint: Consider setting the necessary environment variables by running: >=20 > GUIX_PROFILE=3D"/root/.guix-profile" > . "$GUIX_PROFILE/etc/profile" >=20 > Alternately, see `guix package --search-paths -p > "/root/.guix-profile"'. As I understand from what I was told on #guix, when running sudo su, guix comes from the system: > [root@primary_laptop ~]# which guix > /run/current-system/profile/bin/guix Whereas when running it from the user, it doesn't: > [gnutoo@primary_laptop ~]$ which guix > /home/gnutoo/.config/guix/current/bin/guix And as user GUILE_LOAD_COMPILED_PATH is somehow exported to system paths: > [gnutoo@primary_laptop ~]$ echo $GUILE_LOAD_COMPILED_PATH > /run/current-system/profile/lib/guile/3.0/site-ccache:/run/current-system= /profile/share/guile/site/3.0 So if I instead set it to the right paths it works again: > [gnutoo@primary_laptop guix]$ export > GUILE_LOAD_COMPILED_PATH=3D"/home/gnutoo/.config/guix/current/lib/guile/3= .0/site-ccache:/home/gnutoo/.config/guix/current/share/guile/site/3.0" > [gnutoo@primary_laptop guix]$ guix package -i hello > The following package will be upgraded: > hello (dependencies or package changed) >=20 > nothing to be done 'GUILE_LOAD_COMPILED_PATH=3D"" guix package -i hello' also works. In my case the issue is that having '/run/current-system/profile/lib/guile/3.0/site-ccache' in GUILE_LOAD_COMPILED_PATH makes it fail: > [gnutoo@primary_laptop guix]$ export > GUILE_LOAD_COMPILED_PATH=3D/run/current-system/profile/lib/guile/3.0/site= -ccache > [gnutoo@primary_laptop guix]$ guix package -i hello Backtrace: > In ice-9/boot-9.scm: > 222:29 19 (map1 (((gnu packages gnupg)) ((gnu packages golang)) =E2=80= =A6)) [...] And apparently it fails just because it is in the path: > [gnutoo@primary_laptop guix]$ export > GUILE_LOAD_COMPILED_PATH=3D"/home/gnutoo/.config/guix/current/lib/guile/3= .0/site-ccache:/home/gnutoo/.config/guix/current/share/guile/site/3.0:/run/= current-system/profile/lib/guile/3.0/site-ccache" > [gnutoo@primary_laptop guix]$ guix package -i hello Backtrace: > In ice-9/boot-9.scm: > 222:29 19 (map1 (((gnu packages gnupg)) ((gnu packages golang)) =E2=80= =A6)) [...] This behavior probably happens becuase the system guix wasn't updated with guix system reconfigure for some time, and that the user relies on the system guile cache. And as I understand from #guix on liberachat, I'm supposed to be able to not keep my user profile and my guix system in sync. Would the solution to that be to correctly export GUILE_LOAD_COMPILED_PATH in ~/.guix-profile/etc/profile like it is done in the patch I attached (with an extra small modification in the commit message to mention the bug report)? Other commits fixing bugs in that same profile mentioned bug reports, so I assume that it's simplier to discuss the bug in a bug report than directly sending a patch to fix the issue. Note that I also didn't test the patch yet but I did test that export command. Denis. --MP_/kRf5vb666t=zyDbZ7N_3w31 Content-Type: text/x-patch Content-Transfer-Encoding: quoted-printable Content-Disposition: attachment; filename=0001-gnu-system-GUIX_PROFILE-etc-profile-Fix-GUILE_LOAD_C.patch =46rom 579e613da312f288aa9b9aebd264794bb9586625 Mon Sep 17 00:00:00 2001 From: Denis 'GNUtoo' Carikli Date: Wed, 22 Dec 2021 00:45:28 +0100 Subject: [PATCH] gnu: system: $GUIX_PROFILE/etc/profile: Fix GUILE_LOAD_COMPILED_PATH * gnu/system.scm (operating-system-etc-service)[profile]: export GUILE_LOAD_COMPILED_PATH Signed-off-by: Denis 'GNUtoo' Carikli --- gnu/system.scm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gnu/system.scm b/gnu/system.scm index 088c62ddde..4dbdf1928e 100644 --- a/gnu/system.scm +++ b/gnu/system.scm @@ -987,6 +987,8 @@ (define* (operating-system-etc-service os) # Allow GStreamer-based applications to find plugins. export GST_PLUGIN_PATH=3D\"$HOME/.guix-profile/lib/gstreamer-1.0\" =20 +export GUILE_LOAD_COMPILED_PATH=3D\"$HOME/.config/guix/current/lib/guile/3= .0/site-ccache:$HOME/.config/guix/current/share/guile/site/3.0\" + if [ -n \"$BASH_VERSION\" -a -f /etc/bashrc ] then # Load Bash-specific initialization code. --=20 2.34.0 --MP_/kRf5vb666t=zyDbZ7N_3w31-- --Sig_/A1=uo5dymzzmrWK016Pzs8= Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEeC+d2+Nrp/PU3kkGX138wUF34mMFAmHCbm8ACgkQX138wUF3 4mOtHBAAiBoysdOusJSCbOj0B/JmmfN/FNbxCSFoE6/aqW+XbZmBXeq44n+TQiPO C0dTgq86cQxVo02oZGzcEgz1NiI8+zC7eQp/7FPac+RArUoaYY9XazJQaU0zWNvZ H3Nt1TJXY1ovC7YR3NFoDN3YglLNAtJMjERNA0SmPW7VQFYzgQ2gdRN5NXH3SRy/ 3ZWqa8l8qu5IGxGsM0UQKEONdZgjoifsKyPob8ip3YK2fw1/s8FsZQ61Pjxcyawi meUnCJDKA+d1/i/FZq18AQeVbFiksrHpAhkWDzqlM4oy6mC+A6u6Duhp/qfX6Py2 wSJUi/DM/yyEvAPw2aQJM6s+wuFGgy70I6skevZyn9adCxCYx1+oTYfwXYBMIsvR 8oe423WG6m4+r7lODIWAQbGMPYvvk/O6Foxkp4eHVAGcTJmha1/lKC1bih07YAWu OFV3fQDv2m7p0GnogWqcuvRwJgzliNms2GakcsBXCcdBBlRSDqLQP6RviTFquZOr LNOUJnMvZJgTXBLbV7vvEYOUq4bdRRNh5G9s8A9bqUHMzEe+R0AELMMKh4pdfRhN xZtD9q0jEKqHCSI9zpYH2exMkzh/EojBIWouuvtxMSQAKwJDENQvHqIjZxijOwqi Vjfp/F6tRqByS3FsuxbmnXtNGapEPcZHg+gjnAPemdbq4BFf4S8= =f9UX -----END PGP SIGNATURE----- --Sig_/A1=uo5dymzzmrWK016Pzs8=--