From patchwork Thu Sep 1 09:01:48 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: M X-Patchwork-Id: 42108 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 329FD27BBEA; Thu, 1 Sep 2022 10:44:45 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 8BAFE27BBE9 for ; Thu, 1 Sep 2022 10:44:44 +0100 (BST) Received: from localhost ([::1]:39420 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTgkb-0005dK-SA for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 05:44:43 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56762) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6K-0004Bj-D4 for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51460) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6K-0005ea-2z for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6J-0008QY-Ts for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 1/8] guix: Extract logic of the check-mirror-url. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292532262 (code B ref 57515); Thu, 01 Sep 2022 09:03:03 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:05 +0000 Received: from localhost ([127.0.0.1]:41198 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5M-0008OF-Sc for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:05 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48460) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5G-0008MC-0V for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:02 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1wpG; Thu, 01 Sep 2022 11:01:56 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:48 +0200 Message-Id: X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022916; bh=YnhOqcNcQ/RQIUdmgdFcuyUwVGldGNWnk3IXi0SMSqM=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=UtXQcQLKAXuA2YLuU+c2dFbG3dA8q3tKG3Z0TQAtHJUvXwzHd3pCf5txerp1kUbKr tzI8n0XOcTBvOhB3bZrSEyRpGhPy+N9MGpcRwlKgP09wtZ+jdgr69ngcnU9lq01Me+ j6PpZxwnwd67Uu2TEbfXv31xgqHCk6S71n4+uGuy2PqIHNTAQagXtsk0dCXD6MBJal EGnSgO/V/38SlGXIoGnWDE/6U0NMihNvFNpTftG1d8kL5jwHvzAjjCUHmV/hEkkiXf CiiHHjJutthmLPXvUJvD9B8hNv4s7C8GXka0WKSbAo7J0PVeuiaNBjT8vTnimYWifC 2GxjcJEXtHutQ== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches It will be useful for fixing #57477 ‘"guix refresh -u" sometimes 'unmirrors' source URLs’. * guix/lint.scm (check-mirror-url): Extract mirror://-constructing code to ... * guix/gnu-maintenance.scm (uri-mirror-rewrite): ... here, tweaking the API and implementation in anticipation of future users. --- guix/gnu-maintenance.scm | 23 +++++++++++++++++++++++ guix/lint.scm | 23 +++++++---------------- 2 files changed, 30 insertions(+), 16 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index e7edbf6656..51e8fcd815 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -2,6 +2,7 @@ ;;; Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès ;;; Copyright © 2012, 2013 Nikita Karetnikov ;;; Copyright © 2021 Simon Tournier +;;; Copyright © 2022 Maxime Devos ;;; ;;; This file is part of GNU Guix. ;;; @@ -32,6 +33,8 @@ (define-module (guix gnu-maintenance) #:use-module (rnrs io ports) #:use-module (system foreign) #:use-module ((guix http-client) #:hide (open-socket-for-uri)) + ;; not required in many cases, so autoloaded to reduce start-up costs. + #:autoload (guix download) (%mirrors) #:use-module (guix ftp-client) #:use-module (guix utils) #:use-module (guix memoization) @@ -57,6 +60,8 @@ (define-module (guix gnu-maintenance) find-package gnu-package? + uri-mirror-rewrite + release-file? releases latest-release @@ -651,6 +656,24 @@ (define (url-prefix-rewrite old new) (string-append new (string-drop url (string-length old))) url))) +(define (uri-mirror-rewrite uri) + "Rewrite URI to a mirror:// URI if possible. When not, return URI unmodified." + (if (string-prefix? "mirror://" uri) + ;; Nothing to do, it's already a mirror URI! + uri + (let loop ((mirrors %mirrors)) + (match mirrors + (() + uri) + (((mirror-id mirror-urls ...) rest ...) + (match (find (cut string-prefix? <> uri) mirror-urls) + (#f + (loop rest)) + (prefix + (format #f "mirror://~a/~a" + mirror-id + (string-drop uri (string-length prefix)))))))))) + (define (adjusted-upstream-source source rewrite-url) "Rewrite URLs in SOURCE by apply REWRITE-URL to each of them." (upstream-source diff --git a/guix/lint.scm b/guix/lint.scm index edba1c2663..ff7863ab86 100644 --- a/guix/lint.scm +++ b/guix/lint.scm @@ -12,7 +12,7 @@ ;;; Copyright © 2020 Chris Marusich ;;; Copyright © 2020 Timothy Sample ;;; Copyright © 2021 Xinglu Chen -;;; Copyright © 2021 Maxime Devos +;;; Copyright © 2021, 2022 Maxime Devos ;;; Copyright © 2021 Brice Waegeneire ;;; ;;; This file is part of GNU Guix. @@ -1223,21 +1223,12 @@ (define (check-source-uri uri) (define (check-mirror-url package) "Check whether PACKAGE uses source URLs that should be 'mirror://'." (define (check-mirror-uri uri) ;XXX: could be optimized - (let loop ((mirrors %mirrors)) - (match mirrors - (() - #f) - (((mirror-id mirror-urls ...) rest ...) - (match (find (cut string-prefix? <> uri) mirror-urls) - (#f - (loop rest)) - (prefix - (make-warning package - (G_ "URL should be \ -'mirror://~a/~a'") - (list mirror-id - (string-drop uri (string-length prefix))) - #:field 'source))))))) + (define maybe-rewritten-uri (uri-mirror-rewrite uri)) + (and (not (eq? uri maybe-rewritten-uri)) + (make-warning package + (G_ "URL should be '~a'") + (list maybe-rewritten-uri) + #:field 'source))) (let ((origin (package-source package))) (if (and (origin? origin) From patchwork Thu Sep 1 09:01:49 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 42105 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id BAF1127BBEA; Thu, 1 Sep 2022 10:36:22 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 39DB327BBE9 for ; Thu, 1 Sep 2022 10:36:22 +0100 (BST) Received: from localhost ([::1]:59194 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTgcX-00042f-1V for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 05:36:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56748) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6I-00045a-1C for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51454) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6H-0005dP-NE for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6H-0008Pq-I9 for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 2/8] gnu-maintenance: Produce mirror:// URIs in latest-ftp-release. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292332197 (code B ref 57515); Thu, 01 Sep 2022 09:03:01 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:03 +0000 Received: from localhost ([127.0.0.1]:41186 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5J-0008Mc-1u for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:02 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48464) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5G-0008MD-0W for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:00 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1wpV; Thu, 01 Sep 2022 11:01:56 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:49 +0200 Message-Id: <309bbf185a707fee8f98f741aa5a67fdce6cfda0.1662022775.git.maximedevos@telenet.be> X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022916; bh=xh22UhyedYkV0zVtoEkbC+QgmQtIwk7SHwnFAz9nj14=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=b2benSyhyHsVvkuODUR/jUtu1bN6UpkBbg6geR2DnOK1HjMcVEPwo+6dX7v5vG7l6 oaK6KsLpxWHkeahB4Vf4+ffC5hyg5I7cm92GVwxLb6YO8qTzf9QX2Z37e6yX6f7pMH eEgxFJ3g6C58w8DbY3C8fLCJJCiC6xh5rr4DbCk/AHENuBvREAPYKnLtfV5KtDMRP5 34FeQwJSz3a6aYR8phci9ZKCkPQVAhGQ8Semjg7JpqTKbRvaOUDog0Dv4j9+wAHpe2 ECHDKvxGiRBOGGlZxvNFi7cBi08vJxvZxHvY7e2ek5AaRWWM9V2WMT0pg8yCihtInI zqT4Yn0kpvJFg== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches Partially fixes: https://issues.guix.gnu.org/57477. As a test, try updating gnupg. Before the patch, a ftp:// URL was produced, now the mirror:// is preserved. * guix/gnu-maintenance.scm (latest-ftp-release)[file->source]{urls,signature-urls}: Call uri-mirror-rewrite on the URLs. --- guix/gnu-maintenance.scm | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 51e8fcd815..84fd087319 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -363,10 +363,12 @@ (define (file->source directory file) (upstream-source (package project) (version (tarball->version file)) - (urls (list url)) + ;; uri-mirror-rewrite: Don't turn nice mirror:// URIs into ftp:// + ;; URLs during "guix refresh -u". + (urls (list (uri-mirror-rewrite url))) (signature-urls (match (file->signature url) (#f #f) - (sig (list sig))))))) + (sig (list (uri-mirror-rewrite sig)))))))) (let loop ((directory directory) (result #f)) From patchwork Thu Sep 1 09:01:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 42111 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 2B8CB27BBEA; Thu, 1 Sep 2022 11:04:48 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id B7D3527BBE9 for ; Thu, 1 Sep 2022 11:04:47 +0100 (BST) Received: from localhost ([::1]:36984 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTh42-0000tS-SH for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 06:04:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56750) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6I-00047I-Ns for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51455) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6I-0005dU-AL for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6H-0008Px-Tc for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 3/8] gnu-maintenance: Produce mirror:// URIs in latest-html-release. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292332215 (code B ref 57515); Thu, 01 Sep 2022 09:03:01 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:03 +0000 Received: from localhost ([127.0.0.1]:41188 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5K-0008NG-UT for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:03 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48474) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5G-0008ME-0S for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:00 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1wpZ; Thu, 01 Sep 2022 11:01:56 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:50 +0200 Message-Id: X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022916; bh=wLsvPwlYd2XNSjRPCGUV2yb4QPUKFBjiSxlxu1o8s30=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=OrRfBIaO48nbc0+PgNRcdwObyfCTZWCi500fc0hhskIXEPqeENzyFdJFEqUfFDnCe GGAEO2b4soWxQ4WLoT7AGIzjmrw3YAagaSwgxaIQ/VBlpG4PleNAGG1ZsXPfbGMmPa 7OmmYTxohjjCwiFVBIY9Kdgoe7Oi2NzGw177NpbMa5biHFtByoZq5FsOtMnlEdkYJ1 Zk9bP9X9wTcsWdG9eJMKJtH3A9zqhJQeWvn5X937WzcJNfcuL4x+URZB3O5KBUzEPc eQUHRp0aOt95IN5je3woxGNkRo+OobgmUdPHS9yJq162pWf6qi1/oZzUqOT53FvsOo +n3vOzoeAkPhg== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches Partially fixes: https://issues.guix.gnu.org/57477. TODO: test case, it's http! I'm not aware of a package using both latest-html-release and mirrors, so it has not been completely tested. However, updating "yt-dlp" appears to work (except for git-fetch not being supported yet). The expression for the signature-urls field had to be tweaked to not call uri-mirror-rewrite on #false. * guix/gnu-maintenance.scm (latest-html-release)[url->research]{urls,signature-urls}: Call uri-mirror-rewrite on the URLs. --- guix/gnu-maintenance.scm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 84fd087319..2f09539d5d 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -532,9 +532,12 @@ (define (url->release url) (upstream-source (package package) (version version) - (urls (list url)) + ;; uri-mirror-rewrite: Don't turn nice mirror:// URIs into ftp:// + ;; URLs during "guix refresh -u". + (urls (list (uri-mirror-rewrite url))) (signature-urls - (list ((or file->signature file->signature/guess) url)))))))) + (and=> ((or file->signature file->signature/guess) url) + (lambda (url) (list (uri-mirror-rewrite url)))))))))) (define candidates (filter-map url->release links)) From patchwork Thu Sep 1 09:01:51 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 42106 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id E1C9E27BBEA; Thu, 1 Sep 2022 10:42:59 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 6BC3427BBE9 for ; Thu, 1 Sep 2022 10:42:59 +0100 (BST) Received: from localhost ([::1]:46020 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTgiw-0002t4-Ia for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 05:42:58 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56758) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6J-00049V-HW for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51458) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6J-0005eC-7I for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6J-0008QJ-39 for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 4/8] download: Switch savannah mirrors to HTTPS URLs. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292432247 (code B ref 57515); Thu, 01 Sep 2022 09:03:03 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:04 +0000 Received: from localhost ([127.0.0.1]:41194 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5M-0008Nw-3e for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:04 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48484) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5G-0008MF-0W for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:01 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1xpa; Thu, 01 Sep 2022 11:01:57 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:51 +0200 Message-Id: <4555fb7dfa08f956bbfc8179772c7288c34b1f97.1662022775.git.maximedevos@telenet.be> X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022917; bh=LnX+3sXb1rz2bcyqeg5L1cecjXJb1pcNeESpqg13Xv4=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=EQEp2t3aMIOBRo8NVaahnCW7+Vil+z/F8L4QxNxzvWtNttyUbxSCa33Y4xiE+m7v8 /t/BTTLaT/n4ZZ51oDtUsa4qmiwkUqQ4EpdPk/COgyb5YGMlxPYZ6nf6Chp4cXRGAv rL69vcCj/g4sNzkNgc4Cks4g07zNr3R6AP25tPYZqrDroPvJOUUEVLr+rGbKqzYZIO PvqPWbAzqlZiUi8a5lYVOf+LYS8BgG/jtJBoGGrPyQ21oTpOh7laeEa0H2KJhBOKrY Bc28RzCSFAdzVr2fqF2K5hNqVsTLABW4JzPo5BKVDiFEYlPU77eYuBNcWQa9kXgaJ2 AKLxHUWq65FyA== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches The URI scheme used for nongnu.freemirror.org needs to be consistent between (guix download) and (guix gnu-maintenance) to make the simplified savannah-updater (of a later commit) work. While we're at it, switch the other mirrors to https as well. http://download.savannah.gnu.org/releases-noredirect/ is left unmodified because it 404s * download.scm (%mirrors)[savannah]: Switch from http to https where possible. --- guix/download.scm | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/guix/download.scm b/guix/download.scm index d459ba8cf1..ac88b215de 100644 --- a/guix/download.scm +++ b/guix/download.scm @@ -96,15 +96,15 @@ (define %mirrors (hackage "http://hackage.haskell.org/") (savannah ; http://download0.savannah.gnu.org/mirmon/savannah/ - "http://download.savannah.gnu.org/releases/" - "http://nongnu.freemirror.org/nongnu/" - "http://ftp.cc.uoc.gr/mirrors/nongnu.org/" - "http://ftp.twaren.net/Unix/NonGNU/" - "http://mirror.csclub.uwaterloo.ca/nongnu/" - "http://nongnu.askapache.com/" - "http://savannah.c3sl.ufpr.br/" + "https://download.savannah.gnu.org/releases/" + "https://nongnu.freemirror.org/nongnu/" + "https://ftp.cc.uoc.gr/mirrors/nongnu.org/" + "http://ftp.twaren.net/Unix/NonGNU/" ; https appears unsupported + "https://mirror.csclub.uwaterloo.ca/nongnu/" + "https://nongnu.askapache.com/" + "https://savannah.c3sl.ufpr.br/" "http://download.savannah.gnu.org/releases-noredirect/" - "http://download-mirror.savannah.gnu.org/releases/" + "https://download-mirror.savannah.gnu.org/releases/" "ftp://ftp.twaren.net/Unix/NonGNU/" "ftp://mirror.csclub.uwaterloo.ca/nongnu/" "ftp://mirror.publicns.net/pub/nongnu/" From patchwork Thu Sep 1 09:01:52 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 42112 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id E467D27BBEA; Thu, 1 Sep 2022 11:07:30 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 8EB7527BBE9 for ; Thu, 1 Sep 2022 11:07:30 +0100 (BST) Received: from localhost ([::1]:54282 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTh6f-0001QH-MZ for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 06:07:29 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56752) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6I-00047M-PZ for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51456) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6I-0005dZ-Dx for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6I-0008Q5-91 for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 5/8] gnu-maintenance: Simplify latest-savannah-release. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292332224 (code B ref 57515); Thu, 01 Sep 2022 09:03:02 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:03 +0000 Received: from localhost ([127.0.0.1]:41190 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5L-0008NY-DU for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:03 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48522) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5G-0008MI-38 for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:01 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1xpg; Thu, 01 Sep 2022 11:01:57 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:52 +0200 Message-Id: X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022917; bh=Fi9j90kA3p+THPjRx9ru5spWvmzejwnCKdk9PgB0sUo=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=kqpxAAnoJo0z0IHfMSoec+PUeQtAW/TfB0f6Frm1Q1Irp542i4Jeho3zWY6p1kjwf IY2kKJq7BKt3z8/30e2k3ABTAS75gd8wpR5q8DIqIAt9RrTzFYkNaybtiTanbHPMNG mJ//96yiwBrffFCEgkZlQgKOCF9weXsIdqTpJNygsei4vY/zkjLWd6ElG4azuvy5IY J32LWyQopQFdImwRaE+ynzuL2ZLte9RICDUkb10gwcjZnz5ZVkBPbvAxkSgFU+51Xe DPyoXWg7JdvpAjV9IIzQlCkDPDciN4QQLMUitNYUEWCvIsJGXOJGyLi4DVta+y2PkY ev7qp4laGxOcQ== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches As latest-html-release now produces mirror:// URIs where possible, the additional post-processing is not necessary anymore. As a test, try updating 'gash', the mirror:// URI remains. * gnu-maintenance.scm (latest-savannah-release): Do not call adjusted-upstream-source on the result. --- guix/gnu-maintenance.scm | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 2f09539d5d..853ad91ea0 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -701,15 +701,12 @@ (define (latest-savannah-release package) ((? string? uri) uri) ((uri mirrors ...) uri)))) (package (package-upstream-name package)) - (directory (dirname (uri-path uri))) - (rewrite (url-prefix-rewrite %savannah-base - "mirror://savannah"))) + (directory (dirname (uri-path uri)))) ;; Note: We use the default 'file->signature', which adds ".sig", ".asc", ;; or whichever detached signature naming scheme PACKAGE uses. - (and=> (latest-html-release package - #:base-url %savannah-base - #:directory directory) - (cut adjusted-upstream-source <> rewrite)))) + (latest-html-release package + #:base-url %savannah-base + #:directory directory))) (define (latest-sourceforge-release package) "Return the latest release of PACKAGE." From patchwork Thu Sep 1 09:01:53 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 42107 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id B673A27BBEA; Thu, 1 Sep 2022 10:43:58 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 58B7F27BBE9 for ; Thu, 1 Sep 2022 10:43:58 +0100 (BST) Received: from localhost ([::1]:60948 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTgjt-00054s-CE for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 05:43:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56756) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6J-00048t-D0 for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51457) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6I-0005ds-Ts for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6I-0008QC-OT for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 6/8] download: Add a kernel.org mirror. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292432240 (code B ref 57515); Thu, 01 Sep 2022 09:03:02 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:04 +0000 Received: from localhost ([127.0.0.1]:41192 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5L-0008Nh-P1 for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:04 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48536) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5G-0008MJ-Dn for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:01 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1xpk; Thu, 01 Sep 2022 11:01:57 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:53 +0200 Message-Id: X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022917; bh=9Ww1pToJ0+9YpHQRBxnz86/iazib0nE2lkDjEXfdpLc=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=R0VSHnByvBg19pdqYn2AzSkbYtrlDzHBpvly3y8synixujy+PUo7SM4uFHqs3cNPu Y1kZe72afKD3Zu9195grImWI+VrQd+qXnvL40LP+VTFzQps6oTstJtYBP78RnvyEjz eRKHYLDUSm902Z5jjxUYPuZXtqk+SDq8EKhRwRDWXMreU43hKSBGAmjbltAasWD5ZR 5/W/Ff+OZO0nainOeyzFMBk+pWzS0v1u1AToXVUbYRDscYJETVCY/oH2rwAh2ogkcN NOuYmgc6mXKNCa+agI6oWxmoGW/hyz4ofOwZEWS/732epiuqpmQXVxfj/iy640kCzr 5zX1PNR9OhRUg== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches Add the mirror from (guix gnu-maintenance) to make the simplified linux.org updater (of a later commit) work. * download.scm (%mirrors)[kernel.org]: Add mirrors.edge.kernel.org mirror. --- guix/download.scm | 1 + 1 file changed, 1 insertion(+) diff --git a/guix/download.scm b/guix/download.scm index ac88b215de..29a8f99034 100644 --- a/guix/download.scm +++ b/guix/download.scm @@ -138,6 +138,7 @@ (define %mirrors "http://kernel.osuosl.org/pub/" "http://ftp.be.debian.org/pub/" "http://mirror.linux.org.au/" + "https://mirrors.edge.kernel.org/pub/" "ftp://ftp.funet.fi/pub/mirrors/ftp.kernel.org/pub/") (apache ; from http://www.apache.org/mirrors/dist.html "http://www.eu.apache.org/dist/" From patchwork Thu Sep 1 09:01:54 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 42113 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 7DF1D27BBEA; Thu, 1 Sep 2022 11:08:34 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 279C627BBE9 for ; Thu, 1 Sep 2022 11:08:34 +0100 (BST) Received: from localhost ([::1]:59344 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTh7h-000243-9O for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 06:08:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56760) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6K-0004Ao-1f for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51459) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6J-0005eP-MW for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6J-0008QR-HY for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 7/8] gnu-maintenance: Simplify latest-kernel.org-release. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292432253 (code B ref 57515); Thu, 01 Sep 2022 09:03:03 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:04 +0000 Received: from localhost ([127.0.0.1]:41196 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5M-0008O6-Hv for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:04 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48542) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5G-0008MK-Nw for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:02 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1ypl; Thu, 01 Sep 2022 11:01:58 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:54 +0200 Message-Id: <257f93bd56925c02cd7b42ccda3607a048c38f61.1662022775.git.maximedevos@telenet.be> X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022918; bh=VzHBqdK/iz3zrJvWiF7iy38ySu/L4mhgy/lgdXM0JeM=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=hutIZBkL9dvgkUlwRAoTD5ceG/jxMM+wNTnAT5zXmkZK2tdZXPYLHDQs9ialQ6o0B L7Cw75kmng4vxDTsGdzZogucQaRR2hBrrQZMLYpfclS7N8ElqxTczapR7U/Qi98J2g xq5Iqle6XegfGaigTw9B0qee8j6RIsHzhftbdLNfVn6i9HX2J8oVyf4AQv2fHOlPE8 uM7AuhcOoROgoud9TaTHZ42Rp28OkihnUdpdZ5W3Uf5PeX/WTt3263U1kqW9AUNKJH ZB2rsF0t+4LWhRuaNEfCKR6zTaJ6Wuh1zNVKiilxxLNjJnBcAl4YW9JXwxAmTPCGkz 2SNif1pD4qbYw== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches As latest-html-release now produces mirror:// URIs where possible, the additional post-processing is not necessary anymore. As a test, revert the dtc package back to 1.6.0 and try updating 'gash', the mirror:// URI remains. * gnu-maintenance.scm (latest-kernel.org-release): Do not call adjusted-upstream-source on the result. --- guix/gnu-maintenance.scm | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 853ad91ea0..7cb830b849 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -786,14 +786,11 @@ (define (file->signature file) ((? string? uri) uri) ((uri mirrors ...) uri)))) (package (package-upstream-name package)) - (directory (dirname (uri-path uri))) - (rewrite (url-prefix-rewrite %kernel.org-base - "mirror://kernel.org"))) - (and=> (latest-html-release package - #:base-url %kernel.org-base - #:directory directory - #:file->signature file->signature) - (cut adjusted-upstream-source <> rewrite)))) + (directory (dirname (uri-path uri)))) + (latest-html-release package + #:base-url %kernel.org-base + #:directory directory + #:file->signature file->signature))) (define html-updatable-package? ;; Return true if the given package may be handled by the generic HTML From patchwork Thu Sep 1 09:01:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: M X-Patchwork-Id: 42109 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 5CD4B27BBEA; Thu, 1 Sep 2022 10:50:22 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 1967727BBE9 for ; Thu, 1 Sep 2022 10:50:22 +0100 (BST) Received: from localhost ([::1]:37390 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTgq4-0003H6-Tm for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 05:50:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56766) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTg6L-0004Em-NO for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:05 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51461) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTg6L-0005em-DT for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:05 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTg6K-0008Qf-8M for guix-patches@gnu.org; Thu, 01 Sep 2022 05:03:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 8/8] gnu-maintenance: Remove unused procedures. Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:03:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.166202292532268 (code B ref 57515); Thu, 01 Sep 2022 09:03:04 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:02:05 +0000 Received: from localhost ([127.0.0.1]:41200 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5N-0008OJ-Bn for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:05 -0400 Received: from michel.telenet-ops.be ([195.130.137.88]:48570) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTg5H-0008MM-1V for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:02:02 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by michel.telenet-ops.be with bizsmtp id EZ1v2800K20ykKC06Z1ypo; Thu, 01 Sep 2022 11:01:58 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:01:55 +0200 Message-Id: X-Mailer: git-send-email 2.37.2 In-Reply-To: References: MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662022918; bh=Xh2MF+WpZdM5OexEnj8iytn8oG05m5B11sJLCDYTDq8=; h=From:To:Subject:Date:In-Reply-To:References:Reply-To; b=cPAGP8YD+gmKcTLkzc27oUCfR3MQ4/up98ElSZ1FHNLMSZLpC1DkzlKJlUtD9WWhM yYOA54t9F3TR6E0dPLAF7WF6AP+e4IcQWtyQl2b5E9G6heqZJiNpM1psPgmJ1G5+5z 2oHtAEXhbbW24yI7nnqZMep3y1tfFmY8ifnVtytxh7+JlrAQYKC2948K/v4LUOjtLN D8Rj4jbj9UAv11x8FgHxOAMkffauPQgL4UMzOrK98Vu5/kMyklqJgoQTtvQQdd9rG0 MZzKHCydv5EdYS05cIm9G6kMTPZxSlgTIuIZUXLtp8rr3jKYt1zWtMApH/iWLgypct R1GzmalJELavQ== 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: , Reply-To: 57515@debbugs.gnu.org Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * guix/gnu-maintenance.scm (url-prefix-rewrite, adjusted-upstream-source): Remove. --- guix/gnu-maintenance.scm | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 7cb830b849..2e8b08caa3 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -654,13 +654,6 @@ (define (pure-gnu-package? package) (define gnu-hosted? (url-prefix-predicate "mirror://gnu/")) -(define (url-prefix-rewrite old new) - "Return a one-argument procedure that rewrites URL prefix OLD to NEW." - (lambda (url) - (if (and url (string-prefix? old url)) - (string-append new (string-drop url (string-length old))) - url))) - (define (uri-mirror-rewrite uri) "Rewrite URI to a mirror:// URI if possible. When not, return URI unmodified." (if (string-prefix? "mirror://" uri) @@ -679,15 +672,6 @@ (define (uri-mirror-rewrite uri) mirror-id (string-drop uri (string-length prefix)))))))))) -(define (adjusted-upstream-source source rewrite-url) - "Rewrite URLs in SOURCE by apply REWRITE-URL to each of them." - (upstream-source - (inherit source) - (urls (map rewrite-url (upstream-source-urls source))) - (signature-urls (and=> (upstream-source-signature-urls source) - (lambda (urls) - (map rewrite-url urls)))))) - (define %savannah-base ;; One of the Savannah mirrors listed at ;; that serves valid From patchwork Thu Sep 1 09:43:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: M X-Patchwork-Id: 42110 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 3F89B27BBEA; Thu, 1 Sep 2022 10:52:52 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id CB01627BBE9 for ; Thu, 1 Sep 2022 10:52:51 +0100 (BST) Received: from localhost ([::1]:57382 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oTgsU-0006eZ-VP for patchwork@mira.cbaines.net; Thu, 01 Sep 2022 05:52:51 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:35600) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oTgjz-0005j3-KU for guix-patches@gnu.org; Thu, 01 Sep 2022 05:44:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:51516) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oTgjz-0003vF-9X for guix-patches@gnu.org; Thu, 01 Sep 2022 05:44:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oTgjx-00012z-VS for guix-patches@gnu.org; Thu, 01 Sep 2022 05:44:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#57515] [PATCH 9/9] tests/gnu-maintenance: Test latest-html-release. References: In-Reply-To: Resent-From: Maxime Devos Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 01 Sep 2022 09:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57515 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 57515@debbugs.gnu.org Cc: Maxime Devos Received: via spool by 57515-submit@debbugs.gnu.org id=B57515.16620254253996 (code B ref 57515); Thu, 01 Sep 2022 09:44:01 +0000 Received: (at 57515) by debbugs.gnu.org; 1 Sep 2022 09:43:45 +0000 Received: from localhost ([127.0.0.1]:41265 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTgjg-00012O-Ny for submit@debbugs.gnu.org; Thu, 01 Sep 2022 05:43:45 -0400 Received: from xavier.telenet-ops.be ([195.130.132.52]:59370) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oTgjf-00012E-2m for 57515@debbugs.gnu.org; Thu, 01 Sep 2022 05:43:44 -0400 Received: from localhost.localdomain ([IPv6:2a02:1811:8c09:9d00:5dba:d409:33f7:a16]) by xavier.telenet-ops.be with bizsmtp id EZjg2800620ykKC01ZjgAt; Thu, 01 Sep 2022 11:43:41 +0200 From: Maxime Devos Date: Thu, 1 Sep 2022 11:43:38 +0200 Message-Id: <20220901094338.12499-1-maximedevos@telenet.be> X-Mailer: git-send-email 2.37.2 MIME-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telenet.be; s=r22; t=1662025421; bh=enSES2dlqhEnaztwWWQvhzta54+9FnCJVvIZZW8wjP8=; h=From:To:Cc:Subject:Date; b=JIGgqShJTIrvYio7CyMMZ7a4dUiljQxkhVYLy4zP41kouPkVO18orx0wWTVaReqW6 iU6giHChlyK4Mwx344MebvFI7+mfXqT8Qern20vAOCJebo5G6t2AuQh8rsbnYusqFW vIxV78wumB45kdvDgiPI/fFSDpEv31UKXDdoV2vTaZkK079lJlA3xtwFa6FVmX2mLa SGZldR+ILGfylPPjSJhS1qmjqa8IaDA8brlcvGh7YW8TL2M11kBtsmU7w/nJR4s02n dX0TYHuXGtOOWxipGF4K3r6+Go3aahjMtgisCCbj2mGtGN2nn0T5L5JmeDB1g8IJ42 v/eGgZegnKXbQ== 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+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" X-getmail-retrieved-from-mailbox: Patches * tests/gnu-maintenance.scm ("latest-html-release, no signature") ("latest-html-release, signature): Two new tests. --- tests/gnu-maintenance.scm | 70 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 69 insertions(+), 1 deletion(-) diff --git a/tests/gnu-maintenance.scm b/tests/gnu-maintenance.scm index c04d8ba733..a9e2a0bb9f 100644 --- a/tests/gnu-maintenance.scm +++ b/tests/gnu-maintenance.scm @@ -1,5 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2015, 2021 Ludovic Courtès +;;; Copyright © 2022 Maxime Devos ;;; ;;; This file is part of GNU Guix. ;;; @@ -18,9 +19,14 @@ (define-module (test-gnu-maintenance) #:use-module (guix gnu-maintenance) + #:use-module (guix tests) + #:use-module (guix tests http) + #:use-module (guix upstream) + #:use-module (guix utils) #:use-module (srfi srfi-1) #:use-module (srfi srfi-64) - #:use-module (ice-9 match)) + #:use-module (ice-9 match) + #:use-module (ice-9 textual-ports)) (test-begin "gnu-maintenance") @@ -55,4 +61,66 @@ (define-module (test-gnu-maintenance) ("mpg321_0.3.2.orig.tar.gz" "0.3.2") ("bvi-1.4.1.src.tar.gz" "1.4.1"))))) +(test-assert "latest-html-release, no signature" + (with-http-server + `((200 " + +Releases! + + +version 1 +version 2 + +")) + (let () + (define package + (dummy-package "foo" + (source + (dummy-origin + (uri (string-append (%local-url) "/foo-1.tar.gz")))) + (properties + `((release-monitoring-url . ,(%local-url)))))) + (define update ((upstream-updater-latest %generic-html-updater) package)) + (define expected-new-url + (string-append (%local-url) "/foo-2.tar.gz")) + (and (pk 'u update) + (equal? (upstream-source-version update) "2") + (equal? (list expected-new-url) + (upstream-source-urls update)) + (null? ;; both #false and the empty list are acceptable + (or (upstream-source-signature-urls update) '())))))) + +(test-assert "latest-html-release, signature" + (with-http-server + `((200 " + +Signed releases! + + +version 1 +version 2 +version 1 signature +version 2 signature + +")) + (let () + (define package + (dummy-package "foo" + (source + (dummy-origin + (uri (string-append (%local-url) "/foo-1.tar.gz")))) + (properties + `((release-monitoring-url . ,(%local-url)))))) + (define update ((upstream-updater-latest %generic-html-updater) package)) + (define expected-new-url + (string-append (%local-url) "/foo-2.tar.gz")) + (define expected-signature-url + (string-append (%local-url) "/foo-2.tar.gz.sig")) + (and (pk 'u update) + (equal? (upstream-source-version update) "2") + (equal? (list expected-new-url) + (upstream-source-urls update)) + (equal? (list expected-signature-url) + (upstream-source-signature-urls update)))))) + (test-end)