GNU bug report logs - #42543
lint failure for packages on load path specified with -L

Previous Next

Package: guix;

Reported by: Jack Hill <jackhill <at> jackhill.us>

Date: Sun, 26 Jul 2020 04:21:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 42543 in the body.
You can then email your comments to 42543 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Sun, 26 Jul 2020 04:21:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to Jack Hill <jackhill <at> jackhill.us>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Sun, 26 Jul 2020 04:21:01 GMT) Full text and rfc822 format available.

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

From: Jack Hill <jackhill <at> jackhill.us>
To: bug-guix <at> gnu.org
Subject: lint failure for packages on load path specified with -L
Date: Sun, 26 Jul 2020 00:20:18 -0400 (EDT)
[Message part 1 (text/plain, inline)]
Hi Guix,

I'm running guix from commit 30aa5dd7e7180d163d409b080bf89e8a15a5ba4d. 
I've created a package in local directory lint-test. `guix lint` errors 
when processing this package, but other guix commands like build and show 
work as expected. A session with these commands:

```
jackhill <at> alperton ~$ guix lint -L lint-test my-hello
Backtrace:y-hello <at> 2.10 [formatting]...
           8 (primitive-load "/home/jackhill/.config/guix/current/bi…")
In guix/ui.scm:
  1974:12  7 (run-guix-command _ . _)
In ice-9/boot-9.scm:
  1736:10  6 (with-exception-handler _ _ #:unwind? _ # _)
In guix/store.scm:
   631:22  5 (thunk)
In srfi/srfi-1.scm:
    634:9  4 (for-each #<procedure 7f40c0484020 at guix/scripts/lin…> …)
In guix/scripts/lint.scm:
     60:4  3 (run-checkers _ _ #:store _)
In srfi/srfi-1.scm:
    634:9  2 (for-each #<procedure 7f40b2ab53f0 at guix/scripts/lin…> …)
    241:2  1 (for-each _ _)
In ice-9/boot-9.scm:
  1669:16  0 (raise-exception _ #:continuable? _)

ice-9/boot-9.scm:1669:16: In procedure raise-exception:
In procedure for-each: Wrong type argument: #f
jackhill <at> alperton ~$ guix build -L lint-test my-hello
/gnu/store/h21bncim3hshjpfbs1dn4kvg1ri6zb7z-my-hello-2.10
jackhill <at> alperton ~$ guix show -L lint-test my-hello
name: my-hello
version: 2.10
outputs: out
systems: x86_64-linux i686-linux
dependencies: 
location: lint-test/my-hello.scm:8:2
homepage: https://www.gnu.org/software/hello/
license: GPL 3+
synopsis: Hello, GNU world: An example GNU package 
description: GNU Hello prints the message "Hello, world!" and then
+ exits.  It serves as an example of standard GNU coding practices.  As
+ such, it supports command-line arguments, multiple languages, and so on.
```

my-hello.scm looks like:

```
(define-module (my-hello)
  #:use-module (guix build-system gnu)
  #:use-module (guix download)
  #:use-module (guix licenses)
  #:use-module (guix packages))

(define-public my-hello
  (package
    (name "my-hello")
    (version "2.10")
    (source (origin
              (method url-fetch)
              (uri (string-append "mirror://gnu/hello/hello-" version
                                  ".tar.gz"))
              (sha256
               (base32
                "0ssi1wpaf7plaswqqjwigppsg5fyh99vdlb9kzl7c9lng89ndq1i"))))
    (build-system gnu-build-system)
    (synopsis "Hello, GNU world: An example GNU package")
    (description
     "GNU Hello prints the message \"Hello, world!\" and then exits.  It
serves as an example of standard GNU coding practices.  As such, it supports
command-line arguments, multiple languages, and so on.")
    (home-page "https://www.gnu.org/software/hello/")
    (license gpl3+)))
```

Best,
Jack

Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Mon, 27 Jul 2020 03:37:02 GMT) Full text and rfc822 format available.

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

