From patchwork Fri Jan 6 23:11:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Sharlatan Hellseher X-Patchwork-Id: 45893 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 4738E27BBE9; Fri, 6 Jan 2023 23:12:22 +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_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI, RCVD_IN_MSPIKE_H2,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 8C79327BBEB for ; Fri, 6 Jan 2023 23:12:19 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pDvsb-0007SE-0s; Fri, 06 Jan 2023 18:12:05 -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 1pDvsY-0007Rz-Rf for guix-patches@gnu.org; Fri, 06 Jan 2023 18:12:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pDvsY-0001Ab-IC for guix-patches@gnu.org; Fri, 06 Jan 2023 18:12:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pDvsY-0006u1-7Y for guix-patches@gnu.org; Fri, 06 Jan 2023 18:12:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#60611] [PATCH] gnu: Add python-nox. Resent-From: Sharlatan Hellseher Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 06 Jan 2023 23:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 60611 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 60611@debbugs.gnu.org Cc: Sharlatan Hellseher X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.167304670726508 (code B ref -1); Fri, 06 Jan 2023 23:12:02 +0000 Received: (at submit) by debbugs.gnu.org; 6 Jan 2023 23:11:47 +0000 Received: from localhost ([127.0.0.1]:56062 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pDvsI-0006tU-JU for submit@debbugs.gnu.org; Fri, 06 Jan 2023 18:11:47 -0500 Received: from lists.gnu.org ([209.51.188.17]:35152) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pDvsG-0006tM-DZ for submit@debbugs.gnu.org; Fri, 06 Jan 2023 18:11:45 -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 1pDvsF-0007RC-3f for guix-patches@gnu.org; Fri, 06 Jan 2023 18:11:44 -0500 Received: from mail-wr1-x432.google.com ([2a00:1450:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pDvsB-00012Q-Tj for guix-patches@gnu.org; Fri, 06 Jan 2023 18:11:41 -0500 Received: by mail-wr1-x432.google.com with SMTP id w1so2639963wrt.8 for ; Fri, 06 Jan 2023 15:11:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=K7hm1ve8Mn2i7BG1dbRfckYp/eG9RSAo4oPH5htwX/w=; b=OmbLyEVW/WkiIZTYRXzTc+qWj+cc/C/otcw+Dzzy4AAY7U2VG4nCz+XFgFYdLTZyam h/ZcUhMlGQ8lqPS4AiBWY1FoQY+lSgHQC1KCoQLM1k+XQsu70W05fZGzM5GuxmR99NH1 dn6L0lcY11zcdZlOb1wYfdbMJfVXfQDbov+VOIBBJauT0DnmYF+ybshh5G46soLJqKNN D8FNM8U00k0qzt1GNSpfOBg5KFo1WYR8pTAwo9jIw2l2CMp9w7zUS6aG47B15P9o5Vkd 5prA1EHc2sYQ1gPV3tmBxaBUEYyeBvIS+zDG48hlgu/wpuB6MntEFHc4VmcbohwVcMkq LbtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=K7hm1ve8Mn2i7BG1dbRfckYp/eG9RSAo4oPH5htwX/w=; b=OnBmETNTE1pctwef9SdICLYvfuxX4zJegsuMNwZj2F3l6joW2gPTb3qUaBJo2JAbIG nWdibW+ivpM9vSsjF9uhfWqDgMwft0iMq1tSVDM2Kll9gP7JVYt+JOez65goutc2826A elB5D4m/IK/2idy3JeujCtLdjF8RFGjvax9iZgb8HLQXwPDr7t1B5m2GFn8DyodizINI WNkgssslYZxg+Nnk9x3dsLGPssA3lQ8CtsrAEfUOtsnyJwKewHJnGMfhE6ysgkLn7pet mOdBdVJQDiTKABdhQfM/rzVd699ydSF/cYB/oPp0jaWlv3skLTEiALxBrZ1KWfbPVB9r I7eA== X-Gm-Message-State: AFqh2kpk/9M3XCkHoIPO36WbhKW2L5vJr9w+CWCKwVYHtveav/2/Ka/X zcXKJtesDhE6x56y/t0b2zewTIVyHW8= X-Google-Smtp-Source: AMrXdXsEO5VwXBM7ffU0JX+5n/xTlonYNpH3H0qt0pN5ck1hQFccPjPsTRowyJvNnurPfFzw83Mpsw== X-Received: by 2002:adf:f88f:0:b0:269:a89f:df98 with SMTP id u15-20020adff88f000000b00269a89fdf98mr35577530wrp.54.1673046696514; Fri, 06 Jan 2023 15:11:36 -0800 (PST) Received: from guxtil.incerto.xyz (cpc100856-bagu15-2-0-cust368.1-3.cable.virginm.net. [82.25.93.113]) by smtp.gmail.com with ESMTPSA id z18-20020a5d44d2000000b002368f6b56desm2720848wrr.18.2023.01.06.15.11.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Jan 2023 15:11:35 -0800 (PST) From: Sharlatan Hellseher Date: Fri, 6 Jan 2023 23:11:32 +0000 Message-Id: <20230106231132.22871-1-sharlatanus@gmail.com> X-Mailer: git-send-email 2.38.1 MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::432; envelope-from=sharlatanus@gmail.com; helo=mail-wr1-x432.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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-check.scm (python-nox): New variable. Sort modules alphabetically and add pyproject build system. --- gnu/packages/python-check.scm | 63 +++++++++++++++++++++++++++++++---- 1 file changed, 57 insertions(+), 6 deletions(-) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 486abf1c13..aa8d5bb589 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2020 Edouard Klein ;;; Copyright © 2020, 2021 Vinicius Monego ;;; Copyright © 2020 Tanguy Le Carrour -;;; Copyright © 2021-2022 Sharlatan Hellseher +;;; Copyright © 2021-2023 Sharlatan Hellseher ;;; Copyright © 2021 Brendan Tildesley ;;; Copyright © 2021, 2022 Guillaume Le Vaillant ;;; Copyright © 2021 Bonface Munyoki Kilyungi @@ -39,8 +39,8 @@ (define-module (gnu packages python-check) #:use-module (gnu packages base) #:use-module (gnu packages bash) #:use-module (gnu packages check) - #:use-module (gnu packages docker) #:use-module (gnu packages django) + #:use-module (gnu packages docker) #:use-module (gnu packages openstack) #:use-module (gnu packages perl) #:use-module (gnu packages python-build) @@ -50,13 +50,14 @@ (define-module (gnu packages python-check) #:use-module (gnu packages web) #:use-module (gnu packages xml) #:use-module (gnu packages xorg) - #:use-module (guix utils) #:use-module ((guix licenses) #:prefix license:) - #:use-module (guix packages) + #:use-module (guix build-system pyproject) + #:use-module (guix build-system python) + #:use-module (guix download) #:use-module (guix gexp) #:use-module (guix git-download) - #:use-module (guix download) - #:use-module (guix build-system python)) + #:use-module (guix packages) + #:use-module (guix utils)) (define-public python-tappy (package @@ -2339,6 +2340,56 @@ (define-public python-test-utils which make writing and running functional and integration tests easier.") (license license:asl2.0))) +(define-public python-nox + (package + (name "python-nox") + (version "2022.11.21") + (source + (origin + ;; No tests in the PyPI tarball. + (method git-fetch) + (uri (git-reference + (url "https://github.com/wntrblm/nox") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1xfd63h75wiiyri4f7qyvy50f2ny0v4r4wx2h4px9ddbkh2k5g9p")))) + (build-system pyproject-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + ;; NOTE: This manipulation looks not clear as upstream package + ;; contains "nox/tox_to_nox.jinja2" file which is not copied + ;; during install phase and causes check and sanity-check + ;; phases fail due to missing file. Try to find more simple + ;; solution. + (add-after 'unpack 'rename-tox-to-nox-jinja2 + (lambda _ + (rename-file "nox/tox_to_nox.jinja2" "nox/tox_to_nox.jinja2.py"))) + (add-after 'install 'rename-tox-to-nox-jinja2-back + (lambda _ + (let* ((src-file (car (find-files (string-append #$output "/lib") + "tox_to_nox\\.jinja2\\.py$"))) + (dst-file (string-drop-right src-file 3))) + (rename-file src-file dst-file))))))) + (propagated-inputs + (list python-argcomplete + python-colorlog + python-packaging + python-py + python-virtualenv)) + (native-inputs + (list python-jinja2 + python-pytest + python-tox)) + (home-page "https://nox.thea.codes/") + (synopsis "Flexible test automation") + (description + "@code{nox} is a command-line tool that automates testing in multiple +Python environments, similar to @code{tox}. Unlike tox, Nox uses a standard +Python file for configuration.") + (license license:asl2.0))) + (define-public python-tox (package (name "python-tox")