unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
* Replication question
@ 2024-04-16 16:26 Mauritz Stenek
  2024-04-16 16:41 ` Felix Lechner via
  2024-04-16 17:47 ` Richard Sent
  0 siblings, 2 replies; 4+ messages in thread
From: Mauritz Stenek @ 2024-04-16 16:26 UTC (permalink / raw)
  To: help-guix

Hi all,

Suppose you have these packages in your environment:

    A@old
    B
    C

where `A` is pinned to the `old` version, which is not in the 
latest channel versions -- as per `guix describe`; the latest 
versions of both `B` and `C`, however, are in the latest channel 
versions but *not* in the channel versions where `A@old` is 
defined.

How, then, is this environment replicable without some hacky 
gymnasitcs?

What am I missing?

-- 
Mauritz Stenek <mstenek@disroot.org>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Replication question
  2024-04-16 16:26 Replication question Mauritz Stenek
@ 2024-04-16 16:41 ` Felix Lechner via
  2024-04-16 17:47 ` Richard Sent
  1 sibling, 0 replies; 4+ messages in thread
From: Felix Lechner via @ 2024-04-16 16:41 UTC (permalink / raw)
  To: Mauritz Stenek, help-guix

Hi Mauritz,

On Tue, Apr 16 2024, Mauritz Stenek wrote:

> How, then, is this environment replicable [...] ?

Soon after switching to Guix System, I also adopted Guix Home.  Together
both more or less ensure a reproducible enviroment.  In your use case, I
believe only the packages are reproducible (such as the executables) but
not the entire environment.

As a Guix noobie, I don't understand all of the intricacies so it would
be prudent to wait for other answers before you draw conclusions.

Thanks for using GNU Guix!

Kind regards
Felix


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Replication question
  2024-04-16 16:26 Replication question Mauritz Stenek
  2024-04-16 16:41 ` Felix Lechner via
@ 2024-04-16 17:47 ` Richard Sent
  2024-04-17 16:08   ` pelzflorian (Florian Pelz)
  1 sibling, 1 reply; 4+ messages in thread
From: Richard Sent @ 2024-04-16 17:47 UTC (permalink / raw)
  To: Mauritz Stenek; +Cc: help-guix

Hi Mauritz

Mauritz Stenek <mstenek@disroot.org> writes:

> Suppose you have these packages in your environment:
>
>    A@old
>    B
>    C
>
> where `A` is pinned to the `old` version, which is not in the latest
> channel versions -- as per `guix describe`; the latest versions of
> both `B` and `C`, however, are in the latest channel versions but
> *not* in the channel versions where `A@old` is defined.
>
> How, then, is this environment replicable without some hacky
> gymnasitcs?
>
> What am I missing?

Your hunch is corect. Without knowing the Guix commit that the
environment/profile was built with, you would not be able to reproduce
the profile exactly.

There's two options I know of:

1. Guix time-machine. e.g.
guix time-machine --commit=XXX -- package -m manifest.scm

     a. This will create a profile containing the exact packages at that
     moment in time, including A@old.

     b. All packages will be at whatever version the corresponding
     Scheme package variable is at for that commit. See (info "(guix)
     Invoking guix time-machine"). Probably not the best idea to use
     long term.

2. Inferiors. This provides a mechanism for mixing and matching A@old
from commit XXX with packages B and C from commit YYY. See (info "(guix)
Inferiors").

    a. To my knowledge this won't replace dependencies for B or C if
    they depend on A@old. B and C would use the "primary" channel's A.
    You probably could modify B and C to replace A with A@old though.

As you saw, A@old doesn't have any fancy logic for "go back to the most
recent Guix commit that has A@old". It's just a convenient way to
specify which version of package A to install when multiple are
packaged.

-- 
Take it easy,
Richard Sent
Making my computer weirder one commit at a time.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Replication question
  2024-04-16 17:47 ` Richard Sent
@ 2024-04-17 16:08   ` pelzflorian (Florian Pelz)
  0 siblings, 0 replies; 4+ messages in thread
From: pelzflorian (Florian Pelz) @ 2024-04-17 16:08 UTC (permalink / raw)
  To: Richard Sent; +Cc: Mauritz Stenek, help-guix

Hello Richard; yours is a good answer.  Let me add:

Richard Sent <richard@freakingpenguin.com> writes:
> 1. Guix time-machine. e.g.
> guix time-machine --commit=XXX -- package -m manifest.scm
>
>      a. This will create a profile containing the exact packages at that
>      moment in time, including A@old.
>
>      b. All packages will be at whatever version the corresponding
>      Scheme package variable is at for that commit. See (info "(guix)
>      Invoking guix time-machine"). Probably not the best idea to use
>      long term.

Note that “guix time-machine … -- install” or “guix time-machine … --
build” can be used for individual packages.  So repeated time-machine to
each package’s commit can reproduce the environment (have not tested it,
but should be true).

guix time-machine can also take a channel description file instead
of a commit, if we are talking about other channels.

Also to comment on Mauritz’ question, the @ syntax of guile@2.2.7 has
nothing to do with reproducibility.  Everybody understood correctly that
by A@old, A from an old Guix commit was your intended meaning; I want to
clarify this for future readers.

Regards,
Florian



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-04-17 16:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-16 16:26 Replication question Mauritz Stenek
2024-04-16 16:41 ` Felix Lechner via
2024-04-16 17:47 ` Richard Sent
2024-04-17 16:08   ` pelzflorian (Florian Pelz)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).