From: Jack Hill <jackhill <at> jackhill.us>
To: 42543 <at> debbugs.gnu.org
Subject: Re: lint failure for packages on load path specified with -L
Date: Sun, 26 Jul 2020 23:36:12 -0400 (EDT)
I believe that this problem is in the formatting checker. As I understand 
it, that checker reads the actual sorece file. With that information, I 
tried re-running link the the full path passed to -L, and it works as 
expected:

guix lint -L /home/jackhill/lint-test my-hello

passing just the relative path, i.e. ./lint-test does not work. Passing 
the full path also changes the local reported by guix show.

It seems like canonicalizing the locad path is the right thing to do.

Thoughts?
Jack




Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Mon, 27 Jul 2020 21:49:02 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: 42543 <at> debbugs.gnu.org
Cc: zimoun <zimon.toutoune <at> gmail.com>
Subject: [PATCH 0/2] Canonicalize 'load-path' option
Date: Mon, 27 Jul 2020 23:47:52 +0200
Dear,

These 2 patches 'canonicalize-path' the command-line argument.  I have not
enough power to burn CPU and run all the test suite.  But from my local test,
it seems ok.

The second patch “improves“ the 'load-path' option by re-using
'%standard-build-options'; which means importing (guix scripts build).  It
does not appear to me an issue and probably something historical and
forgotten. Otherwise, please tell me.


All the best,
simon

zimoun (2):
  scripts: build: Canonicalize 'load-path' option.
  scripts: repl: Canonicalize 'load-path' option.

 guix/scripts/build.scm | 10 ++++++----
 guix/scripts/repl.scm  | 10 ++++------
 2 files changed, 10 insertions(+), 10 deletions(-)


base-commit: 7b58d009a952e0c36446a0a5d06582f1e9822bb6
-- 
2.26.2





Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Mon, 27 Jul 2020 21:49:02 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: 42543 <at> debbugs.gnu.org
Cc: zimoun <zimon.toutoune <at> gmail.com>
Subject: [PATCH 1/2] scripts: build: Canonicalize 'load-path' option.
Date: Mon, 27 Jul 2020 23:47:53 +0200
Fixes <https://bugs.gnu.org/42543>.
Reported by Jack Hill <jackhill <at> jackhill.us>.

* guix/scripts/build.scm (%standard-build-options): Canonicalize 'load-path'.
---
 guix/scripts/build.scm | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/guix/scripts/build.scm b/guix/scripts/build.scm
index 8ff2fd1910..f41221dd43 100644
--- a/guix/scripts/build.scm
+++ b/guix/scripts/build.scm
@@ -3,6 +3,7 @@
 ;;; Copyright © 2013 Mark H Weaver <mhw <at> netris.org>
 ;;; Copyright © 2020 Marius Bakke <mbakke <at> fastmail.com>
 ;;; Copyright © 2020 Ricardo Wurmus <rekado <at> elephly.net>
