summary refs log tree commit diff
path: root/gnu/packages/python-science.scm
diff options
context:
space:
mode:
authorMarius Bakke <marius@gnu.org>2022-01-21 22:40:47 +0100
committerMarius Bakke <marius@gnu.org>2022-01-22 10:23:00 +0100
commitb2faad4bd084eb6dd88316f83543a43c982051ab (patch)
treeef74cf84bfadb782f387c6b27e2fd48d34c5d3ea /gnu/packages/python-science.scm
parent4f6cbc0aeee90453d39398a74730879ce16a2e7e (diff)
downloadguix-b2faad4bd084eb6dd88316f83543a43c982051ab.tar.gz
gnu: python-upsetplot: Update to 0.6.0.
* gnu/packages/python-science.scm (python-upsetplot): Update to 0.6.0.
[source](modules, snippet): New fields.
[arguments]: Remove obsolete phase.  Respect TESTS? in check phase.
Diffstat (limited to 'gnu/packages/python-science.scm')
-rw-r--r--gnu/packages/python-science.scm25
1 files changed, 15 insertions, 10 deletions
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 1966d72e09..8df311baea 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -675,26 +675,31 @@ annotations on an existing boxplots and barplots generated by seaborn.")
 (define-public python-upsetplot
   (package
     (name "python-upsetplot")
-    (version "0.4.1")
+    (version "0.6.0")
     (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "UpSetPlot" version))
        (sha256
         (base32
-         "0kwljcmsvrxm33y3ssham2bwv4a5m31mv96y9h18va0cv7s3mqn1"))))
+         "11zrykwnb00w5spx4mnsnm0f9gwrphdczainpmwkyyi50vipaa2l"))
+       (modules '((guix build utils)))
+       (snippet
+        ;; Patch for compatibility with newer setuptools:
+        ;; https://github.com/jnothman/UpSetPlot/pull/178
+        '(substitute* "upsetplot/data.py"
+           (("import distutils")
+            "from distutils.version import LooseVersion")
+           (("if distutils\\.version\\.LooseVersion")
+            "if LooseVersion")))))
     (build-system python-build-system)
     (arguments
-     `(#:phases
+     '(#:phases
        (modify-phases %standard-phases
-         (add-after 'unpack 'fix-versioning
-           (lambda _
-             (substitute* "setup.py"
-               (("pytest-cov<2.6") "pytest-cov"))))
          (replace 'check
-           (lambda* (#:key inputs outputs #:allow-other-keys)
-             (add-installed-pythonpath inputs outputs)
-             (invoke "pytest" "-v" "--doctest-modules"))))))
+           (lambda* (#:key tests? #:allow-other-keys)
+             (when tests?
+               (invoke "pytest" "-v" "--doctest-modules")))))))
     (propagated-inputs
      (list python-matplotlib python-pandas))
     (native-inputs