unofficial mirror of guix-science@gnu.org 
 help / color / mirror / Atom feed
From: Peter Polidoro <peter@polidoro.io>
To: guix-science@gnu.org
Subject: Reproducible Project Environments
Date: Mon, 06 Dec 2021 09:18:28 -0500	[thread overview]
Message-ID: <86lf0x3f9c.fsf@polidoro.io> (raw)

Guix is a wonderful way to distribute software, especially for 
science. Thank you all for such a fantastic project and community!

I am an engineer working with scientists at the Howard Hughes 
Medical Institute, a science philanthropy based in the United 
States funding researchers all over the world. I hope to help 
convince the researchers I work with to all use Guix someday.

My question is, what files do you recommend placing within a 
project directory to make it as straightforward as possible to 
distribute that project to others to develop and use in a 
reproducible environment?

If all of the project dependencies are in Guix as packages, then a 
guix.scm or manifest.scm file seems all that is needed to create a 
reproducible environment using guix shell, as long as someone has 
Guix installed on their machine.

What do you recommend when some of the project dependencies are 
not yet Guix packages? Obviously it would be best to get those 
dependencies into Guix as official packages eventually, but what 
is the best way to handle those dependencies until then?

Say that in addition to some Guix packages, the project also needs 
some Python packages that are available on pypi, but are not yet 
Guix packages. Using something like direnv, an .envrc file in the 
project directory can install the Guix package dependencies into a 
local profile, then pip install the Python dependencies into a 
project local virtualenv. Then the user just needs Guix and direnv 
installed on their machine to get a reproducible environment when 
they change into that directory. Specifying dependencies in an 
.envrc file does not seem as elegant as using a pure Guix 
solution, however.

What is the best way to handle these dependencies without using 
direnv and just Guix? Should I create Guix packages for the Python 
dependencies in an external custom channel? If so, how do you 
specify custom channels when using guix shell? Is there a method 
that is as simple as direnv or does it involve a user separately 
setting up a new profile to reference the custom channel before 
running guix shell?

Do you ever create packages within a guix.scm file or a 
manifest.scm file or perhaps in a separate channel.scm file in the 
project directory to keep the project more self contained than 
referencing an external custom channel? Then would you create some 
project local profile that references this file to use when 
running guix shell? Or is the recommended approach to always use a 
custom channel before submitting the packages to be included into 
Guix proper? Thanks!



             reply	other threads:[~2021-12-06 16:08 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-06 14:18 Peter Polidoro [this message]
2021-12-06 16:16 ` Reproducible Project Environments Julien Lepiller
2021-12-06 18:09   ` Peter Polidoro
2021-12-06 19:52     ` Efraim Flashner
2021-12-06 16:58 ` zimoun
2021-12-06 18:13   ` Peter Polidoro
2021-12-08 14:30   ` Peter Polidoro
2021-12-09 20:33     ` Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86lf0x3f9c.fsf@polidoro.io \
    --to=peter@polidoro.io \
    --cc=guix-science@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).