From patchwork Thu Jan 11 20:58:28 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Troy Figiel X-Patchwork-Id: 58809 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 9453327BBE2; Thu, 11 Jan 2024 21:43:44 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL, SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 8F9E527BBE9 for ; Thu, 11 Jan 2024 21:43:42 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rO2pd-00030k-Ef; Thu, 11 Jan 2024 16:43:21 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rO2pU-0002xS-5J for guix-patches@gnu.org; Thu, 11 Jan 2024 16:43:15 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rO2pM-0002Lu-Ii for guix-patches@gnu.org; Thu, 11 Jan 2024 16:43:08 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rO2pK-0006qO-4f for guix-patches@gnu.org; Thu, 11 Jan 2024 16:43:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#68391] [PATCH 2/3] gnu: Add python-pandas-stubs. References: <87edentut3.fsf@troyfigiel.com> In-Reply-To: <87edentut3.fsf@troyfigiel.com> Resent-From: Troy Figiel Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 11 Jan 2024 21:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 68391 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 68391@debbugs.gnu.org Received: via spool by 68391-submit@debbugs.gnu.org id=B68391.170500932426222 (code B ref 68391); Thu, 11 Jan 2024 21:43:02 +0000 Received: (at 68391) by debbugs.gnu.org; 11 Jan 2024 21:42:04 +0000 Received: from localhost ([127.0.0.1]:34189 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rO2oN-0006or-Gb for submit@debbugs.gnu.org; Thu, 11 Jan 2024 16:42:03 -0500 Received: from mout-p-102.mailbox.org ([2001:67c:2050:0:465::102]:52418) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rO2oL-0006oN-SM for 68391@debbugs.gnu.org; Thu, 11 Jan 2024 16:42:03 -0500 Received: from smtp2.mailbox.org (smtp2.mailbox.org [10.196.197.2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-102.mailbox.org (Postfix) with ESMTPS id 4T9ymh20CBz9sDq for <68391@debbugs.gnu.org>; Thu, 11 Jan 2024 22:41:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=troyfigiel.com; s=MBO0001; t=1705009316; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=bpY5dtJsQ3MqrR0sA8gKHyCDC6s48dPmOxr6hzHYBoE=; b=0dr8Id78YZwJyT4Y1YEtjHYiRQbVzjG2KLMl+6eN0QN8YPlVnr3Q2IpvjqUxDcbruzOXFP 5cunJxBwWz87VWl+6BF1W7TpEBqRO6V73P+zGu+3ac0h9FTuii5raCBrvN03MG+LZ9kMdL BGR9BStOKM80A1U9JB93JNPidMusUOcrUp5GA3U9f/T2CzucM/Gt4i7aIY5sA2EBoy3Zk3 M6Ww8peIcjg8dVuA6Q5oSwzR08jRDEFxVOOlWIBCcVN7DyKv8wCw68BOD3Uzb6RPuWkfVw fMWHNFsILnUaaDAFAWPrjbM7w0vN0mhVwVQsrFdzhmuLmkEMjF1ytnsxCoghDQ== From: Troy Figiel Date: Thu, 11 Jan 2024 21:58:28 +0100 Message-ID: <87bk9rtun0.fsf@troyfigiel.com> MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/packages/python-science.scm (python-pandas-stubs): New variable. --- gnu/packages/python-science.scm | 58 +++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/gnu/packages/python-science.scm b/gnu/packages/python-science.scm index 8065de0e99..d8e0b343fb 100644 --- a/gnu/packages/python-science.scm +++ b/gnu/packages/python-science.scm @@ -561,6 +561,64 @@ (define-public python-pandas doing practical, real world data analysis in Python.") (license license:bsd-3))) +(define-public python-pandas-stubs + (package + (name "python-pandas-stubs") + ;; The versioning follows that of Pandas and uses the date of the + ;; python-pandas-stubs release. This is the latest version of + ;; python-pandas-stubs for python-pandas 1.4.4. + (version "1.4.4.220919") + (source + (origin + ;; No tests in the PyPI tarball. + (method git-fetch) + (uri (git-reference + (url "https://github.com/pandas-dev/pandas-stubs") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "14fhj1y71akwl41ws7cpazsbq5b8wf4rwaydqq2h39q7gylpcp99")))) + (build-system pyproject-build-system) + (arguments + '(#:phases (modify-phases %standard-phases + (add-before 'check 'prepare-x + (lambda _ + (system "Xvfb &") + (setenv "DISPLAY" ":0") + ;; xsel needs to write a log file. + (setenv "HOME" + (getcwd))))))) + (propagated-inputs (list python-types-pytz)) + ;; Add python-fastparquet to native inputs once it has been packaged. Its + ;; tests will be skipped for now. + (native-inputs (list python-lxml + python-matplotlib + python-pandas + python-poetry-core + python-pyarrow + python-pyreadstat + python-pytest + python-scipy + python-sqlalchemy + python-tables + python-tabulate + python-xarray + ;; Needed to test clipboard support. + which + xclip + xorg-server-for-tests + xsel)) + (home-page "https://pandas.pydata.org") + (synopsis "Type annotations for pandas") + (description + "This package contains public type stubs for @code{python-pandas}, +following the convention of providing stubs in a separate package, as +specified in @acronym{PEP, Python Enhancement Proposal} 561. The stubs cover +the most typical use cases of @code{python-pandas}. In general, these stubs +are narrower than what is possibly allowed by pandas, but follow a convention +of suggesting best recommended practices for using @code{python-pandas}.") + (license license:bsd-3))) + (define-public python-pythran (package (name "python-pythran")