[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
158/233: gnu: python-pandas: Build and run tests in parallel.
From: |
guix-commits |
Subject: |
158/233: gnu: python-pandas: Build and run tests in parallel. |
Date: |
Sun, 24 Apr 2022 23:39:58 -0400 (EDT) |
apteryx pushed a commit to branch wip-ipython-polyglossia
in repository guix.
commit 24a7ee448662965602e6377d0d2619078d72eb9b
Author: Maxim Cournoyer <maxim.cournoyer@gmail.com>
AuthorDate: Mon Apr 18 15:27:38 2022 -0400
gnu: python-pandas: Build and run tests in parallel.
* gnu/packages/python-science.scm (python-pandas)
[phases]{enable-parallel-build}: New phase.
{check}: Add xdist -n option. Skip test_memory_usage test.
[native-inputs]: Add python-pytest-xdist.
---
gnu/packages/python-science.scm | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm
index 1852a16047..7721b04c31 100644
--- a/gnu/packages/python-science.scm
+++ b/gnu/packages/python-science.scm
@@ -412,6 +412,12 @@ library.")
(srfi srfi-26))
#:phases
(modify-phases %standard-phases
+ (add-after 'unpack 'enable-parallel-build
+ (lambda _
+ (substitute* "setup.py"
+ (("\"-j\", type=int, default=1")
+ (format #f "\"-j\", type=int, default=~a"
+ (parallel-job-count))))))
(add-after 'unpack 'patch-which
(lambda* (#:key inputs #:allow-other-keys)
(let ((which (assoc-ref inputs "which")))
@@ -438,6 +444,7 @@ library.")
(when tests?
(invoke "pytest" "-vv" "pandas" "--skip-slow"
"--skip-network"
+ "-n" (number->string (parallel-job-count))
"-k"
(string-append
;; These test access the internet (see:
@@ -447,7 +454,11 @@ library.")
"not test_wrong_url"
;; TODO: Missing input
" and not TestS3"
- " and not s3"))))))))))
+ " and not s3"
+ ;; This test fails when run with pytest-xdist
+ ;; (see:
+ ;;
https://github.com/pandas-dev/pandas/issues/39096).
+ " and not test_memory_usage"))))))))))
(propagated-inputs
(list python-jinja2
python-numpy
@@ -465,6 +476,7 @@ library.")
python-html5lib
python-pytest
python-pytest-mock
+ python-pytest-xdist
;; Needed to test clipboard support.
xorg-server-for-tests))
(home-page "https://pandas.pydata.org")
- 227/233: gnu: python-numpy-documentation: Overhaul package definition., (continued)
- 227/233: gnu: python-numpy-documentation: Overhaul package definition., guix-commits, 2022/04/24
- 131/233: gnu: Add texlive-xindy., guix-commits, 2022/04/24
- 139/233: gnu: python-httpcore: Update to 0.14.7 and enable tests., guix-commits, 2022/04/24
- 193/233: gnu: python-locust: Update to 2.8.6., guix-commits, 2022/04/24
- 207/233: gnu: python-pingouin: Update to 0.5.1., guix-commits, 2022/04/24
- 125/233: gnu: texlive-polyglossia: Rename and fix package., guix-commits, 2022/04/24
- 144/233: gnu: Add python-socksio., guix-commits, 2022/04/24
- 145/233: gnu: python-sqlalchemy: Run tests in parallel via xdist., guix-commits, 2022/04/24
- 146/233: gnu: python-sqlalchemy: Update to 1.4.35., guix-commits, 2022/04/24
- 153/233: gnu: Add python-jupyterlab-server., guix-commits, 2022/04/24
- 158/233: gnu: python-pandas: Build and run tests in parallel.,
guix-commits <=
- 162/233: gnu: python-umap-learn: Update to 0.5.3., guix-commits, 2022/04/24
- 167/233: gnu: python-jupyter-protocol: Update to 0.2.0., guix-commits, 2022/04/24
- 170/233: gnu: python-types-dataclasses: Fix typo., guix-commits, 2022/04/24
- 177/233: gnu: python-can: Update to 4.0.0., guix-commits, 2022/04/24
- 178/233: gnu: python-amqp: Update to 5.1.1 and enable tests., guix-commits, 2022/04/24
- 187/233: gnu: Add python-pyyaml-env-tag., guix-commits, 2022/04/24
- 199/233: gnu: weasyprint: Update to 54.3., guix-commits, 2022/04/24
- 203/233: gnu: setzer: Add python-wrapper to fix build., guix-commits, 2022/04/24
- 208/233: gnu: python-flask-wtf: Update to 1.0.1., guix-commits, 2022/04/24
- 209/233: gnu: python-flask-login: Update to 0.6.0., guix-commits, 2022/04/24