Hi,

zimoun <zimon.touto...@gmail.com> skribis:

> On Thu, 30 Jun 2022 at 10:58, Hartmut Goebel <h.goe...@crazy-compilers.com> 
> wrote:
>
>> BTW 2: Which updater is used for each package is non-deterministic.
>
> From (guix discovery), ’all-modules’ is not deterministic because it
> depends on how the filesystem tree is walked.

Nope!  ‘all-modules’ *is* deterministic because it builds upon
‘scheme-files’, which is deterministic and documented as such.

> Maybe sorting ’%updaters’ would be enough; something like,
>
> (define %updaters
>   ;; The list of publically-known updaters.
>   (delay (sort (fold-module-public-variables (lambda (obj result)

Whether ‘fold-module-public-variables’ is deterministic depends on
whether ‘module-map’ is deterministic, which in turn depends on
‘hash-map->list’, which is not deterministic AFAICS.

So what we could do is replace uses of ‘module-map’ with a variant that
sorts variables.

That said, the only case where it can influence updater order is when
several of them are defined in the same module.

Thoughts?

Ludo’.

Reply via email to