From patchwork Fri Nov 19 21:05:58 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vagrant Cascadian X-Patchwork-Id: 34649 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 F3CB827BBE3; Fri, 19 Nov 2021 21:07:28 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id AA93327BBE1 for ; Fri, 19 Nov 2021 21:07:28 +0000 (GMT) Received: from localhost ([::1]:53616 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1moB6V-0004ai-OV for patchwork@mira.cbaines.net; Fri, 19 Nov 2021 16:07:27 -0500 Received: from eggs.gnu.org ([209.51.188.92]:59560) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1moB67-0004aV-JL for guix-patches@gnu.org; Fri, 19 Nov 2021 16:07:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:57352) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1moB66-00031t-9j for guix-patches@gnu.org; Fri, 19 Nov 2021 16:07:03 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1moB66-0001IY-5O for guix-patches@gnu.org; Fri, 19 Nov 2021 16:07:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#51985] lint: Adjust patch file length check. Resent-From: Vagrant Cascadian Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 19 Nov 2021 21:07:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 51985 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: To: 51985@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.16373559754917 (code B ref -1); Fri, 19 Nov 2021 21:07:01 +0000 Received: (at submit) by debbugs.gnu.org; 19 Nov 2021 21:06:15 +0000 Received: from localhost ([127.0.0.1]:40665 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1moB5L-0001HF-En for submit@debbugs.gnu.org; Fri, 19 Nov 2021 16:06:15 -0500 Received: from lists.gnu.org ([209.51.188.17]:55112) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1moB5K-0001H8-DJ for submit@debbugs.gnu.org; Fri, 19 Nov 2021 16:06:14 -0500 Received: from eggs.gnu.org ([209.51.188.92]:59452) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1moB5J-0004Qu-SD for guix-patches@gnu.org; Fri, 19 Nov 2021 16:06:14 -0500 Received: from cascadia.aikidev.net ([173.255.214.101]:35680) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1moB5E-0002p1-Ti for guix-patches@gnu.org; Fri, 19 Nov 2021 16:06:13 -0500 Received: from localhost (unknown [IPv6:2600:3c01:e000:21:21:21:0:100b]) (Authenticated sender: vagrant@cascadia.debian.net) by cascadia.aikidev.net (Postfix) with ESMTPSA id D2D6F1AA41 for ; Fri, 19 Nov 2021 13:06:01 -0800 (PST) From: Vagrant Cascadian Date: Fri, 19 Nov 2021 13:05:58 -0800 Message-ID: <875ysnsvnt.fsf@yucca> MIME-Version: 1.0 Received-SPF: none client-ip=173.255.214.101; envelope-from=vagrant@debian.org; helo=cascadia.aikidev.net 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_NONE=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: 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 The current guix lint check is a bit overly conservative, and reports several results which do not in practice actually cause issues. This patch proposes to reduce the size by two characters (leaving only two patches on guix master that need to be adjusted), uses a version string more like what actually might be included in a tarball built using "make dist", and adds a comment describing what the arbitrary string actually is supposed to represent. This should still even leave a little wiggle-room when guix hits version 100+ and/or 1000000+ commits, by which time hopefully guix has switched to a tarball format that doesn't have such a short arbitrary file length limit! live well, vagrant From 6ad2050a8bbc308a328d30d4f66cb229d868b79d Mon Sep 17 00:00:00 2001 From: Vagrant Cascadian Date: Fri, 19 Nov 2021 12:14:19 -0800 Subject: [PATCH] lint: Adjust patch file length check. * guix/lint.scm (check-patch-file-names): Adjust margin used to check for patch file lengths. --- guix/lint.scm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/guix/lint.scm b/guix/lint.scm index ac2e7b3841..39b4a2ae85 100644 --- a/guix/lint.scm +++ b/guix/lint.scm @@ -957,7 +957,10 @@ patch could not be found." ;; Check whether we're reaching tar's maximum file name length. (let ((prefix (string-length (%distro-directory))) - (margin (string-length "guix-2.0.0rc3-10000-1234567890/")) + ;; Margin approximating the largest path that "make dist" might + ;; create, with a release candidate version, 123456 commits, and + ;; git commit hash abcde0. + (margin (string-length "guix-12.0.0rc3-123456-abcde0/")) (max 99)) (filter-map (match-lambda ((? string? patch) -- 2.30.2