From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id oF8yLb9V7l4RagAA0tVLHw (envelope-from ) for ; Sat, 20 Jun 2020 18:30:23 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id oPcHKb9V7l4CLgAA1q6Kng (envelope-from ) for ; Sat, 20 Jun 2020 18:30:23 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 0CEDF940539 for ; Sat, 20 Jun 2020 18:30:23 +0000 (UTC) Received: from localhost ([::1]:36102 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jmiFx-0003uO-KO for larch@yhetil.org; Sat, 20 Jun 2020 14:30:21 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60710) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jmiFf-0003rA-3K for guix-patches@gnu.org; Sat, 20 Jun 2020 14:30:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:47185) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jmiFe-00053W-Oj for guix-patches@gnu.org; Sat, 20 Jun 2020 14:30:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jmiFe-0000b8-L9 for guix-patches@gnu.org; Sat, 20 Jun 2020 14:30:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#41968] [PATCH 2/5] gnu: python-pandas: Update to 1.0.5. Resent-From: Pierre Langlois Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 20 Jun 2020 18:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41968 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 41968@debbugs.gnu.org Cc: Pierre Langlois Received: via spool by 41968-submit@debbugs.gnu.org id=B41968.15926777802250 (code B ref 41968); Sat, 20 Jun 2020 18:30:02 +0000 Received: (at 41968) by debbugs.gnu.org; 20 Jun 2020 18:29:40 +0000 Received: from localhost ([127.0.0.1]:58731 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jmiFB-0000a7-5g for submit@debbugs.gnu.org; Sat, 20 Jun 2020 14:29:40 -0400 Received: from mout.gmx.net ([212.227.15.15]:40949) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jmiF7-0000Zq-MC for 41968@debbugs.gnu.org; Sat, 20 Jun 2020 14:29:32 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1592677763; bh=SLRuUI6Lnq2OAgi189LznUOpm+MbPlA59RG4lD+104k=; h=X-UI-Sender-Class:References:From:To:Cc:Subject:In-reply-to:Date; b=NpTf1YVd3mf10H7h3Yd32o7kG6chMNThibI8Habi+6p0igru/kNSIB8QGg7DxWIjb SHUAhtJLN0xQ7u4pKY9XOEDwzfcisLsEQg0p3vZZ4+yV/FwsR+kbE6BDbhkWbP/9BQ KZ00t5bKCN3RE3v5aJGEqJ1DaEK5RdXmh0ur62BE= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from e119807-lin ([93.22.246.159]) by mail.gmx.com (mrgmx004 [212.227.17.184]) with ESMTPSA (Nemesis) id 1N2mBa-1ijvLz0EZw-0136V4; Sat, 20 Jun 2020 20:29:23 +0200 References: <87r1u9ha11.fsf@gmx.com> User-agent: mu4e 1.4.10; emacs 26.3 From: Pierre Langlois In-reply-to: <87r1u9ha11.fsf@gmx.com> Date: Sat, 20 Jun 2020 20:29:20 +0200 Message-ID: <87ftaph9q7.fsf@gmx.com> MIME-Version: 1.0 Content-Type: text/x-patch; charset=utf-8 Content-Disposition: inline; filename=0002-gnu-python-pandas-Update-to-1.0.5.patch Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:M1ArASLzaTtFzCpIzIctDTUdZzzB3+akSssmkFigL4eOO1GfZtk RuWtCYePEHGvExOOAPCDem3jSBrxb6GoHrV9OdyFc8oJcQ2rWVeNm66ScbUJCYlIzGajD9Y n1SdbQJgnG1yjrR638Qor7lcuFdAScAjgRc61mpgXEp8x4gyuor78fA/M4U4abxv/Xlig/D Fh0UoeCn4D7wY8/dD1G0w== X-UI-Out-Filterresults: notjunk:1;V03:K0:jAAfYSb3r9M=:qhWG7ppSDk4YnpcgBkVuHF AnmmRU17fVNlU/Eb9kNLMNBjkfB+npEd+r4AsiQIoLBT7DoK7p8F733C30p0bjiveb/4l0Xev dCSTUsk06CMGunBqRSzObH7+Fm45m7TcA4BN6sxm9W+xMw4//89FaCkFezJ/vLN6CcBIauV+h 7KLK1LSvQOYfoR1H8hPsHGKKlGrNwJpCKrUpY8LIwSrNVNzXLmkqfG4mb1jEX+rrJwGDqrorT Rq7gIOI6Mi8eBYeu2RJ71+qsntFkX+aOzy205ORhp2gNsd8Ru/hh8g+SyKsZe+K5UqetL5Jzq zvvHWTGGTsTmPMnfqcHLvod36SQVDSUTsRvC/cZiJQI/5Dl7m2OBMxLGPcFZ1mToNtxXeEsAM srKAOIxmZj4u1+ecCjBUWv/YVKmLR2dps6WtLBaxVw820NwMIJOn2Ou9XtWvvgT0bTGLysmhh SuLfvaqJnU5Af5Nhekd7QU84wDtEHX1rHM3KE/tyCQjpc/xvkgEXY5Exz0ceVxbv9TGT/Ul/E 6AWLpO5Tj02wxQ0paFZzlb3A6P6JThHGVMVHx/0t4xirEe4qF/PgC3RvDVWEv9PJMNkzoiXhe +e8ItpfiMq3QmM0d1jQwqbLmISKzn9MP1INvViVeLaU9JOrC/3DKa6wMc6hBqSHoraHO7NmPh sVQNgZZswl2z461YiciRpRWGrYRkxXDIUZ9MqyVAUehlaKzSHRy3oemQX+hJbjp/E5rO/rVNT 3UdTzNVa093BD+1culfseE51F4EdR+OrryC8ViA0L9yGGIciCvbXcXdn/N16Bzg9dezN4yuh3 bF5v8rWrXDfmILlIos/tB8i4Ym5ESmfzZjWO0heM9tX57uvD7/oxbhOw69X4jfTmDKG4ar5be vRMNIYMivLgDZSvS0+015jwv3qioJUb4gYr1P+UiWa5BtfoLJuhkoLK5s1rqLPmdNc8RUlSDg wo286ppcT58TYZi3oW4K9vy2WWCG6HmqStkLG1fVIiYgxtXskC3WlfzIiO5DR03v/CCdPnET/ sDwalsUpfPN+d1aJbRheRml83j+eysXxVVyO07StZByvhWCgk97HF0Djs/gxKI652wT/ANLO9 OKLuP0FHXoYEJ/R9CfeR7qu9Od8NdP8DBAi5/l6Fwyyd6+khmocO9nHc9X2gojeAE1Q1Nmwgv u7K7htboLgGSWx4xWb0TfwiXbjb8RuOVfRX5sblROckXqumPv3uq8Z62Q1UNlyysRjZJ4MP9T JWaiYnaNPEtKfZT3F X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Spam-Score: -1.0 (-) X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=gmx.net header.s=badeba3b8450 header.b=NpTf1YVd; dmarc=none; spf=pass (aspmx1.migadu.com: domain of guix-patches-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=guix-patches-bounces@gnu.org X-Spam-Score: -0.01 X-TUID: pSV3JDgufY9F >From 6b7633a973970e0148fa18007a1fd378a6664a6b Mon Sep 17 00:00:00 2001 From: Pierre Langlois Date: Thu, 18 Jun 2020 00:58:41 +0200 Subject: [PATCH 2/5] gnu: python-pandas: Update to 1.0.5. But also keep version 0.25.3 around for packages requiring an earlier versions, as well as version 0.24.2 for a version with python2. * gnu/packages/python-science.scm (python-pandas): Update to 1.0.5. [arguments]: Adapt 'patch-which phase. Add new 'prepare-x phase. Do not delete tests that depend on "moto", they are skipped automatically. [propagated-inputs]: Add python-jinja2. [inputs]: Add xsel and xclip. [native-inputs]: Add xorg-server-for-tests so we can test clipboard support. (python-pandas-0.24): New variable. (python2-pandas): Inherit from python-pandas-0.25. * gnu/packages/bioinformatics.scm (python-biom-format)[propagated-inputs]: Switch to python-pandas-0.25. --- gnu/packages/bioinformatics.scm | 4 +- gnu/packages/python-science.scm | 65 ++++++++++++++++++++++++--------- 2 files changed, 50 insertions(+), 19 deletions(-) diff --git a/gnu/packages/bioinformatics.scm b/gnu/packages/bioinformatics.= scm index 580488fc49..3ee134db77 100644 --- a/gnu/packages/bioinformatics.scm +++ b/gnu/packages/bioinformatics.scm @@ -943,7 +943,9 @@ Python.") ("python-future" ,python-future) ("python-click" ,python-click) ("python-h5py" ,python-h5py) - ("python-pandas" ,python-pandas))) + ;; FIXME: Upgrade to pandas 1.0 when + ;; https://github.com/biocore/biom-format/issues/837 is resolved. + ("python-pandas" ,python-pandas-0.25))) (native-inputs `(("python-cython" ,python-cython) ("python-pytest" ,python-pytest) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.= scm index 2f7516b9f6..55fc1be4f9 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -8,6 +8,7 @@ ;;; Copyright =C2=A9 2019 Tobias Geerinckx-Rice ;;; Copyright =C2=A9 2019 Maxim Cournoyer ;;; Copyright =C2=A9 2019 Giacomo Leidi +;;; Copyright =C2=A9 2020 Pierre Langlois ;;; ;;; This file is part of GNU Guix. ;;; @@ -37,7 +38,9 @@ #:use-module (gnu packages python-xyz) #:use-module (gnu packages sphinx) #:use-module (gnu packages time) + #:use-module (gnu packages xdisorg) #:use-module (gnu packages xml) + #:use-module (gnu packages xorg) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix utils) @@ -231,13 +234,13 @@ Cython.") (define-public python-pandas (package (name "python-pandas") - (version "0.25.2") + (version "1.0.5") (source (origin (method url-fetch) (uri (pypi-uri "pandas" version)) (sha256 - (base32 "1gp2pvzdiakvgjmykdzdlzrsfbg4vjm49jjdl9s0ha0a3yfs34fa")))) + (base32 "1a2gv3g6jr6vb5ca43fkwjl5xf86wpfz8y3zcy787adjl0hdkib9")))) (build-system python-build-system) (arguments `(#:modules ((guix build utils) @@ -249,8 +252,15 @@ Cython.") (lambda* (#:key inputs #:allow-other-keys) (let ((which (assoc-ref inputs "which"))) (substitute* "pandas/io/clipboard/__init__.py" - (("^CHECK_CMD =3D .*") - (string-append "CHECK_CMD =3D \"" which "\"\n")= ))) + (("^WHICH_CMD =3D .*") + (string-append "WHICH_CMD =3D \"" which "\"\n")= ))) + #t)) + (add-before 'check 'prepare-x + (lambda _ + (system "Xvfb &") + (setenv "DISPLAY" ":0") + ;; xsel needs to write a log file. + (setenv "HOME" "/tmp") #t)) (replace 'check (lambda _ @@ -265,25 +275,19 @@ Cython.") (substitute* "setup.cfg" (("addopts =3D --strict-data-files") "addopts = =3D ")) (with-directory-excursion build-directory - ;; Delete tests that require "moto" which is not= yet - ;; in Guix. - (for-each delete-file - '("pandas/tests/io/conftest.py" - "pandas/tests/io/json/test_compressi= on.py" - "pandas/tests/io/parser/test_network= .py" - "pandas/tests/io/test_parquet.py")) (invoke "pytest" "-vv" "pandas" "--skip-slow" - "--skip-network" "-k" - ;; XXX: Due to the deleted tests above. - "not test_read_s3_jsonl")))))))) + "--skip-network")))))))) (propagated-inputs - `(("python-numpy" ,python-numpy) + `(("python-jinja2" ,python-jinja2) + ("python-numpy" ,python-numpy) ("python-openpyxl" ,python-openpyxl) ("python-pytz" ,python-pytz) ("python-dateutil" ,python-dateutil) ("python-xlrd" ,python-xlrd))) (inputs - `(("which" ,which))) + `(("which" ,which) + ("xclip" ,xclip) + ("xsel" ,xsel))) (native-inputs `(("python-cython" ,python-cython) ("python-beautifulsoup4" ,python-beautifulsoup4) @@ -291,7 +295,9 @@ Cython.") ("python-html5lib" ,python-html5lib) ("python-nose" ,python-nose) ("python-pytest" ,python-pytest) - ("python-pytest-mock" ,python-pytest-mock))) + ("python-pytest-mock" ,python-pytest-mock) + ;; Needed to test clipboard support. + ("xorg-server" ,xorg-server-for-tests))) (home-page "https://pandas.pydata.org") (synopsis "Data structures for data analysis, time series, and statist= ics") (description @@ -303,10 +309,33 @@ doing practical, real world data analysis in Python.") (properties `((python2-variant . ,(delay python2-pandas)))) (license license:bsd-3))) =20 +(define-public python-pandas-0.25 + (package + (inherit python-pandas) + (version "0.25.3") + (source (origin + (method url-fetch) + (uri (pypi-uri "pandas" version)) + (sha256 + (base32 + "191048m6kdc6yfvqs9w412lq60cfvigrsb57y0x116lwibgp9njj")))) + (arguments + (substitute-keyword-arguments (package-arguments python-pandas) + ((#:phases phases) + `(modify-phases ,phases + (replace 'patch-which + (lambda* (#:key inputs #:allow-other-keys) + (let ((which (assoc-ref inputs "which"))) + (substitute* "pandas/io/clipboard/__init__.py" + (("^CHECK_CMD =3D .*") + (string-append "CHECK_CMD =3D \"" which "\"\n")))) + #t)) + (delete 'prepare-x))))))) + ;; Pandas 0.24.x are the last versions that support Python 2. (define-public python2-pandas (let ((pandas (package-with-python2 - (strip-python2-variant python-pandas)))) + (strip-python2-variant python-pandas-0.25)))) (package (inherit pandas) (version "0.24.2") --=20 2.26.2