Subject: Re: bug#28144: info-dir ERROR: no code for module (guix build utils)

From: Christopher Baines <[email-masked]>
Date: Tue, 22 Aug 2017 10:59:58 +0100

On Tue, 22 Aug 2017 10:41:55 +0200
[email-masked] (Ludovic Courtès) wrote:

> Heya,
> 
> Christopher Baines <[email-masked]> skribis:
> 
> > I've had the following issue a few times now, it seems that somehow,
> > the info-dir builder can be incorrectly generated, without the usual
> > module import stuff.
> >
> > The most recent time this occurred, I worked around this by finding
> > the guix package in the store which I thought was being used at the
> > time, and explicitly garbage collected it (guix gc -d ...). I then
> > rebuilt it, and this seemed to work around the problem. I was using
> > the same guix package, pinned to an revision in a git repository.
> >
> >
> > The builder starts with:
> >
> >   (begin (use-modules (guix build utils)
> >
> >
> > This is the error which you get:
> >
> > The following derivations will be built:
> >    /gnu/store/8qi10kwz4ghabdj5p7s252z11snvhhgf-profile.drv
> >    /gnu/store/0jxiph2hvmvakcj6gkz9d00a8ncma903-info-dir.drv  
> 
> Could you check if the .drv has the right -L and -C flags for guile?
> 
> What commit was this on?
> 
> Looking at (guix profiles), what you describe Cannot Happen™ because
> there’s a correct ‘with-imported-modules’ form there.

I've included the derivation contents below, I can't see the -L and -C
flags, so I'm guessing that they are missing.

As for what commit this is on, this particular occurance took place
when I was using my odd guix-pre-inst-env [1] script that
attempts to create an environment containing a particular version of
Guix, without letting anything from the surrounding environment creep
in, so I'm not really sure what code was in use at the time.

1: https://github.com/alphagov/govuk-guix/blob/master/guix-pre-inst-env