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 ms0.migadu.com with LMTPS id cHdaGEAsw2CFaAAAgWs5BA (envelope-from ) for ; Fri, 11 Jun 2021 11:26:24 +0200 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 mA65E0Asw2BQZAAAbx9fmQ (envelope-from ) for ; Fri, 11 Jun 2021 09:26:24 +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 D792D113AA for ; Fri, 11 Jun 2021 11:26:23 +0200 (CEST) Received: from localhost ([::1]:34050 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lrdQj-0002RB-TE for larch@yhetil.org; Fri, 11 Jun 2021 05:26:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:45196) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lrdQQ-0002R1-27 for guix-patches@gnu.org; Fri, 11 Jun 2021 05:26:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:54836) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lrdQP-0004LR-R6 for guix-patches@gnu.org; Fri, 11 Jun 2021 05:26:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lrdQP-00047s-Gp for guix-patches@gnu.org; Fri, 11 Jun 2021 05:26:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#47670] [PATCH 0/2] Add updater for packages hosted as SourceHut Git repositories Resent-From: Xinglu Chen Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 11 Jun 2021 09:26:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 47670 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 47670@debbugs.gnu.org Received: via spool by 47670-submit@debbugs.gnu.org id=B47670.162340355215844 (code B ref 47670); Fri, 11 Jun 2021 09:26:01 +0000 Received: (at 47670) by debbugs.gnu.org; 11 Jun 2021 09:25:52 +0000 Received: from localhost ([127.0.0.1]:38149 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lrdQG-00047U-5z for submit@debbugs.gnu.org; Fri, 11 Jun 2021 05:25:52 -0400 Received: from h87-96-130-155.cust.a3fiber.se ([87.96.130.155]:59566 helo=mail.yoctocell.xyz) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lrdQE-00047E-4G for 47670@debbugs.gnu.org; Fri, 11 Jun 2021 05:25:50 -0400 From: Xinglu Chen DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yoctocell.xyz; s=mail; t=1623403543; bh=M4gf5k0NhNMv4FxcJiDy8VyW0iVGfWfAL8bwdkHH/AA=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=Z6ayWeLyYApB6RimPer/avjd3N0G4cDZ+0tDrNHAPiZUtA86dT/SFKBCytya3ytm2 HI6TuJecMnUW+D+98+QcYkIn+aZIz9+Nwy+VCwrXpyt0d6q1AYnc3M1fAIjVQ3ruJ5 xZ1JyfSo0Us45frBvWrbDtnYLGC/DC5Bo/FC9IAQ= In-Reply-To: <87zgw3jfed.fsf_-_@gnu.org> References: <6b8ddedae2addf01efa57dcf3a6723bed81bf076.camel@zaclys.net> <87im4vwtyd.fsf@yoctocell.xyz> <2513bc7a1e52872be1cd1b8ecde11e21a6f613e0.camel@zaclys.net> <87fszzwryv.fsf@yoctocell.xyz> <87czv3wrnj.fsf@yoctocell.xyz> <87zgw3jfed.fsf_-_@gnu.org> Date: Fri, 11 Jun 2021 11:25:42 +0200 Message-ID: <87lf7gbvmx.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: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1623403584; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc: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=1acVHWNwJwqvAiBZD7C1eKE0hggr7jEZnC9NOzf2DoI=; b=hHjePZ5twbfW5VZ+wILq7IjdALcCZxBnd1NLSiUSO+K1zcwHW749UTklisr2ByvWRW9bDC xxQHpUToAL5HtkBNV/UEorHq3XsPx02sgcKJnkpdEeTa5RWvU/kqcwPq9AKZuVKa63LpdE dkKnkLWbu5qNuJFDMIzT8kznyMfh8mckJ+eN0ve7QKu+ancT5OXAxqAWCMwfLTj18BHBLp Vudn6CSa/VxPuToXucPqCPAIO8rQ+WOgFTTMxawUIgRCZx1IyWYj/fH5WrTZ66GfoRzI6J v4wgK/9TjEvmjCO9c5EnaK5ipowssVBHhjMwSN+fbm+vwV26yOL2+vnZzey13w== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1623403584; a=rsa-sha256; cv=none; b=nzrutl4YUHLvGzfB5zVQdD6tFMLBrCM1zO8fiUSMrkFxEIZFvJfW3sWs+3NMzrpqahD4ju 0Vmf8nnBVpPfTsGbXuCgimHFQ6kALa/clJbIvvtCmtR6nEMqi2VGUAwAseUphAJ6Bo3mrR mhB85Zc9z7QEF3wg1KjYInkPmCa9UXbtclevUbkiMQrowcQc83qrQZVFJ304PC9dDu1Yis 2DSJg3RwocX53oA5g8iKzHEL0y1baBiQ1+q8FR9HnSpo8NxGpowtetNkb27nFWE30375Wy HVdR6Z2C7C3Fs7xqUFTIkoNlyRy0d9MJLqZrF3x2MaBewekYe37BR6op+X5pGA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=yoctocell.xyz header.s=mail header.b=Z6ayWeLy; dmarc=fail reason="SPF not aligned (relaxed)" header.from=yoctocell.xyz (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Spam-Score: -3.42 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=yoctocell.xyz header.s=mail header.b=Z6ayWeLy; dmarc=fail reason="SPF not aligned (relaxed)" header.from=yoctocell.xyz (policy=none); spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Migadu-Queue-Id: D792D113AA X-Spam-Score: -3.42 X-Migadu-Scanner: scn0.migadu.com X-TUID: kTRwvNNmtkAa --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On Sun, Jun 06 2021, Ludovic Court=C3=A8s wrote: > Hi! > > Xinglu Chen skribis: > >> On Fri, Apr 09 2021, Xinglu Chen wrote: >> >>> On Fri, Apr 09 2021, L=C3=A9o Le Bouter via Guix-patches via wrote: >>> >>>> Is that an autogenerated tarball? I am under the impression that usage >>>> of those is banned in GNU Guix, and that there's a lint pass for it. >>>> What do you use these autogenerated tarballs for? Is the 'ls-remote' >>>> command not enough to replace the version and hash? >>> >>> The GitHub updater fetches the autogenerated tarball so that's what I >>> did as well. I wasn't aware about the fact that we would like to avoid >>> them. >>> >>>> GNU Guix uses shallow clones (AIUI) to save bandwidth, do you need >>>> this to generate the hash? I encourage you use the same shallow clone >>>> mechanism here, so it's more generic and not specific to Sourcehut. >>> >>> Ok, I will use shallow clones to make it more generic. >> >> Umm, the 'upstream-source-compiler' uses 'url-fetch' to fetch the url, I >> guess we would have to make it support Git repositories first. > > Yes, that=E2=80=99s a limitation of (guix upstream) right now. > =E2=80=98%method-updates=E2=80=99 was a first step in the direction of su= pporting Git > repos. One of the problems with adding support for Git repos in (guix upstream) was that Libgit2 (and by extension Guile-Git) doesn=E2=80=99t provide an AP= I for verifying tags, the I only way I know of is to run =E2=80=98git verify-tag= =E2=80=99 in the shell. There is a =E2=80=98git_commit_extract_signature=E2=80=99 API, = but it only for individual commits, and since the majority of people don=E2=80=99t sign their commits it means that a most of the time its not going to be able to verify the checkout. > Now, I agree with L=C3=A9o that (1) this is not SourceHut-specific, and (= 2) > it should not download generated archives. > > Also, I=E2=80=99d prefer to have the code rely on Guile-Git to list tags = rather > than invoking =E2=80=98git=E2=80=99, if possible. Libgit2 has a =E2=80=98git_tag_list=E2=80=99 API, though it doesn=E2=80=99t= seem like Guile-Git supports it. https://libgit2.org/libgit2/#HEAD/group/tag/git_tag_list > Perhaps that code could leave in its own (guix import git) module or > similar, rather than in (guix gnu-maintenance), which already has > little to do with GNU maintenance at this point. :-) Yeah, I think that=E2=80=99s a good idea :) --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJJBAEBCAAzFiEEAVhh4yyK5+SEykIzrPUJmaL7XHkFAmDDLBYVHHB1YmxpY0B5 b2N0b2NlbGwueHl6AAoJEKz1CZmi+1x5sqAQAJdux5Zhi45qOdFJupG7RRtenYXD 93CI2I4tYqdm7enHXLOB9yxbZ+Hfk7t4rr0mBDLtDs4j3GvtYAOak6+lM9+02WJu TkzjeyTZNtAEWWRX2+QsG2Ei/Na/ah4fPAotsZXeYK63hHKJW7FtuCdb0UBJfJbw MeqBTj9w4PEqJl90h6/yMw+l3094js+mrz07mEqYqcNB5vgJKzCXWPsdj7KGoGf+ vyvwnFNrr6v87SaFBtp01ftxMWEAA0XP9wHyKqVxg6JUOMSSoXCLod7gXMkKN5xc SC3Mxsh28AuTfn9MQz77tnZQHYMLWk5Qk+XPFsl+gXmFE82Y1WxpQFJ3W+jQbVvu o+Ql4j7beOrDL2UTeBHVW7i9IB0KOzIwMRheUaQ9P7QKkxo6unFB0TpJhUuoFQQm im6SrmKaT3LpjBOSmSVigdsoXbEFPrHmCSMOEvR4BeIh+mknCKYAo+G8KhTgoK9R sdUF/budK2H6zha7Fb2aIvFcQ3mbdMR98OysRClkwXboifruFqZ59VAl3djKqRlY ed2gaXu6ss/s3HnMaqX9Ld0++W9kYJtengPlC452fiCZN22GAzgWfi8BZ4CfX49I kkrFHnzyf+AhFBln3ugvwJ7/z2Fb6F2K6Fgn0EL1nPP34PCbe/Zqo1hlyKfXLE6V az0q8SmOcYpUim6K =30d2 -----END PGP SIGNATURE----- --=-=-=--