+;;; Copyright © 2020 Simon Tournier <zimon.toutoune <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -568,10 +569,11 @@ talking to a remote daemon\n")))
   (list (option '(#\L "load-path") #t #f
                 (lambda (opt name arg result . rest)
                   ;; XXX: Imperatively modify the search paths.
-                  (%package-module-path (cons arg (%package-module-path)))
-                  (%patch-path (cons arg (%patch-path)))
-                  (set! %load-path (cons arg %load-path))
-                  (set! %load-compiled-path (cons arg %load-compiled-path))
+                  (let ((path (canonicalize-path arg)))
+                    (%package-module-path (cons path (%package-module-path)))
+                    (%patch-path (cons path (%patch-path)))
+                    (set! %load-path (cons path %load-path))
+                    (set! %load-compiled-path (cons path %load-compiled-path)))
 
                   (apply values (cons result rest))))
         (option '(#\K "keep-failed") #f #f

base-commit: 7b58d009a952e0c36446a0a5d06582f1e9822bb6
-- 
2.26.2





Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Mon, 27 Jul 2020 21:49:03 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: 42543 <at> debbugs.gnu.org
Cc: zimoun <zimon.toutoune <at> gmail.com>
Subject: [PATCH 2/2] scripts: repl: Canonicalize 'load-path' option.
Date: Mon, 27 Jul 2020 23:47:54 +0200
* guix/scripts/repl.scm: Use (guix scripts build) '%standard-build-options' to
deal with 'load-path' option.
---
 guix/scripts/repl.scm | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/guix/scripts/repl.scm b/guix/scripts/repl.scm
index 0ea9c3655c..59edb543d1 100644
--- a/guix/scripts/repl.scm
+++ b/guix/scripts/repl.scm
@@ -21,6 +21,7 @@
 (define-module (guix scripts repl)
   #:use-module (guix ui)
   #:use-module (guix scripts)
+  #:use-module ((guix scripts build) #:select (%standard-build-options))
   #:use-module (guix repl)
   #:use-module (srfi srfi-1)
   #:use-module (srfi srfi-26)
@@ -57,12 +58,9 @@
         (option '(#\q) #f #f
                 (lambda (opt name arg result)
                   (alist-cons 'ignore-dot-guile? #t result)))
-        (option '(#\L "load-path") #t #f
-                (lambda (opt name arg result)
-                  ;; XXX: Imperatively modify the search paths.
-                  (set! %load-path (cons arg %load-path))
-                  (set! %load-compiled-path (cons arg %load-compiled-path))
-                  result))))
+        (find (lambda (option)
+                (member "load-path" (option-names option)))
+              %standard-build-options)))
 
 
 (define (show-help)
-- 
2.26.2





Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Mon, 27 Jul 2020 21:55:02 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: Jack Hill <jackhill <at> jackhill.us>, 42543 <at> debbugs.gnu.org
Subject: Re: bug#42543: lint failure for packages on load path specified with
 -L
Date: Mon, 27 Jul 2020 23:54:10 +0200
Dear,

The issue was in the “formatting” and “source” checkers, something
inconsistent with other parts (see “search-path %load-path”).

Therefore, “--load-path=path/to/modules” is now ’canonicalize-path’,
directly in “(guix scripts build)%standard-build-options” from where the
other load-path options derive.

See patch http://issues.guix.gnu.org/42543#2


All the best,
simon




Added tag(s) patch. Request was from zimoun <zimon.toutoune <at> gmail.com> to control <at> debbugs.gnu.org. (Mon, 27 Jul 2020 22:55:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Tue, 28 Jul 2020 03:51:01 GMT) Full text and rfc822 format available.

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

From: Jack Hill <jackhill <at> jackhill.us>
To: zimoun <zimon.toutoune <at> gmail.com>
Cc: 42543 <at> debbugs.gnu.org
Subject: Re: bug#42543: lint failure for packages on load path specified with
 -L
Date: Mon, 27 Jul 2020 23:50:11 -0400 (EDT)
[Message part 1 (text/plain, inline)]
On Mon, 27 Jul 2020, zimoun wrote:

> Dear,
>
> The issue was in the “formatting” and “source” checkers, something
> inconsistent with other parts (see “search-path %load-path”).
>
> Therefore, “--load-path=path/to/modules” is now ’canonicalize-path’,
> directly in “(guix scripts build)%standard-build-options” from where the
> other load-path options derive.
>
> See patch http://issues.guix.gnu.org/42543#2

Thank you. I've applied the patches and it fixes the problem for me. My 
computer had some free cycles, so I ran the Guix test suite (make check) 
and all looks good:

============================================================================
Testsuite summary for GNU Guix 1.0.1.20277-f43458
============================================================================
# TOTAL: 1065
# PASS:  1058
# SKIP:  5
# XFAIL: 2
# FAIL:  0
# XPASS: 0
# ERROR: 0
============================================================================

Best wishes,
Jack

Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Wed, 05 Aug 2020 20:29:02 GMT) Full text and rfc822 format available.

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

From: Ludovic Courtès <ludo <at> gnu.org>
To: Jack Hill <jackhill <at> jackhill.us>
Cc: 42543 <at> debbugs.gnu.org
Subject: Re: bug#42543: lint failure for packages on load path specified with
 -L
Date: Wed, 05 Aug 2020 22:28:07 +0200
Hi,

Jack Hill <jackhill <at> jackhill.us> skribis:

> jackhill <at> alperton ~$ guix lint -L lint-test my-hello
> Backtrace:y-hello <at> 2.10 [formatting]...
>            8 (primitive-load "/home/jackhill/.config/guix/current/bi…")
> In guix/ui.scm:
>   1974:12  7 (run-guix-command _ . _)
> In ice-9/boot-9.scm:
>   1736:10  6 (with-exception-handler _ _ #:unwind? _ # _)
> In guix/store.scm:
>    631:22  5 (thunk)
> In srfi/srfi-1.scm:
>     634:9  4 (for-each #<procedure 7f40c0484020 at guix/scripts/lin…> …)
> In guix/scripts/lint.scm:
>      60:4  3 (run-checkers _ _ #:store _)
> In srfi/srfi-1.scm:
>     634:9  2 (for-each #<procedure 7f40b2ab53f0 at guix/scripts/lin…> …)
>     241:2  1 (for-each _ _)
> In ice-9/boot-9.scm:
>   1669:16  0 (raise-exception _ #:continuable? _)
>
> ice-9/boot-9.scm:1669:16: In procedure raise-exception:
> In procedure for-each: Wrong type argument: #f

I can’t reproduce this problem:

--8<---------------cut here---------------start------------->8---
$ cat /tmp/t/my-hello.scm
(define-module (my-hello)
  #:use-module (guix build-system gnu)
  #:use-module (guix download)
  #:use-module (guix licenses)
  #:use-module (guix packages))

(define-public my-hello
  (package
    (name "my-hello")
    (version "2.10")
    (source (origin
              (method url-fetch)
              (uri (string-append "mirror://gnu/hello/hello-" version
                                  ".tar.gz"))
              (sha256
               (base32
                "0ssi1wpaf7plaswqqjwigppsg5fyh99vdlb9kzl7c9lng89ndq1i"))))
    (build-system gnu-build-system)
    (synopsis "Hello, GNU world: An example GNU package")
    (description
     "GNU Hello prints the message \"Hello, world!\" and then exits.  It
serves as an example of standard GNU coding practices.  As such, it supports
command-line arguments, multiple languages, and so on.")
    (home-page "https://www.gnu.org/software/hello/")
    (license gpl3+)))
$ guix lint -L /tmp/t my-hello
$ echo $?
0
$ guix show -L /tmp/t my-hello
name: my-hello
version: 2.10
outputs: out
systems: x86_64-linux i686-linux
dependencies: 
location: /tmp/t/my-hello.scm:8:2
homepage: https://www.gnu.org/software/hello/
license: GPL 3+
synopsis: Saluton, mondo GNU: ekzemplo de pako GNU  
description: GNU Hello montras la mesaĝon "Hello, world!" kaj finiĝas.  Ĝi funkcias kiel ekzemplo de norma
+ kodumada tradicio de GNU.  Tiel, ĝi subtenas komand-liniajn argumentojn, plurajn lingvojn, kaj tiel plu.

$ guix describe
Generacio 152	Aug 04 2020 17:34:23	(nuna)
  guix abe3c5e
    repository URL: https://git.savannah.gnu.org/git/guix.git
    branch: master
    commit: abe3c5ed7d04985c987e6c81aeb1284354ea0c77
--8<---------------cut here---------------end--------------->8---

Do you still have this problem?

(Besides, ‘canonicalize-path’ should be used sparsely: it’s quite
expensive and sometimes confusing for users.  With the proposed patches,
“-L /does/not/exist” would now lead to an error.)

Thanks,
Ludo’.




Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Wed, 05 Aug 2020 21:43:01 GMT) Full text and rfc822 format available.

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

From: Jack Hill <jackhill <at> jackhill.us>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 42543 <at> debbugs.gnu.org
Subject: Re: bug#42543: lint failure for packages on load path specified with
 -L
Date: Wed, 5 Aug 2020 17:42:21 -0400 (EDT)
[Message part 1 (text/plain, inline)]
Hi Ludo’! Hope you've enjoyed your (short) time away from the keyboard :)

On Wed, 5 Aug 2020, Ludovic Courtès wrote:

> Hi,
>
> Jack Hill <jackhill <at> jackhill.us> skribis:
>
>> jackhill <at> alperton ~$ guix lint -L lint-test my-hello
>> Backtrace:y-hello <at> 2.10 [formatting]...
>>            8 (primitive-load "/home/jackhill/.config/guix/current/bi…")
>> In guix/ui.scm:
>>   1974:12  7 (run-guix-command _ . _)
>> In ice-9/boot-9.scm:
>>   1736:10  6 (with-exception-handler _ _ #:unwind? _ # _)
>> In guix/store.scm:
>>    631:22  5 (thunk)
>> In srfi/srfi-1.scm:
>>     634:9  4 (for-each #<procedure 7f40c0484020 at guix/scripts/lin…> …)
>> In guix/scripts/lint.scm:
>>      60:4  3 (run-checkers _ _ #:store _)
>> In srfi/srfi-1.scm:
>>     634:9  2 (for-each #<procedure 7f40b2ab53f0 at guix/scripts/lin…> …)
>>     241:2  1 (for-each _ _)
>> In ice-9/boot-9.scm:
>>   1669:16  0 (raise-exception _ #:continuable? _)
>>
>> ice-9/boot-9.scm:1669:16: In procedure raise-exception:
>> In procedure for-each: Wrong type argument: #f
>
> I can’t reproduce this problem:

[…]

> $ guix lint -L /tmp/t my-hello
> $ echo $?
> 0
> $ guix show -L /tmp/t my-hello
> name: my-hello
> version: 2.10
> outputs: out
> systems: x86_64-linux i686-linux
> dependencies:
> location: /tmp/t/my-hello.scm:8:2
> homepage: https://www.gnu.org/software/hello/
> license: GPL 3+
> synopsis: Saluton, mondo GNU: ekzemplo de pako GNU
> description: GNU Hello montras la mesaĝon "Hello, world!" kaj finiĝas.  Ĝi funkcias kiel ekzemplo de norma
> + kodumada tradicio de GNU.  Tiel, ĝi subtenas komand-liniajn argumentojn, plurajn lingvojn, kaj tiel plu.

You've passed an absolute path to -L. Indeed, I don't don't see the 
problem when I do that, only when using a relative path. Can you try 
running `guix lint -L t my-hello` while your current working directory is 
/tmp?

> Do you still have this problem?

Yes, confirmed just now with 05f3d34094b23dc9612ff6641a0257bc4f7dcd12

> (Besides, ‘canonicalize-path’ should be used sparsely: it’s quite
> expensive and sometimes confusing for users.  With the proposed patches,
> “-L /does/not/exist” would now lead to an error.)

Perhaps this can be solved a different way. Could we propagate the 
knowledge of the current working directory, and construct absolute path 
when needed?

However, now that you, hopefully, better understand the problem, do we 
want to support relative paths passed to -L? It seems that they happen to 
work some places now, but not others (guix edit is another place where it 
doesn't work). I would be equally happy if we decided to not support 
relative paths, and warn the user when was was provided to -L.

I also think it might make sense for -L /does/not/exist to print a 
(friendly) error rather than silently not loading modules, but I'm open to 
arguments to the contrary.

Best,
Jack

Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Wed, 05 Aug 2020 22:34:02 GMT) Full text and rfc822 format available.

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

From: zimoun <zimon.toutoune <at> gmail.com>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: Jack Hill <jackhill <at> jackhill.us>,
 "42543 <at> debbugs.gnu.org" <42543 <at> debbugs.gnu.org>
Subject: bug#42543: lint failure for packages on load path specified with -L
Date: Thu, 6 Aug 2020 00:33:05 +0200
[Message part 1 (text/plain, inline)]
Hi Ludo,

I confirm the bug and please consider the fix sent in this thread:

http://issues.guix.gnu.org/42543#2

Well, it tweaks using 'canonicalize-path' which is maybe not the right
thing. Let me know.

Cheers,
simon


On Wednesday, 5 August 2020, Ludovic Courtès <ludo <at> gnu.org> wrote:

> Hi,
>
> Jack Hill <jackhill <at> jackhill.us> skribis:
>
> > jackhill <at> alperton ~$ guix lint -L lint-test my-hello
> > Backtrace:y-hello <at> 2.10 [formatting]...
> >            8 (primitive-load "/home/jackhill/.config/guix/current/bi…")
> > In guix/ui.scm:
> >   1974:12  7 (run-guix-command _ . _)
> > In ice-9/boot-9.scm:
> >   1736:10  6 (with-exception-handler _ _ #:unwind? _ # _)
> > In guix/store.scm:
> >    631:22  5 (thunk)
> > In srfi/srfi-1.scm:
> >     634:9  4 (for-each #<procedure 7f40c0484020 at guix/scripts/lin…> …)
> > In guix/scripts/lint.scm:
> >      60:4  3 (run-checkers _ _ #:store _)
> > In srfi/srfi-1.scm:
> >     634:9  2 (for-each #<procedure 7f40b2ab53f0 at guix/scripts/lin…> …)
> >     241:2  1 (for-each _ _)
> > In ice-9/boot-9.scm:
> >   1669:16  0 (raise-exception _ #:continuable? _)
> >
> > ice-9/boot-9.scm:1669:16: In procedure raise-exception:
> > In procedure for-each: Wrong type argument: #f
>
> I can’t reproduce this problem:
>
> --8<---------------cut here---------------start------------->8---
> $ cat /tmp/t/my-hello.scm
> (define-module (my-hello)
>   #:use-module (guix build-system gnu)
>   #:use-module (guix download)
>   #:use-module (guix licenses)
>   #:use-module (guix packages))
>
> (define-public my-hello
>   (package
>     (name "my-hello")
>     (version "2.10")
>     (source (origin
>               (method url-fetch)
>               (uri (string-append "mirror://gnu/hello/hello-" version
>                                   ".tar.gz"))
>               (sha256
>                (base32
>                 "0ssi1wpaf7plaswqqjwigppsg5fyh99vdlb9kzl7c9lng89ndq1i"))))
>     (build-system gnu-build-system)
>     (synopsis "Hello, GNU world: An example GNU package")
>     (description
>      "GNU Hello prints the message \"Hello, world!\" and then exits.  It
> serves as an example of standard GNU coding practices.  As such, it
> supports
> command-line arguments, multiple languages, and so on.")
>     (home-page "https://www.gnu.org/software/hello/")
>     (license gpl3+)))
> $ guix lint -L /tmp/t my-hello
> $ echo $?
> 0
> $ guix show -L /tmp/t my-hello
> name: my-hello
> version: 2.10
> outputs: out
> systems: x86_64-linux i686-linux
> dependencies:
> location: /tmp/t/my-hello.scm:8:2
> homepage: https://www.gnu.org/software/hello/
> license: GPL 3+
> synopsis: Saluton, mondo GNU: ekzemplo de pako GNU
> description: GNU Hello montras la mesaĝon "Hello, world!" kaj finiĝas.  Ĝi
> funkcias kiel ekzemplo de norma
> + kodumada tradicio de GNU.  Tiel, ĝi subtenas komand-liniajn argumentojn,
> plurajn lingvojn, kaj tiel plu.
>
> $ guix describe
> Generacio 152   Aug 04 2020 17:34:23    (nuna)
>   guix abe3c5e
>     repository URL: https://git.savannah.gnu.org/git/guix.git
>     branch: master
>     commit: abe3c5ed7d04985c987e6c81aeb1284354ea0c77
> --8<---------------cut here---------------end--------------->8---
>
> Do you still have this problem?
>
> (Besides, ‘canonicalize-path’ should be used sparsely: it’s quite
> expensive and sometimes confusing for users.  With the proposed patches,
> “-L /does/not/exist” would now lead to an error.)
>
> Thanks,
> Ludo’.
>
>
>
>
[Message part 2 (text/html, inline)]

Reply sent to Ludovic Courtès <ludo <at> gnu.org>:
You have taken responsibility. (Sun, 23 Aug 2020 21:11:01 GMT) Full text and rfc822 format available.

Notification sent to Jack Hill <jackhill <at> jackhill.us>:
bug acknowledged by developer. (Sun, 23 Aug 2020 21:11:02 GMT) Full text and rfc822 format available.

Message #39 received at 42543-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Jack Hill <jackhill <at> jackhill.us>
Cc: 42543-done <at> debbugs.gnu.org
Subject: Re: bug#42543: lint failure for packages on load path specified with
 -L
Date: Sun, 23 Aug 2020 23:10:13 +0200
Hello!

Jack Hill <jackhill <at> jackhill.us> skribis:

>> Jack Hill <jackhill <at> jackhill.us> skribis:
>>
>>> jackhill <at> alperton ~$ guix lint -L lint-test my-hello
>>> Backtrace:y-hello <at> 2.10 [formatting]...
>>>            8 (primitive-load "/home/jackhill/.config/guix/current/bi…")
>>> In guix/ui.scm:
>>>   1974:12  7 (run-guix-command _ . _)
>>> In ice-9/boot-9.scm:
>>>   1736:10  6 (with-exception-handler _ _ #:unwind? _ # _)
>>> In guix/store.scm:
>>>    631:22  5 (thunk)
>>> In srfi/srfi-1.scm:
>>>     634:9  4 (for-each #<procedure 7f40c0484020 at guix/scripts/lin…> …)
>>> In guix/scripts/lint.scm:
>>>      60:4  3 (run-checkers _ _ #:store _)
>>> In srfi/srfi-1.scm:
>>>     634:9  2 (for-each #<procedure 7f40b2ab53f0 at guix/scripts/lin…> …)
>>>     241:2  1 (for-each _ _)
>>> In ice-9/boot-9.scm:
>>>   1669:16  0 (raise-exception _ #:continuable? _)
>>>
>>> ice-9/boot-9.scm:1669:16: In procedure raise-exception:
>>> In procedure for-each: Wrong type argument: #f

[...]

> You've passed an absolute path to -L. Indeed, I don't don't see the
> problem when I do that, only when using a relative path. Can you try
> running `guix lint -L t my-hello` while your current working directory
> is /tmp?

Oops you’re right.  I’ve fixed the root issue with
d10474c38d58bdc676e64336769dc2e00cdfa8ed (avoiding ‘canonicalize-path’).

Thanks,
Ludo’.




Information forwarded to bug-guix <at> gnu.org:
bug#42543; Package guix. (Mon, 24 Aug 2020 20:24:02 GMT) Full text and rfc822 format available.

Message #42 received at 42543-done <at> debbugs.gnu.org (full text, mbox):

From: Jack Hill <jackhill <at> jackhill.us>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 42543-done <at> debbugs.gnu.org
Subject: Re: bug#42543: lint failure for packages on load path specified with
 -L
Date: Mon, 24 Aug 2020 16:23:44 -0400 (EDT)
[Message part 1 (text/plain, inline)]
On Sun, 23 Aug 2020, Ludovic Courtès wrote:

> I’ve fixed the root issue with d10474c38d58bdc676e64336769dc2e00cdfa8ed 
> (avoiding ‘canonicalize-path’).

Awesome, thank you!

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 22 Sep 2020 11:24:08 GMT) Full text and rfc822 format available.

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

Previous Next


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