Subject: bug#44402: `guix pull` crashes on current master

From: Leo Famulari <[email-masked]>
Date: Mon, 2 Nov 2020 17:38:29 -0500

As reported by mroh on #guix, building the current master branch crashes
`guix pull`:

------
building /gnu/store/73f1lk43y71byz6zic4ac397s751d50c-guix-cli.drv...
[  8/110] loading...	 14.5% of 55 filesBacktrace:
In ice-9/boot-9.scm:
   222:29 19 (map1 (((gnu packages less)) ((gnu packages linux)) ((gnu packages man)) ((gnu packages nano)) ((gnu packages nvi)) ((gnu packages package-management)) ((gnu packages pciutils)) (#) ?))
   222:29 18 (map1 (((gnu packages linux)) ((gnu packages man)) ((gnu packages nano)) ((gnu packages nvi)) ((gnu packages package-management)) ((gnu packages pciutils)) ((gnu packages texinfo)) # ?))
   222:29 17 (map1 (((gnu packages man)) ((gnu packages nano)) ((gnu packages nvi)) ((gnu packages package-management)) ((gnu packages pciutils)) ((gnu packages texinfo)) ((gnu packages zile)) # ?))
   222:29 16 (map1 (((gnu packages nano)) ((gnu packages nvi)) ((gnu packages package-management)) ((gnu packages pciutils)) ((gnu packages texinfo)) ((gnu packages zile)) ((gnu services)) ((?)) ?))
   222:29 15 (map1 (((gnu packages nvi)) ((gnu packages package-management)) ((gnu packages pciutils)) ((gnu packages texinfo)) ((gnu packages zile)) ((gnu services)) ((gnu services shepherd)) # ?))
   222:29 14 (map1 (((gnu packages package-management)) ((gnu packages pciutils)) ((gnu packages texinfo)) ((gnu packages zile)) ((gnu services)) ((gnu services shepherd)) ((gnu services base)) # ?))
   222:29 13 (map1 (((gnu packages pciutils)) ((gnu packages texinfo)) ((gnu packages zile)) ((gnu services)) ((gnu services shepherd)) ((gnu services base)) ((gnu bootloader)) ((gnu system #)) # ?))
   222:29 12 (map1 (((gnu packages texinfo)) ((gnu packages zile)) ((gnu services)) ((gnu services shepherd)) ((gnu services base)) ((gnu bootloader)) ((gnu system shadow)) ((gnu system nss)) (#) ?))
   222:29 11 (map1 (((gnu packages zile)) ((gnu services)) ((gnu services shepherd)) ((gnu services base)) ((gnu bootloader)) ((gnu system shadow)) ((gnu system nss)) ((gnu system locale)) ((?)) ?))
   222:29 10 (map1 (((gnu services)) ((gnu services shepherd)) ((gnu services base)) ((gnu bootloader)) ((gnu system shadow)) ((gnu system nss)) ((gnu system locale)) ((gnu system pam)) ((gnu ?)) ?))
   222:17  9 (map1 (((gnu services shepherd)) ((gnu services base)) ((gnu bootloader)) ((gnu system shadow)) ((gnu system nss)) ((gnu system locale)) ((gnu system pam)) ((gnu system #)) ((gnu ?)) ?))
  3297:17  8 (resolve-interface (gnu services shepherd) #:select _ #:hide _ #:prefix _ #:renamer _ #:version _)
In ice-9/threads.scm:
    390:8  7 (_ _)
In ice-9/boot-9.scm:
  3223:13  6 (_)
In ice-9/threads.scm:
    390:8  5 (_ _)
In ice-9/boot-9.scm:
  3507:20  4 (_)
   2806:4  3 (save-module-excursion #<procedure 7ffff2527d80 at ice-9/boot-9.scm:3508:21 ()>)
  3527:26  2 (_)
In unknown file:
           1 (primitive-load-path "gnu/services/shepherd" #<procedure 7ffff1cc3500 at ice-9/boot-9.scm:3514:37 ()>)
In gnu/services/shepherd.scm:
   107:21  0 (_)

gnu/services/shepherd.scm:107:21: In procedure allocate-struct: Wrong type argument in position 1 (expecting struct): #<procedure %service-extension?-procedure (obj)>
note: keeping build directory `/tmp/guix-build-guix-cli.drv-0'
builder for `/gnu/store/73f1lk43y71byz6zic4ac397s751d50c-guix-cli.drv' failed with exit code 1
build of /gnu/store/73f1lk43y71byz6zic4ac397s751d50c-guix-cli.drv failed
View build log at '/var/log/guix/drvs/73/f1lk43y71byz6zic4ac397s751d50c-guix-cli.drv.bz2'.
cannot build derivation `/gnu/store/bbhcka85bgbjxdi47myz5xf0nrb2qygl-guix-cli-modules.drv': 1 dependencies couldn't be built
cannot build derivation `/gnu/store/z6fa0smqmsqnpzsdafncryza40h79yrj-guix-system-tests.drv': 1 dependencies couldn't be built
cannot build derivation `/gnu/store/hnfp4fvbnyaw3flqsmsw896iwmy8yds1-guix-dfed0eca9-modules.drv': 1 dependencies couldn't be built
cannot build derivation `/gnu/store/fgsx7x6dfs0l13i6ka4c70q0hpk2cv7f-guix-dfed0eca9.drv': 1 dependencies couldn't be built
cannot build derivation `/gnu/store/m6ls1fg02fx235x3vkiss18k2ys3jkjw-profile.drv': 1 dependencies couldn't be built
guix pull: error: build of `/gnu/store/m6ls1fg02fx235x3vkiss18k2ys3jkjw-profile.drv' failed
------

I've confirmed that commit b5f2a035f93519b27f46673e6d76665767a1fbd9
works, and I'm testing later commits now.