Subject: Re: [PATCH v5 07/45] guix: node-build-system: Add #:absent-dependencies argument.

From: Liliana Marie Prikler <[email-masked]>
Date: Tue, 21 Dec 2021 21:44:37 +0100

Hi,

Am Dienstag, dem 21.12.2021 um 13:25 -0500 schrieb Philip McGrath:
> Here are, to the best of my understanding, the differences in 
> representation among (guix build json) and the three versions of 
> guile-json packaged in Guix. (For guile-json, this is based on my 
> relatively-quick reading of the docs, not any direct experience.) An 
> extra complication is that some part of Guix's code staging seems to 
> incorrectly turn #nil into '(). I will see if I can narrow that down
> and file a bug report.
> 
> (guix build json):
>    • object -> (Pairof '@ (Listof (Pairof String Json)))
>    • array  -> (Listof Json)
>    • null   -> #nil
>    • string -> String
> 
> guile-json-4:
>    • object -> (Listof (Pairof (U Symbol Number String) Json))
>    • array  -> (Vectorof Json)
>    • null   -> 'null ;; configurable by keyword argument
>    • string -> (U Symbol String)
> 
> guile-json-3:
>    • object -> (Listof (Pairof (U Symbol Number String) Json))
>    • array  -> (Vectorof Json)
>    • null   -> #nil
>    • string -> (U Symbol String)
#nil to '() conversions are probably the fault of some syntax-case or
match expression.  That being said, I hope we don't have to worry about
code staging too much as comparison ought to be done using null? imo.

I think the main difference between (guix build json) and guile-json
here are the extended keys in the latter (guix only has strings) and
the vector/object distinction.  I think it'd be rather straight-forward
to write upgrade guidelines in case we ever make the switch. 
Similarly, all rules based on pattern-matching *will break*, forcing us
to upgrade all the recipes with it.  WDYT?  Would that be manageable
(assuming the change to require Guile-JSON would already be core-
updates material)?