GNU bug report logs - #45615
Wrong type argument in "guix lint -c archival"

Previous Next

Package: guix;

Reported by: Hartmut Goebel <h.goebel <at> crazy-compilers.com>

Date: Sat, 2 Jan 2021 22:15:01 UTC

Severity: normal

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: Ludovic Courtès <ludo <at> gnu.org>
To: zimoun <zimon.toutoune <at> gmail.com>
Cc: 45615 <at> debbugs.gnu.org, Hartmut Goebel <h.goebel <at> crazy-compilers.com>
Subject: bug#45615: SWH API break?
Date: Mon, 11 Jan 2021 16:16:41 +0100
Hi,

zimoun <zimon.toutoune <at> gmail.com> skribis:

> Well, maybe I miss something.  The JSON looks like:
>
> https://archive.softwareheritage.org/api/1/origin/https://github.com/Genivia/ugrep/get/
>
> as we already discussed [1] the other day.  From my understanding, when
> the field does not exist, before guile-json sets to #f and now it sets
> to #<unspecified>; I guess that it is related to the NEWS entry:
>
>   - Record-JSON mapping now allows using *unspecified* values to indicate a
>     field record should not be serialized.
>     (Fixes #61)
>
>
> and the behaviour change is described here:
>
> Unspecified fields will now have the value *unspecified*. You mention
> that json->link-record would assign a #f but that's not actually
> correct, since a field could be a boolean in which case there would not
> be a way to identify it. 
>
> <https://github.com/aconchillo/guile-json/issues/61#issuecomment-703212590>
>
>
> I am not familiar enough with Guile-JSON to see how to fix.  Any tips?

Thanks for investigating!  Looking more closely, I think the issue is
related to this change, but to me it’s a bug: it’s now impossible to set
a field to #f.  Reported at
<https://github.com/aconchillo/guile-json/issues/69>.

Unfortunately, I can’t think of a way to work around it since it’s
pretty fundamental.

At any rate, we should add a test that exercises this in ‘tests/swh.scm’
so we don’t get caught by surprise next time.

Thanks,
Ludo’.




This bug report was last modified 4 years and 182 days ago.

Previous Next


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