From: Phil Beadling <phil@beadling.co.uk>
To: help-guix <help-guix@gnu.org>
Subject: Inconsistencies in Package Transformation?
Date: Tue, 18 May 2021 22:01:49 +0100 [thread overview]
Message-ID: <CAOvsyQsiGy1uGjMbd2aZ83dfG_tVm0DUWnzV2Cqsv3iO5FPDzQ@mail.gmail.com> (raw)
Hi all,
I've read through this link:
https://guix.gnu.org/manual/en/html_node/Package-Transformation-Options.html
But I seem to get unexpected outcomes in some examples - see below.
Any advice or confirmation that this is a bug or misuse by me?
Thanks,
Phil.
A simple case of package transformation without any dependencies seems to
work fine - for example, let's upgrade pandas to v1.1.5:
*$ guix package -i python-pandas python -p ~/profiles/pandas-1.1.5
--with-git-url=python-pandas=https://github.com/pandas-dev/pandas.git
<https://github.com/pandas-dev/pandas.git>
--with-commit=python-pandas=v1.1.5 --without-tests=python-pandasThe
following packages will be installed: python 3.8.2 python-pandas
1.1.5updating checkout of 'https://github.com/pandas-dev/pandas.git'.
<https://github.com/pandas-dev/pandas.git'.>..retrieved commit
af3e67970ff8e9e3eccfef54c8de96f850e36912The following derivation will be
built: /gnu/store/cd045q1l75wx59d62f1b8sb6p92yjf4d-profile.drvbuilding CA
certificate bundle...listing Emacs sub-directories...building fonts
directory...building directory of Info manuals...building database for
manual pages...building profile with 2 packages...hint: Consider setting
the necessary environment variables by running:
GUIX_PROFILE="/home/phil/profiles/pandas-1.1.5" .
"$GUIX_PROFILE/etc/profile"Alternately, see `guix package --search-paths -p
"/home/phil/profiles/pandas-1.1.5"'.$
GUIX_PROFILE="/home/phil/profiles/pandas-1.1.5"$ .
"$GUIX_PROFILE/etc/profile"$ python3Python 3.8.2 (default, Jan 1 1970,
00:00:01)[GCC 7.5.0] on linuxType "help", "copyright", "credits" or
"license" for more information.>>> import pandas as pd>>>
pd.__version__'0+unknown'>>>*
The right commit is taken from github, and after the build we use the
profile to access our new version of pandas (the 0+unknown version I think
is caused by building from git).
Next, I try exactly the same transformation, but I want to instead build
one of my own applications which has python-pandas as propagated input. My
understanding from the docs is this should work find as a deep
transformation should occur?
*$ guix package -i foo python -p ~/profiles/foo-pandas-1.1.5
--with-git-url=python-pandas=https://github.com/pandas-dev/pandas.git
<https://github.com/pandas-dev/pandas.git>
--with-commit=python-pandas=v1.1.5 --without-tests=python-pandas
--without-tests=python-dask --without-tests=fooThe following packages will
be installed: python 3.8.2 foo 3.196.0updating checkout of
'ssh://git@bitbucket:7999/foo/foo.git'...retrieved commit
a723e52bec22ca36bbfda62f34a1f46e0065b7eaupdating checkout of
'https://github.com/pandas-dev/pandas.git'.
<https://github.com/pandas-dev/pandas.git'.>..retrieved commit
af3e67970ff8e9e3eccfef54c8de96f850e36912hint: Consider setting the
necessary environment variables by running:
GUIX_PROFILE="/home/phil/profiles/simm-pandas-1.1.5" .
"$GUIX_PROFILE/etc/profile"Alternately, see `guix package --search-paths -p
"/home/phil/profiles/simm-pandas-1.1.5"'.$
GUIX_PROFILE="/home/phil/profiles/simm-pandas-1.1.5"$ .
"$GUIX_PROFILE/etc/profile"$ python3Python 3.8.2 (default, Jan 1 1970,
00:00:01)[GCC 7.5.0] on linuxType "help", "copyright", "credits" or
"license" for more information.>>> import pandas as pd>>>
pd.__version__'1.1.2'>>>*
Everything looks to be going to plan, but when I import pandas using the
new profile I get version *1.1.2* - which is my standard untransformed
python-pandas package - no replacement has taken place, despite the process
reporting the correct location and commit id for the pandas checkout.
This either looks like a) a bug, or b) I've misunderstood the scope of the
transformation syntax.
One last detail - my own definiton of python-pandas v1.1.2 inherits from
the gnu package in Guix. Whilst I inherit the name python-pandas the
actual package is called python-pandas-foo, and it is referenced in foo's
package's propagated inputs like this:
*("python-pandas" ,python-pandas-foo)*
Package definition snippet:
*(define-public python-pandas-foo (package (inherit python-pandas)
(version "1.1.2") (source (origin (method url-fetch)
(uri (pypi-uri "pandas" version)) (sha256 (base32
"0i0lbp26kzbq1qa4rv2s2r42m9d95svjrfflmi01plygla3zskxn")))) .... and so on*
I don't think this last detail should matter, but I include is as the only
other significant detail that may differ from other systems.
next reply other threads:[~2021-05-18 21:02 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-18 21:01 Phil Beadling [this message]
2021-05-18 21:30 ` Inconsistencies in Package Transformation? Julien Lepiller
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=CAOvsyQsiGy1uGjMbd2aZ83dfG_tVm0DUWnzV2Cqsv3iO5FPDzQ@mail.gmail.com \
--to=phil@beadling.co.uk \
--cc=help-guix@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).