unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#52906: python-biopython conflicts with python-numpy
@ 2021-12-30 21:13 zimoun
  2021-12-30 23:55 ` Leo Famulari
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: zimoun @ 2021-12-30 21:13 UTC (permalink / raw)
  To: 52906; +Cc: Ricardo Wurmus

[-- Attachment #1: Type: text/plain, Size: 1979 bytes --]

Hi,

Using 7022eb6, the package ’python-biopython’ propagates
’python-numpy’, i.e., python-numpy@1.20.3.

However, because Guix installs by default the last version and:

--8<---------------cut here---------------start------------->8---
$ guix package -A | grep 'python-numpy ' | cut -f1,2
python-numpy        	1.21.3              
python-numpy        	1.20.3              
--8<---------------cut here---------------end--------------->8---

then this manifests.scm leads to an error,

--8<---------------cut here---------------start------------->8---
$ cat /tmp/manifest.scm
(specifications->manifest
 (list "python-numpy"
       "python-biopython"))

$ guix package -m /tmp/manifest.scm -p /tmp/fail
The following packages will be installed:
   python-biopython 1.76
   python-numpy     1.21.3

guix package: error: profile contains conflicting entries for python-numpy
guix package: error:   first entry: python-numpy@1.21.3 /gnu/store/ggrkk9l67fjn1cj7alr8vx40xv08a6h0-python-numpy-1.21.3
guix package: error:   second entry: python-numpy@1.20.3 /gnu/store/wgsmkn68q8h178sqc7ywjcdr330z9rb6-python-numpy-1.20.3
guix package: error:    ... propagated from python-biopython@1.76
hint: Try upgrading both `python-numpy' and `python-biopython', or remove one of
them from the profile.
--8<---------------cut here---------------end--------------->8---

which is annoying.

I propose to refer as name “python-numpy” the symbol python-numpy which
leads to a consistent scientific Python stack.  And to refer as name
“python-numpy-next” the symbol python-numpy-next.

For instance, it is already the case for emacs-next or for the
Bioconductor package r-cistopic.

Doing so, adventurous people can use python-numpy-next (or recompile all
the scientific Python stack using it), or update it directly on master
(for testing say) without going to a core-update cycle.

WDYT?

Attached a proposed patch.

Cheers,
simon


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: patch.patch --]
[-- Type: text/x-diff, Size: 1466 bytes --]

From 962d942ffcba7893ab15c30dc602e51462d9b09a Mon Sep 17 00:00:00 2001
From: zimoun <zimon.toutoune@gmail.com>
Date: Thu, 30 Dec 2021 22:04:49 +0100
Subject: [PATCH] gnu: Rename last 'python-numpy' as 'python-numpy-next'.

* gnu/packages/python-xyz.scm (python-numpy-next): Rename.
---
 gnu/packages/python-xyz.scm | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 7ca0b1668d..047bb4cbb8 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -5366,11 +5366,9 @@ (define-public python2-cython
                     ""))
                  #t)))))))))
 
