Subject: bug#64302: Guix derivation cannot be computed during pull

From: Andreas Enge <[email-masked]>
Date: Mon, 26 Jun 2023 17:15:00 +0200

Hello,

here is what happens on a server I do not manage to update for about a year now:

$ guix pull
Updating channel 'guix' from Git repository at 'https://git.savannah.gnu.org/git/guix.git'...
Authenticating channel 'guix', commits 9edb3f6 to 1bc878d (1,055 new commits)...
Building from this channel:
  guix      https://git.savannah.gnu.org/git/guix.git	1bc878d
substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0%
substitute: updating substitutes from 'https://bordeaux.guix.gnu.org'... 100.0%
substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0%
substitute: updating substitutes from 'https://bordeaux.guix.gnu.org'... 100.0%
substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0%
substitute: updating substitutes from 'https://bordeaux.guix.gnu.org'... 100.0%
building /gnu/store/a2zzynwqii5j84gg9zn2brkh0hiqrh6n-module-import.drv...
building /gnu/store/s8bj7c9nd85ng871h4440w7jw6p0hxpq-module-import.drv...
building /gnu/store/3m2pndmnxj91s80ad1kvjw7kjsgpf733-module-import-compiled.drv...
building /gnu/store/fg3r0s0r1sbljjdvgsnjkkziskn3fagp-module-import-compiled.drv...
building /gnu/store/a2lgmyr95d3nr0snp31662rygf5g7cz7-compute-guix-derivation.drv...
Computing Guix derivation for 'x86_64-linux'... /guix pull: error: You found a bug: the program '/gnu/store/wvni7k3g4wnf0k782zgfv4gya9bnw8gg-compute-guix-derivation'
failed to compute the derivation for Guix (version: "1bc878ded2ea349384da6a72d4b8326c63c794b4"; system: "x86_64-linux";
host version: "35b176daf1a466f136f0b77c03de78f482a30702"; pull-version: 1).
Please report the COMPLETE output above by email to <[email-masked]>.

Here is the content of the compute-guix-derivation script:
#!/gnu/store/1kws5vkl0glvpxg7arabsv6q9vazp0hx-guile-3.0.7/bin/guile --no-auto-compile
!#
(eval-when (expand load eval) (set! %load-path (cons "/gnu/store/ic6dz76n6kax93q32b3356dvpl19iv5w-module-import" %load-path)) (set! %load-compiled-path (cons "/gnu/store/hkmx7wwwzdycj5q76j08ffn479vmvdax-module-import-compiled" %load-compiled-path)))(begin (use-modules (ice-9 match)) (eval-when (expand load eval) (match (command-line) ((_ source _ ...) (match %load-path ((front _ ...) (unless (string=? front source) (set! %load-path (list source (string-append "/gnu/store/60jl4xry9c93j9l0rr7nkvbw7dihjz4k-guile-gcrypt-0.3.0" "/share/guile/site/" (effective-version)) front))))))) (set! %load-compiled-path (cons (string-append "/gnu/store/60jl4xry9c93j9l0rr7nkvbw7dihjz4k-guile-gcrypt-0.3.0" "/lib/guile/" (effective-version) "/site-ccache") %load-compiled-path)) (read-disable (quote positions))) (use-modules (guix store) (guix self) (guix derivations) (srfi srfi-1)) (match (command-line) ((_ source system version protocol-version build-output) (let* ((proto (string->number protocol-version)) (store (if (integer? proto) (port->connection (duplicate-port (current-input-port) "w+0") #:version proto) (open-connection))) (sock (socket AF_UNIX SOCK_STREAM 0))) (connect sock AF_UNIX build-output) (display (and=> (parameterize ((current-warning-port (%make-void-port "w")) (current-build-output-port sock)) (run-with-store store (guix-derivation source version "3.0" #:channel-metadata (quote (repository (version 0) (url "https://git.savannah.gnu.org/git/guix.git") (branch "master") (commit "1bc878ded2ea349384da6a72d4b8326c63c794b4") (name guix) (introduction (channel-introduction (version 0) (commit "9edb3f66fd807b096b48283debdcddccfea34bad") (signer "BBB0 2DDF 2CEA F6A8 0D1D  E643 A2A0 6DF2 A33A 54FA"))))) #:pull-version 1) #:system system)) derivation-file-name))))))

If I remember well, in the past I tried to update with a guix from guix
(obtained with "guix install guix") and also with one from git
("./pre-inst-env guix pull"), and the result was always the same.

So here is the sad outdated state:
$ guix describe
Generation 10	Aug 26 2022 15:29:35	(current)
  guix 35b176d
    repository URL: https://git.savannah.gnu.org/git/guix.git
    branch: master
    commit: 35b176daf1a466f136f0b77c03de78f482a30702

Andreas