GNU bug report logs - #31974
If a phase returns #f, a warning is issued, but the build continues

Previous Next

Package: guix;

Reported by: Mark H Weaver <mhw <at> netris.org>

Date: Tue, 26 Jun 2018 03:15:01 UTC

Severity: important

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

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#31974: closed (If a phase returns #f, a warning is issued,
 but the build continues)
Date: Wed, 09 Jan 2019 20:39:03 +0000
[Message part 1 (text/plain, inline)]
Your message dated Wed, 09 Jan 2019 21:38:25 +0100
with message-id <87a7k936ta.fsf <at> gnu.org>
and subject line Re: bug#31974: If a phase returns #f, a warning is issued, but the build continues
has caused the debbugs.gnu.org bug report #31974,
regarding If a phase returns #f, a warning is issued, but the build continues
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
31974: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=31974
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Mark H Weaver <mhw <at> netris.org>
To: bug-guix <at> gnu.org
Subject: If a phase returns #f, a warning is issued, but the build continues
Date: Mon, 25 Jun 2018 23:13:03 -0400
I just noticed that I made a mistake in commit
d8a3b1b9e847d4a44d2695f95af77170d4d2788f, which changed 'gnu-build' in
(guix build gnu-build-system) to issue a warning if a phase returns a
value other than #t.

The result is that if a phase returns a value other than #t, a warning
is issued, but the build nonetheless continues to the next phase, and
the build could ultimately "succeed" even some phases returned #f.

In other words, the return values of phases are effectively ignored,
except for the warning, so the only way to cause a build with phases to
fail is to raise an exception.

We can't fix this problem without a full rebuild.  Sorry about that :-(

The only good news here is that I've already fixed all of the core
packages to return #t from all phases and to report errors using
exceptions.  Ditto for all of the packages that I use on my GNOME
desktop.  The remaining packages that might return #f from a phase could
be fixed in 'master'.

      Mark


[Message part 3 (message/rfc822, inline)]
From: Ludovic Courtès <ludo <at> gnu.org>
To: Mark H Weaver <mhw <at> netris.org>
Cc: 31974-done <at> debbugs.gnu.org
Subject: Re: bug#31974: If a phase returns #f, a warning is issued,
 but the build continues
Date: Wed, 09 Jan 2019 21:38:25 +0100
Mark H Weaver <mhw <at> netris.org> skribis:

> I just noticed that I made a mistake in commit
> d8a3b1b9e847d4a44d2695f95af77170d4d2788f, which changed 'gnu-build' in
> (guix build gnu-build-system) to issue a warning if a phase returns a
> value other than #t.
>
> The result is that if a phase returns a value other than #t, a warning
> is issued, but the build nonetheless continues to the next phase, and
> the build could ultimately "succeed" even some phases returned #f.

This was fixed in commit 82230603ce06de7aa3e4aef2fa093a6dbf0ef8df.
Closing!

Ludo'.


This bug report was last modified 6 years and 184 days ago.

Previous Next


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