GNU bug report logs - #53238
password-store fails to build with tree version 2

Previous Next

Package: guix;

Reported by: Olivier Dion <olivier.dion <at> polymtl.ca>

Date: Thu, 13 Jan 2022 20:34:01 UTC

Severity: normal

Tags: patch

Merged with 53272, 53288

Done: Marius Bakke <marius <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #23 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Tobias Geerinckx-Rice <me <at> tobias.gr>
To: Olivier Dion <olivier.dion <at> polymtl.ca>
Cc: 53238 <at> debbugs.gnu.org, guix-patches <at> gnu.org
Subject: Re: [bug#53238] [PATCH] gnu: tree: Remove stddata feature.
Date: Thu, 13 Jan 2022 23:33:29 +0100
[Message part 1 (text/plain, inline)]
Hullo Olivier,

I was going to apply the patch below to fix the password-store 
package, but Maxime just submitted another version which I prefer. 
I'd rather not provide two trees in Guix.

Olivier Dion 写道:
> I've contacted the maintainer asking for removal of the feature 
> in its
> next release.

After some consideration, I think it's an interesting feature. 
Something like this is long overdue.

I don't know if this approach is the right one, but I'll 
begrudgingly settle for JSON if it finally catches on…

> It's more than just packages, it's also user scripts that can be 
> broken

They can be fixed, or better yet rewritten.  tree(1) is not tr(1). 
‘Some lazy idiot could parse this with bash’ != ‘frozen API which 
upstream can never improve’.  Really.

…uh, I'm describing myself there, by the way ;-)  I feel quite 
seen.

Not that they needed to, but upstream even bumped the major 
revision along with this change.

> and believe me when I say that this is not an easy bug to track 
> down ;-).

Fully agree!  I wasted too much time trying to track it down 
myself.  I blame password-store's spaghetto of redirection more 
than tree.

Kind regards,

T G-R

[0004-gnu-password-store-Fix-failing-test-suite.patch (text/x-patch, inline)]
From e100fedb52df07738c2d535928c6c9f98042e07f Mon Sep 17 00:00:00 2001
From: Tobias Geerinckx-Rice <me <at> tobias.gr>
Date: Thu, 13 Jan 2022 13:45:25 +0000
Subject: [PATCH 04/26] gnu: password-store: Fix failing test suite.

* gnu/packages/admin.scm (tree-1): New public variable.
* gnu/packages/password-utils.scm (password-store)[inputs]:
Use it rather than the default tree <at> 2.

Reported by Maxim Cournoyer <maxim.cournoyer <at> gmail.com> and
Olivier Dion <olivier.dion <at> polymtl.ca>.
---
 gnu/packages/admin.scm          | 20 ++++++++++++++++++++
 gnu/packages/password-utils.scm |  3 ++-
 2 files changed, 22 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index f11374a439..c2e656db1a 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -2421,6 +2421,26 @@ (define-public tree
     (home-page "http://mama.indstate.edu/users/ice/tree/")
     (license license:gpl2+)))
 
+(define-public tree-1
+  ;; tree 2.0.0 introduced a feature called ‘stddata’ that emits JSON when
+  ;; output is directed to file descriptor 3.  At least password-store still
+  ;; requires the old version.
+  (package
+    (inherit tree)
+    (version "1.8.0")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append
+                    "http://mama.indstate.edu/users/ice/tree/src/tree-"
+                    version ".tgz"))
+              (sha256
+               (base32 "1hmpz6k0mr6salv0nprvm1g0rdjva1kx03bdf1scw8a38d5mspbi"))))
+    (arguments
+     (substitute-keyword-arguments (package-arguments tree)
+       ((#:make-flags flags '())
+        #~(append #$flags
+                  (list (string-append "prefix=" #$output))))))))
+
 (define-public lr
   (package
     (name "lr")
diff --git a/gnu/packages/password-utils.scm b/gnu/packages/password-utils.scm
index 0ff8608c9c..86af0deb47 100644
--- a/gnu/packages/password-utils.scm
+++ b/gnu/packages/password-utils.scm
@@ -552,7 +552,8 @@ (define-public password-store
        ("gnupg" ,gnupg)
        ("qrencode" ,qrencode)
        ("sed" ,sed)
-       ("tree" ,tree)
+       ;; XXX v1.7.4 tests are broken with tree <at> 2: <issues.guix.gnu.org/53238>.
+       ("tree" ,tree-1)
        ("which" ,which)
        ("wl-clipboard" ,wl-clipboard)
        ("xclip" ,xclip)
-- 
2.34.0

[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 3 years and 179 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.