unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Vagrant Cascadian <vagrant@debian.org>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: guix-devel@gnu.org
Subject: Re: default tar format for "make dist" and patch file length
Date: Wed, 17 Nov 2021 15:49:49 -0800	[thread overview]
Message-ID: <87czmy8hr6.fsf@ponder> (raw)
In-Reply-To: <87fsru8l05.fsf@ponder>

[-- Attachment #1: Type: text/plain, Size: 2429 bytes --]

On 2021-11-17, Vagrant Cascadian wrote:
> On 2021-11-17, Ludovic Courtès wrote:
>> Vagrant Cascadian <vagrant@debian.org> skribis:
>>
>>> Ideally, "guix lint" would be run and issues fixed before applying
>>> patches ... !
...
>>> Is it worth adding an inexpensive check to etc/git/pre-push that also
>>> checks for file-length and fails to push due to this issue potentially
>>> breaking "make dist"?
...
> This basically mimics the check that guix-lint does:
>
> for p in $(find gnu/packages/patches -type f ) ; do
>   if [ "$(echo guix-2.0.0rc3-10000-1234567890/${p} | wc -c)" -ge "99" ]
>   then
>     echo $p
>     exit 1
>   fi
> done
>
> Would something like that be cheap enough to consider adding to
> etc/git/pre-push? Are "find" and "wc" reasonable dependencies to assume
> they are available?
>
> Obviously, have to wait until they are all fixed, some of which probably
> require going through core-updates... or start with a more conservative
> but still useful length-check.

Another strategy would be to reduce the overly cautious lint check:

diff --git a/guix/lint.scm b/guix/lint.scm
index ac2e7b3841..e795c466b1 100644
--- a/guix/lint.scm
+++ b/guix/lint.scm
@@ -957,7 +957,7 @@ (define (starts-with-package-name? file-name)

      ;; 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 (string-length "guix-2.0.0rc3-10000-12345678/"))
            (max    99))
        (filter-map (match-lambda
                      ((? string? patch)


That leaves only two packages on master in violation of the lint check,
and those are both updatable directly on master, and "make dist" still
works with those two packages as they are, in my experience.

I think that's fairly safe to do, actually, as "make dist" on
core-updates-frozen currently produces a tarball prefixed with:

  guix-1.3.0.10380-fe257/

If guix keeps bumping it's version into the double-digits, an
rc-version, and it surpasses 99999 commits, and an extra character for
the git commit hash, this still leaves considerable wiggle-room:

  guix-10.0.0rc0-123456-abcde0/
vs.
  guix-2.0.0rc3-10000-12345678/

So, I guess I'm leaning towards making the guix lint check a little more
lenient.

Thoughts?


live well,
  vagrant

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

  reply	other threads:[~2021-11-17 23:50 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-16  0:34 default tar format for "make dist" and patch file length Vagrant Cascadian
2021-11-17 11:32 ` Ludovic Courtès
2021-11-17 22:39   ` Vagrant Cascadian
2021-11-17 23:49     ` Vagrant Cascadian [this message]
2021-11-19 14:54       ` Ludovic Courtès
2021-11-20  4:39         ` Philip McGrath
2021-11-20  5:21           ` Vagrant Cascadian
2021-11-24 21:27             ` Vagrant Cascadian
2021-11-22  2:03     ` Maxim Cournoyer
2021-11-22 11:31       ` Ludovic Courtès
2021-11-22 20:14         ` Maxim Cournoyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87czmy8hr6.fsf@ponder \
    --to=vagrant@debian.org \
    --cc=guix-devel@gnu.org \
    --cc=ludo@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).