Subject: bug#23836: bae0636 bournish: Add 'wc' command. make check FAIL: 9

From: [email-masked] (Ludovic Courtès)
Date: Fri, 24 Jun 2016 14:30:24 +0200

Hello,

myglc2 <[email-masked]> skribis:

> Running Guix on Debian 8.3 from git bae0636 bournish: Add 'wc' command.

> test-name: query narinfo without signature
> location: /home/g1/dev/guix/tests/substitute.scm:173
> source:
> + (test-equal
> +   "query narinfo without signature"
> +   ""
> +   (with-narinfo
> +     %narinfo
> +     (string-trim-both
> +       (with-output-to-string
> +         (lambda ()
> +           (with-input-from-string
> +             (string-append
> +               "have "
> +               (%store-prefix)
> +               "/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa-foo")
> +             (lambda () (guix-substitute "--query"))))))))
> expected-value: 
> actual-value: #f
> actual-error:
> + (system-error
> +   "lstat"
> +   "~A: ~S"
> +   ("No such file or directory"
> +    "/home/g1/dev/guix/test-tmp/var/24621/cache-24621/guix/substitute/")
> +   (2))
> result: FAIL

This is fishy.  Could it be that files in this directory were being
accessed or removed concurrently?

Could you retry these tests with:

  make check TESTS=tests/substitute.scm

?

> test-name: container-excursion
> location: /home/g1/dev/guix/tests/containers.scm:100
> source:
> + (test-assert
> +   "container-excursion"
> +   (call-with-temporary-directory
> +     (lambda (root)
> +       (match (list (pipe) (pipe))
> +              (((start-in . start-out) (end-in . end-out))
> +               (define (container)
> +                 (close end-out)
> +                 (close start-in)
> +                 (write 'ready start-out)
> +                 (close start-out)
> +                 (read end-in)
> +                 (close end-in))
> +               (define (namespaces pid)
> +                 (let ((pid (number->string pid)))
> +                   (map (lambda (ns)
> +                          (readlink (string-append "/proc/" pid "/ns/" ns)))
> +                        '("user" "ipc" "uts" "net" "pid" "mnt"))))
> +               (let* ((pid (run-container root '() %namespaces 1 container))
> +                      (container-namespaces (namespaces pid))
> +                      (result
> +                        (begin
> +                          (close start-out)
> +                          (read start-in)
> +                          (close start-in)
> +                          (container-excursion
> +                            pid
> +                            (lambda ()
> +                              (match (primitive-fork)
> +                                     (0
> +                                      (assert-exit
> +                                        (equal?
> +                                          container-namespaces
> +                                          (namespaces (getpid)))))
> +                                     (fork-pid
> +                                       (match (waitpid fork-pid)
> +                                              ((_ . status)
> +                                               (primitive-exit
> +                                                 (status:exit-val
> +                                                   status)))))))))))
> +                 (close end-in)
> +                 (write 'done end-out)
> +                 (close end-out)
> +                 (waitpid pid)
> +                 (zero? result)))))))
> actual-value: #f
> actual-error:
> + (system-error
> +   "clone"
> +   "~d: ~A"
> +   (2080505873 "Operation not permitted")
> +   (1))
> result: FAIL

You can ignore this one: the previous tests were skipped due to lack of
support for user namespaces on this system, and this one should have
been fixed too (I’ll update tests/containers.scm so that it really skips
it.)

Thanks for your report!

Ludo’.