-;; NOTE: when upgrading numpy please make sure that python-pandas and
-;; python-scipy still build, as these three packages are often used together.
 (define-public python-numpy-next
   (package
-    (name "python-numpy")
+    (name "python-numpy-next")
     (version "1.21.3")
     (source
      (origin
@@ -5481,6 +5479,8 @@ (define-public python-numpy-1.20
      (substitute-keyword-arguments (package-arguments python-numpy-next)
        ((#:tests? _ #t) #f)))))
 
+;; NOTE: when upgrading numpy please make sure that python-pandas and
+;; python-scipy still build, as these three packages are often used together.
 (define-public python-numpy python-numpy-1.20)
 
 ;; NOTE: NumPy 1.8 is packaged only for Python 2 because it is of

base-commit: 002442b2209b0953dd209e6219696a8758ceceb2
-- 
2.34.0


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

* bug#52906: python-biopython conflicts with python-numpy
  2021-12-30 21:13 bug#52906: python-biopython conflicts with python-numpy zimoun
@ 2021-12-30 23:55 ` Leo Famulari
  2021-12-31 10:14 ` Ricardo Wurmus
  2021-12-31 12:50 ` Ricardo Wurmus
  2 siblings, 0 replies; 8+ messages in thread
From: Leo Famulari @ 2021-12-30 23:55 UTC (permalink / raw)
  To: zimoun; +Cc: Ricardo Wurmus, 52906

On Thu, Dec 30, 2021 at 10:13:48PM +0100, zimoun wrote:
> $ guix package -m /tmp/manifest.scm -p /tmp/fail
> The following packages will be installed:
>    python-biopython 1.76
>    python-numpy     1.21.3
> 
> guix package: error: profile contains conflicting entries for python-numpy
> guix package: error:   first entry: python-numpy@1.21.3 /gnu/store/ggrkk9l67fjn1cj7alr8vx40xv08a6h0-python-numpy-1.21.3
> guix package: error:   second entry: python-numpy@1.20.3 /gnu/store/wgsmkn68q8h178sqc7ywjcdr330z9rb6-python-numpy-1.20.3
> guix package: error:    ... propagated from python-biopython@1.76
> hint: Try upgrading both `python-numpy' and `python-biopython', or remove one of
> them from the profile.
> --8<---------------cut here---------------end--------------->8---

See also <https://issues.guix.gnu.org/52859>,
"tests/guix-pack-relocatable fails / numpy propagation collision".

> I propose to refer as name “python-numpy” the symbol python-numpy which
> leads to a consistent scientific Python stack.  And to refer as name
> “python-numpy-next” the symbol python-numpy-next.

Agreed, the stack should be kept consistent.




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

* bug#52906: python-biopython conflicts with python-numpy
  2021-12-30 21:13 bug#52906: python-biopython conflicts with python-numpy zimoun
  2021-12-30 23:55 ` Leo Famulari
@ 2021-12-31 10:14 ` Ricardo Wurmus
  2021-12-31 10:51   ` zimoun
  2021-12-31 12:50 ` Ricardo Wurmus
  2 siblings, 1 reply; 8+ messages in thread
From: Ricardo Wurmus @ 2021-12-31 10:14 UTC (permalink / raw)
  To: zimoun; +Cc: 52906


zimoun <zimon.toutoune@gmail.com> writes:

> Hi,
>
> Using 7022eb6, the package ’python-biopython’ propagates
> ’python-numpy’, i.e., python-numpy@1.20.

Back then we reverted to numpy 1.20.x as the default because of numba,
which did not work with 1.21.  I’m now upgrading numba (and llvmlite) to
a more recent release candidate, which should bring compatibility with
numpy 1.21.

If that works we’ll make python-numpy-next the new python-numpy.

Your patch is an acceptable workaround.  Arguably this should have been
done when I made numpy 1.20 the default on the core-updates-frozen
branch.  I’ll apply your patch later today unless the switch to numpy
1.21 as the default is successful.

-- 
Ricardo




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

* bug#52906: python-biopython conflicts with python-numpy
  2021-12-31 10:14 ` Ricardo Wurmus
@ 2021-12-31 10:51   ` zimoun
  2021-12-31 12:43     ` Ricardo Wurmus
  0 siblings, 1 reply; 8+ messages in thread
From: zimoun @ 2021-12-31 10:51 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 52906

Hi Ricardo,

On Fri, 31 Dec 2021 at 11:18, Ricardo Wurmus <rekado@elephly.net> wrote:
> zimoun <zimon.toutoune@gmail.com> writes:

> Back then we reverted to numpy 1.20.x as the default because of numba,
> which did not work with 1.21.  I’m now upgrading numba (and llvmlite) to
> a more recent release candidate, which should bring compatibility with
> numpy 1.21.
>
> If that works we’ll make python-numpy-next the new python-numpy.

I think that it could nice to have "python-numpy-next".  Now, because
we are right after a core-updates, the last Numpy version and the one
we use as scientific Python stack are really close.  But it will not
necessary the case between 2 core-updates merges.  Well, my point is
to have the core-updates package python-numpy used by all the
scientific Python stack and the leaf package python-numpy-next where
updates can happen on master, it can be used with transformations
etc., especially by scientific Python developper.


Cheers,
simon




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

* bug#52906: python-biopython conflicts with python-numpy
  2021-12-31 10:51   ` zimoun
@ 2021-12-31 12:43     ` Ricardo Wurmus
  2021-12-31 13:16       ` zimoun
  0 siblings, 1 reply; 8+ messages in thread
From: Ricardo Wurmus @ 2021-12-31 12:43 UTC (permalink / raw)
  To: zimoun; +Cc: 52906


zimoun <zimon.toutoune@gmail.com> writes:

> Hi Ricardo,
>
> On Fri, 31 Dec 2021 at 11:18, Ricardo Wurmus <rekado@elephly.net> wrote:
>> zimoun <zimon.toutoune@gmail.com> writes:
>
>> Back then we reverted to numpy 1.20.x as the default because of numba,
>> which did not work with 1.21.  I’m now upgrading numba (and llvmlite) to
>> a more recent release candidate, which should bring compatibility with
>> numpy 1.21.
>>
>> If that works we’ll make python-numpy-next the new python-numpy.
>
> I think that it could nice to have "python-numpy-next".  Now, because
> we are right after a core-updates, the last Numpy version and the one
> we use as scientific Python stack are really close.  But it will not
> necessary the case between 2 core-updates merges.  Well, my point is
> to have the core-updates package python-numpy used by all the
> scientific Python stack and the leaf package python-numpy-next where
> updates can happen on master, it can be used with transformations
> etc., especially by scientific Python developper.

Yes, it’s a good idea to have it anyway.

I just realized that switching over to the new numpy is going to cause
more than a 1000 rebuilds.  So I’ll apply your patch on the master
branch and build out the numpy upgrade on a separate branch.

Thank you!

-- 
Ricardo




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

* bug#52906: python-biopython conflicts with python-numpy
  2021-12-30 21:13 bug#52906: python-biopython conflicts with python-numpy zimoun
  2021-12-30 23:55 ` Leo Famulari
  2021-12-31 10:14 ` Ricardo Wurmus
@ 2021-12-31 12:50 ` Ricardo Wurmus
  2 siblings, 0 replies; 8+ messages in thread
From: Ricardo Wurmus @ 2021-12-31 12:50 UTC (permalink / raw)
  To: zimoun; +Cc: 52906-done


zimoun <zimon.toutoune@gmail.com> writes:

> Attached a proposed patch.

I applied it with a small change: I also had to override the name as
“python-numpy” in the derived packages.

Thanks!

-- 
Ricardo




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

* bug#52906: python-biopython conflicts with python-numpy
  2021-12-31 12:43     ` Ricardo Wurmus
@ 2021-12-31 13:16       ` zimoun
  2021-12-31 20:18         ` Ricardo Wurmus
  0 siblings, 1 reply; 8+ messages in thread
From: zimoun @ 2021-12-31 13:16 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 52906

Hi,

On Fri, 31 Dec 2021 at 13:44, Ricardo Wurmus <rekado@elephly.net> wrote:

> I just realized that switching over to the new numpy is going to cause
> more than a 1000 rebuilds.  So I’ll apply your patch on the master
> branch and build out the numpy upgrade on a separate branch.

Thanks!  A separate wip-* branch?


Cheers,
simon




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

* bug#52906: python-biopython conflicts with python-numpy
  2021-12-31 13:16       ` zimoun
@ 2021-12-31 20:18         ` Ricardo Wurmus
  0 siblings, 0 replies; 8+ messages in thread
From: Ricardo Wurmus @ 2021-12-31 20:18 UTC (permalink / raw)
  To: zimoun; +Cc: 52906


zimoun <zimon.toutoune@gmail.com> writes:

> Hi,
>
> On Fri, 31 Dec 2021 at 13:44, Ricardo Wurmus <rekado@elephly.net> wrote:
>
>> I just realized that switching over to the new numpy is going to cause
>> more than a 1000 rebuilds.  So I’ll apply your patch on the master
>> branch and build out the numpy upgrade on a separate branch.
>
> Thanks!  A separate wip-* branch?

Yes, I wanted to build this out on wip-upgrade-numpy or something
similar.  I’d like to avoid entangling this with other upgrades on a
core-updates or staging branch.

-- 
Ricardo




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

end of thread, other threads:[~2021-12-31 20:20 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-30 21:13 bug#52906: python-biopython conflicts with python-numpy zimoun
2021-12-30 23:55 ` Leo Famulari
2021-12-31 10:14 ` Ricardo Wurmus
2021-12-31 10:51   ` zimoun
2021-12-31 12:43     ` Ricardo Wurmus
2021-12-31 13:16       ` zimoun
2021-12-31 20:18         ` Ricardo Wurmus
2021-12-31 12:50 ` Ricardo Wurmus

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

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).