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 UE9ZJSf3NWH2GAAAgWs5BA (envelope-from ) for ; Mon, 06 Sep 2021 13:10:31 +0200 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 cCBxISf3NWGIdgAA1q6Kng (envelope-from ) for ; Mon, 06 Sep 2021 11:10:31 +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 B5CEBBA78 for ; Mon, 6 Sep 2021 13:10:30 +0200 (CEST) Received: from localhost ([::1]:40638 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mNCWD-0007ex-Lg for larch@yhetil.org; Mon, 06 Sep 2021 07:10:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59116) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mNCUp-000759-GP for bug-guix@gnu.org; Mon, 06 Sep 2021 07:09:08 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:40602) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mNCUp-00036p-4X for bug-guix@gnu.org; Mon, 06 Sep 2021 07:09:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mNCUo-0007uw-W3 for bug-guix@gnu.org; Mon, 06 Sep 2021 07:09:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#49006: MELPA importer uses the wrong source when called from CLI Resent-From: Xinglu Chen Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Mon, 06 Sep 2021 11:09:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 49006 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: 49006@debbugs.gnu.org Received: via spool by 49006-submit@debbugs.gnu.org id=B49006.163092653930417 (code B ref 49006); Mon, 06 Sep 2021 11:09:02 +0000 Received: (at 49006) by debbugs.gnu.org; 6 Sep 2021 11:08:59 +0000 Received: from localhost ([127.0.0.1]:52147 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mNCUl-0007uX-FV for submit@debbugs.gnu.org; Mon, 06 Sep 2021 07:08:59 -0400 Received: from h87-96-130-155.cust.a3fiber.se ([87.96.130.155]:36410 helo=mail.yoctocell.xyz) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mNCUj-0007uI-QR for 49006@debbugs.gnu.org; Mon, 06 Sep 2021 07:08:58 -0400 From: Xinglu Chen DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yoctocell.xyz; s=mail; t=1630926530; bh=O/ArN9kALLqnUQozFmXxNs4IZdJsl+rkOcoK1rs12sU=; h=From:To:Subject:In-Reply-To:References:Date; b=PpEcaEXiwYnR4C6KLndWXg/vqFGivCpXlQhHQWqJN/X3VC9tgP3CqTD256QG+aL/B Ggr7qWDITCTBcLsYwoIPKhGeFRj16iEBETRUWK2njc3EImqsjBUBXt3UYHvCIks6l+ NOARqxqSCUviEdeue7b4Hgs5URgzYJ4z6GhZdu5s= In-Reply-To: <87czsp8wic.fsf@yoctocell.xyz> References: <87fsxl91oh.fsf@yoctocell.xyz> <87czsp8wic.fsf@yoctocell.xyz> Date: Mon, 06 Sep 2021 13:08:49 +0200 Message-ID: <87fsui2c72.fsf@yoctocell.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" 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 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1630926631; 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:in-reply-to:in-reply-to:references:references: list-id:list-help:list-unsubscribe:list-subscribe:list-post: dkim-signature; bh=LMFBLsAazE+fd3eUynSBl89ruuoWU4lf8xWTCXuJTCI=; b=RTl3iuJyQY1eQqM87bHK1P8v8Xay6cfLHwrzzwMv8Wn+Wtg2AyOXuwSFEDY7oDGb4pXGCx Mmj+b39P8knZJ2U8nNgmECAq0gv98g4XUE8hSvkzqqfKVtczcIXex5X89EneBZBhH1sVAx 2NoIth/0D64Rye9y1QBDkaLXWAhc1OO+8w6yigIK6mk7ZQlfngd4PBKrR/zmq3+qVLn7Zo +qh4Dftbaox6edO0NYLOuOqjgzPGqANhqEWh5hosbyq6KN0v5djcEVl09RXd1VsXd5b6Io 3xbuVOeGwA2f9MgnArefqdAoH9lM5diWQEXeJrnRXNhx2EkJ+CTaSoFMX6TKng== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1630926631; a=rsa-sha256; cv=none; b=bBlTnW7AVNcSUAYz8ycuw5dkvoOe1IOzNaVOYw3zh0e2V5WGAVoP0k3hGSB8jfiUvTc8J8 AWEV7TbPlx+cD49Blr+bONEZmxBOjITbfISFkvhI/d3f05JiA872ymVFmhqjrvKWrQGowB rTjho4i2EZIQbUzNg1jZ/Uu4vXB1nyayOvCB3qh7EJ+7M7QU8FE5WGdWRRUEQA8W/ZyD0X rnsO9PIkSO1O1M1tlQbX9gVSbAwLGHke+E6/XpXqsBGuXKrOrYsDsxQ65ywLQ4CxMKsAmK Jfr9qUW543+ystawHZmqkkBfOgybjx7b18zPJt7aFlDlpsIX8tiUPQXMMZrLCg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=yoctocell.xyz header.s=mail header.b=PpEcaEXi; dmarc=fail reason="SPF not aligned (relaxed)" header.from=yoctocell.xyz (policy=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-Migadu-Spam-Score: -3.41 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=yoctocell.xyz header.s=mail header.b=PpEcaEXi; dmarc=fail reason="SPF not aligned (relaxed)" header.from=yoctocell.xyz (policy=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-Migadu-Queue-Id: B5CEBBA78 X-Spam-Score: -3.41 X-Migadu-Scanner: scn0.migadu.com X-TUID: PAM7M4Y693pD --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On Sun, Jun 13 2021, Xinglu Chen wrote: > Okay, so new findings: > > When the (guix import elpa) module has been compiled, the generated > package definition uses =E2=80=98url-fetch=E2=80=99 to fetch the source. > > --8<---------------cut here---------------start------------->8--- > ~/src/guix [env]$ ./pre-inst-env guix import elpa -a melpa magit > > Starting download of /tmp/guix-file.US750W > From https://melpa.org/packages/magit-20210609.2000.tar... > =E2=80=A6609.2000.tar 1.7MiB 365KiB/s 00:05 [###########= #######] 100.0% > (package > (name "emacs-magit") > (version "20210609.2000") > (source > (origin > (method url-fetch) > (uri (string-append > "https://melpa.org/packages/magit-" > version > ".tar")) > (sha256 > (base32 > "0pplizxy20i3i9zqm5kfjz4la93gpz8wwh1ybwdwngv5ks7vhdsr")))) > (build-system emacs-build-system) > (propagated-inputs > `(("emacs-dash" ,emacs-dash) > ("emacs-git-commit" ,emacs-git-commit) > ("emacs-magit-section" ,emacs-magit-section) > ("emacs-transient" ,emacs-transient) > ("emacs-with-editor" ,emacs-with-editor))) > (home-page "https://github.com/magit/magit") > (synopsis "A Git porcelain inside Emacs.") > (description > "Magit is a text-based Git user interface that puts an unmatched focus > on streamlining workflows. Commands are invoked using short mnemonic > key sequences that take the cursor=E2=80=99s position in the highly actio= nable > interface into account to provide context-sensitive behavior. > > With Magit you can do nearly everything that you can do when using Git > on the command-line, but at greater speed and while taking advantage > of advanced features that previously seemed too daunting to use on a > daily basis. Many users will find that by using Magit they can become > more effective Git user. > ") > (license #f)) > --8<---------------cut here---------------end--------------->8--- > > However, if the (guix import elpa) module hasn=E2=80=99t been compiled, s= ay I > just add a dummy comment to it, then the generated package definition > uses =E2=80=98git-fetch=E2=80=99 instead of =E2=80=98url-fetch=E2=80=99. = Notice the messages emitted by > Guile. > > --8<---------------cut here---------------start------------->8--- > ~/src/guix [env]$ ./pre-inst-env guix import elpa -a melpa magit > ;;; note: source file /home/yoctocell/src/guix/guix/import/elpa.scm > ;;; newer than compiled /home/yoctocell/src/guix/guix/import/elpa.go > ;;; note: source file /home/yoctocell/src/guix/guix/import/elpa.scm > ;;; newer than compiled /home/yoctocell/.config/guix/current/lib/gu= ile/3.0/site-ccache/guix/import/elpa.go > ;;; note: source file /home/yoctocell/src/guix/guix/import/elpa.scm > ;;; newer than compiled /home/yoctocell/.guix-home/profile/lib/guil= e/3.0/site-ccache/guix/import/elpa.go > ;;; note: source file /home/yoctocell/src/guix/guix/import/elpa.scm > ;;; newer than compiled /home/yoctocell/.config/guix/current/lib/gu= ile/3.0/site-ccache/guix/import/elpa.go > ;;; note: source file /home/yoctocell/src/guix/guix/import/elpa.scm > ;;; newer than compiled guix/import/elpa.go > ;;; note: source file /home/yoctocell/src/guix/guix/import/elpa.scm > ;;; newer than compiled /home/yoctocell/.cache/guile/ccache/3.0-LE-= 8-4.5/home/yoctocell/src/guix/guix/import/elpa.scm.go > (package > (name "emacs-magit") > (version "20210609.2000") > (source > (origin > (method git-fetch) > (uri (git-reference > (url "https://github.com/magit/magit.git") > (commit > "71f57c5582448be81b02ba53750dd2ea39ed0eaf"))) > (sha256 > (base32 > "16ip50a46nk6xxj8qkpf6rmp28zjc1bhyjj9bfgibim8ywj87dlq")))) > (build-system emacs-build-system) > (propagated-inputs > `(("emacs-dash" ,emacs-dash) > ("emacs-git-commit" ,emacs-git-commit) > ("emacs-magit-section" ,emacs-magit-section) > ("emacs-transient" ,emacs-transient) > ("emacs-with-editor" ,emacs-with-editor))) > (arguments > '(#:include > '("^lisp/magit$" > "^lisp/magit[^/]+.el$" > "^lisp/git-rebase.el$" > "^Documentation/magit.texi$" > "^Documentation/AUTHORS.md$" > "^LICENSE$") > #:exclude > '("^lisp/magit-libgit.el$" > "^lisp/magit-section.el$"))) > (home-page "https://github.com/magit/magit") > (synopsis "A Git porcelain inside Emacs.") > (description > "Magit is a text-based Git user interface that puts an unmatched focus > on streamlining workflows. Commands are invoked using short mnemonic > key sequences that take the cursor=E2=80=99s position in the highly actio= nable > interface into account to provide context-sensitive behavior. > > With Magit you can do nearly everything that you can do when using Git > on the command-line, but at greater speed and while taking advantage > of advanced features that previously seemed too daunting to use on a > daily basis. Many users will find that by using Magit they can become > more effective Git user. > ") > (license #f)) > --8<---------------cut here---------------end--------------->8--- > > Maybe there is some problem with Guile itself? I came up with a hack to fix the issue, see the diff below diff --git a/guix/import/elpa.scm b/guix/import/elpa.scm index c0dc5acf51..0d07b4b35e 100644 --- a/guix/import/elpa.scm +++ b/guix/import/elpa.scm @@ -335,7 +335,8 @@ the package named PACKAGE-NAME." type ''." =20=20=20 (define melpa-recipe - (if (eq? repo 'melpa) + ;; XXX: Otherwise (eq? repo 'melpa) always seems to return #f. + (if (force (delay (eq? repo 'melpa))) (package-name->melpa-recipe (elpa-package-name pkg)) #f)) =20=20=20 I am not sure if this is a good workaround, though. Any thoughts? --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJJBAEBCAAzFiEEAVhh4yyK5+SEykIzrPUJmaL7XHkFAmE19sEVHHB1YmxpY0B5 b2N0b2NlbGwueHl6AAoJEKz1CZmi+1x55aEP/RAOmMLSPEVQC1xkWgy42VWhRJoj vGXamThwtMXYf6ugtZjKp1cRzf+Hg6zGHjNheSgzA1NNi+cga0n+coKlzeMPKiTM IvZLrJPXQMK5w/fCPEguLS+GRQlXF0hmFvgKS8LxaYxSBvMHexmqxLvSmR9iiaLq xHdK3mxVu3NtLsbasVZ3MZzmhKuQPEXgqT0OMgaS8BfNlrB359bLBE/k9X8pS2Hc Io/DZ1HD2AQdxSPOTYar9Og8W+5+lwak/eKwGumZ3obu8H7iwGpVgGDbb7WAL9FC wzt6ZDyfsdHscKdSPONCQLHHtdUDx3vYTQP+23/FvkTDLG0KYJCb7kaB+nbBdv0a T3OQajFtIw+BjKYZI5Wbb426wp6jA9iYD0135hVbkuyt41MhsFZBW9hQ3B48ndBH 3UPE5RPKzuVuIzKqqmR5/K5caRxjCQPlzFLAaHfGlS6SqD4QWIPCKs/763rFP6iJ bSNXmQpeCV9NzF68wehmiYL3l07CjQkmwlTGr637rwaLWgT1Gi0dJUDvWCLDbe2S /io018jIr2P+HUy65jHL2ap/zAQdZLbU88CHSBbmtdWvFQJJVjpO9gavDpv7LSO+ dxotTp0QzvHp+RFX1ALr9Osx20/IkCATcbNIA36cRW/3uop46sEJtjMi8PUf2Zqi 9Bp/qhv8qt2sR60F =cWy2 -----END PGP SIGNATURE----- --=-=-=--