From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id KA96CLTDjl9qdQAA0tVLHw (envelope-from ) for ; Tue, 20 Oct 2020 11:02:12 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id kN1RBLTDjl9cNQAAbx9fmQ (envelope-from ) for ; Tue, 20 Oct 2020 11:02:12 +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 EF45494014A for ; Tue, 20 Oct 2020 11:02:10 +0000 (UTC) Received: from localhost ([::1]:51736 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kUpP6-00042E-ED for larch@yhetil.org; Tue, 20 Oct 2020 07:02:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48108) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kUpN5-0002rp-KH for guix-patches@gnu.org; Tue, 20 Oct 2020 07:00:03 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:60407) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kUpN5-00069P-1S for guix-patches@gnu.org; Tue, 20 Oct 2020 07:00:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kUpN4-0005cE-Td for guix-patches@gnu.org; Tue, 20 Oct 2020 07:00:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#41807] [PATCHES] Add python-sanic and dependencies. Resent-From: paul Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Tue, 20 Oct 2020 11:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 41807 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: Lars-Dominik Braun Cc: 41807@debbugs.gnu.org X-Debbugs-Original-Cc: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.160319155021489 (code B ref -1); Tue, 20 Oct 2020 11:00:02 +0000 Received: (at submit) by debbugs.gnu.org; 20 Oct 2020 10:59:10 +0000 Received: from localhost ([127.0.0.1]:43720 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUpM6-0005aM-CS for submit@debbugs.gnu.org; Tue, 20 Oct 2020 06:59:10 -0400 Received: from lists.gnu.org ([209.51.188.17]:37018) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kUpM1-0005Zu-Kp for submit@debbugs.gnu.org; Tue, 20 Oct 2020 06:59:00 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47950) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kUpM1-0002Mu-CJ for guix-patches@gnu.org; Tue, 20 Oct 2020 06:58:57 -0400 Received: from latitanza.investici.org ([2001:888:2000:56::19]:32931) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kUpLt-00060x-FQ for guix-patches@gnu.org; Tue, 20 Oct 2020 06:58:57 -0400 Received: from mx3.investici.org (unknown [127.0.0.1]) by latitanza.investici.org (Postfix) with ESMTP id 4CFrG205bxz8sgQ; Tue, 20 Oct 2020 10:58:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=autistici.org; s=stigmate; t=1603191514; bh=/Xuc0ivTZopzG8QDlOPIapNAas9O/ARacM32bt1+zkM=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=JkF3CaZ2zGsEvS0BjgKY1ujYIYO6vxmqIKrCqgiEyXm0EpovRpuxJGPztC8YXmiDv sJLE0JdBiFPziN13oNIcEqK9AFaoywM7UDZ9en10Xg4eM4+Y0Ojm9yxGwyRzFOQZVy WAlqQ0wB11zx3eNVuqnZtFZ8digwCNKwe97oMMPA= Received: from [82.94.249.234] (mx3.investici.org [82.94.249.234]) (Authenticated sender: goodoldpaul@autistici.org) by localhost (Postfix) with ESMTPSA id 4CFrG15FVtz8sfr; Tue, 20 Oct 2020 10:58:33 +0000 (UTC) References: <20200617064940.GA5119@zpidnp36> From: paul Message-ID: <8c50cb48-c90c-9c2d-b2d5-5186cf4c688a@autistici.org> Date: Tue, 20 Oct 2020 12:58:27 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Icedove/78.3.2 MIME-Version: 1.0 In-Reply-To: <20200617064940.GA5119@zpidnp36> Content-Type: multipart/mixed; boundary="------------C8A94F88818EF84A37916187" Content-Language: en-US Received-SPF: pass client-ip=2001:888:2000:56::19; envelope-from=goodoldpaul@autistici.org; helo=latitanza.investici.org X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. 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, NICE_REPLY_A=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.4 (-) 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=autistici.org header.s=stigmate header.b=JkF3CaZ2; 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: c+N3qmDK5yJC This is a multi-part message in MIME format. --------------C8A94F88818EF84A37916187 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Hi :), I apologize for the long delay, On 6/17/20 8:49 AM, Lars-Dominik Braun wrote: > Hi, > >> I'm sending a patch series to add python-sanic, its dependencies and some >> dependencies of mypy. > I’ve got Sanic 19.12 in my own channel[1], which I wanted to upstream for a > long time now. Most packages have tests enabled, because I managed to package > that really old httpcore. Do you want to try and port these to sanic 20.03? > > Cheers, > Lars > > [1] https://github.com/leibniz-psychology/guix-zpid/blob/master/zpid/packages/sanic.scm > I managed to package sanic following your channel definition (and enabled tests), I updated some packages, removed some other packages that were already merged in Guix and produced an updated patch set. Thank you for your patience, Giacomo --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0001-gnu-Add-python-contextvars.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0001-gnu-Add-python-contextvars.patch" >From 63cee61e501d34a234106e47594eec6ce2504c6b Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Mon, 8 Jun 2020 23:57:19 +0200 Subject: [PATCH 1/9] gnu: Add python-contextvars. * gnu/packages/python-xyz.scm (python-contextvars): New variable. --- gnu/packages/python-xyz.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 575ce40ac8..cf20973cfc 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -22524,3 +22524,24 @@ applications with variable CPU loads).") (define-public python2-parallel (package-with-python2 python-parallel)) + +(define-public python-contextvars + (package + (name "python-contextvars") + (version "2.4") + (source + (origin + (method url-fetch) + (uri (pypi-uri "contextvars" version)) + (sha256 + (base32 + "17n3w8c20kgkgc6khaafdhhlcdj4bzman4paxqsl7harma59137k")))) + (build-system python-build-system) + (propagated-inputs + `(("python-immutables" ,python-immutables))) + (home-page + "https://github.com/MagicStack/contextvars") + (synopsis "PEP 567 Backport") + (description "This package implements a backport of Python 3.7 +@code{contextvars} module (see PEP 567) for Python 3.6.") + (license license:asl2.0))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0002-gnu-Add-python-aiofiles.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0002-gnu-Add-python-aiofiles.patch" >From 8f2fa7e0e72f2402b6d4b0970744973523575177 Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Tue, 9 Jun 2020 17:40:32 +0200 Subject: [PATCH 2/9] gnu: Add python-aiofiles. * gnu/packages/python-xyz.scm (python-aiofiles): New variable. --- gnu/packages/python-xyz.scm | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index cf20973cfc..1d51128090 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -22545,3 +22545,21 @@ applications with variable CPU loads).") (description "This package implements a backport of Python 3.7 @code{contextvars} module (see PEP 567) for Python 3.6.") (license license:asl2.0))) + +(define-public python-aiofiles + (package + (name "python-aiofiles") + (version "0.5.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "aiofiles" version)) + (sha256 + (base32 + "1bqmv019x16qa3zah0z915cw6z4va3fjs60fk2s7vyah3gyvrrlq")))) + (build-system python-build-system) + (home-page "https://github.com/Tinche/aiofiles") + (synopsis "File support for @code{asyncio}") + (description "@code{python-aiofiles} is a library for handling local +disk files in asyncio applications.") + (license license:asl2.0))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0003-gnu-Add-python-hstspreload.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0003-gnu-Add-python-hstspreload.patch" >From 8cfe473e1995c45c15faecde6cc48a15ca8ccdd2 Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Tue, 20 Oct 2020 12:37:54 +0200 Subject: [PATCH 3/9] gnu: Add python-hstspreload. * gnu/packages/python-web.scm (python-hstspreload): New variable. --- gnu/packages/python-web.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index b8b7ce9d31..b0bbd66583 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -5164,3 +5164,24 @@ Encoding for HTTP.") "This module acts as a webbrowser solving Cloudflare's Javascript challenges.") (license license:expat))) + +(define-public python-hstspreload + (package + (name "python-hstspreload") + (version "2020.10.20") + (source + (origin + (method url-fetch) + (uri (pypi-uri "hstspreload" version)) + (sha256 + (base32 + "1qah80p2xlib1rhivvdj9v5y3girxrj7dwp1mnh8mwaj5wy32y8a")))) + (build-system python-build-system) + (home-page + "https://github.com/sethmlarson/hstspreload") + (synopsis + "Chromium HSTS Preload list as a Python package") + (description + "@code{python-hstspreload} contains Chromium HSTS Preload list +as a Python package.") + (license license:bsd-3))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0004-gnu-Add-python-mypy-extensions.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0004-gnu-Add-python-mypy-extensions.patch" >From e19cceab869a67d876cbb807626b605f778cbc0f Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Tue, 9 Jun 2020 19:06:02 +0200 Subject: [PATCH 4/9] gnu: Add python-mypy-extensions. * gnu/packages/python-xyz.scm (python-mypy-extensions): New variable. --- gnu/packages/python-xyz.scm | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 1d51128090..82c3a21913 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -22563,3 +22563,25 @@ applications with variable CPU loads).") (description "@code{python-aiofiles} is a library for handling local disk files in asyncio applications.") (license license:asl2.0))) + +(define-public python-mypy-extensions + (package + (name "python-mypy-extensions") + (version "0.4.3") + (source + (origin + (method url-fetch) + (uri (pypi-uri "mypy-extensions" version)) + (sha256 + (base32 + "1a04qsk8hd1lqns8w1j7cr0vmvbhg450di5k1i16kqxkbf7q30id")))) + (build-system python-build-system) + (home-page + "https://github.com/python/mypy_extensions") + (synopsis + "Experimental type system extensions for mypy") + (description + "@code{python-mypy-extensions} defines experimental extensions +to the standard @code{typing} module that are supported by the +@code{mypy} typechecker.") + (license license:expat))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0005-gnu-Add-python-pyre-extensions.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0005-gnu-Add-python-pyre-extensions.patch" >From dbe8aad933bf7d6bf2571df8b08d48be73d73c9e Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Wed, 10 Jun 2020 12:52:20 +0200 Subject: [PATCH 5/9] gnu: Add python-pyre-extensions. * gnu/packages/python-xyz.scm (python-pyre-extensions): New variable. --- gnu/packages/python-xyz.scm | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 82c3a21913..2e3c8b762c 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -22585,3 +22585,27 @@ disk files in asyncio applications.") to the standard @code{typing} module that are supported by the @code{mypy} typechecker.") (license license:expat))) + +(define-public python-pyre-extensions + (package + (name "python-pyre-extensions") + (version "0.0.18") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pyre-extensions" version)) + (sha256 + (base32 + "0c5cbbqrfyjwakdh3kbwxis6mbrbwky1z1fqslgszgpcj4g43q30")))) + (build-system python-build-system) + (propagated-inputs + `(("python-typing-extensions" + ,python-typing-extensions) + ("python-typing-inspect" ,python-typing-inspect))) + (home-page "https://pyre-check.org") + (synopsis + "Type system extensions for use with @code{python-pyre}") + (description + "@code{python-pyre-extensions} defines extensions to the standard +@code{typing} module that are supported by the Pyre typechecker.") + (license license:expat))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0006-gnu-Add-python-nbsphinx.patch" Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename="0006-gnu-Add-python-nbsphinx.patch" >From e432d180aef69ecec895dd9dcbd6a1a476c01184 Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Tue, 20 Oct 2020 12:43:17 +0200 Subject: [PATCH 6/9] gnu: Add python-nbsphinx. * gnu/packages/sphinx.scm (python-nbsphinx): New variable. --- gnu/packages/sphinx.scm | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/sphinx.scm b/gnu/packages/sphinx.scm index f27f9d0176..439febc91b 100644 --- a/gnu/packages/sphinx.scm +++ b/gnu/packages/sphinx.scm @@ -13,6 +13,7 @@ ;;; Copyright © 2019 Nicolas Goaziou ;;; Copyright © 2019 Alexandros Theodotou ;;; Copyright © 2019 Brett Gilio +;;; Copyright © 2020 Giacomo Leidi ;;; ;;; This file is part of GNU Guix. ;;; @@ -643,3 +644,32 @@ translate and to apply translation to Sphinx generated document.") documentation when a change is detected. It also includes a livereload enabled web server.") (license license:expat))) + +(define-public python-nbsphinx + (package + (name "python-nbsphinx") + (version "0.7.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "nbsphinx" version)) + (sha256 + (base32 + "0j56bxdj08vn3q1804qwb1ywhga1mdg1awgm7i64wfpfwi8df2zm")))) + (build-system python-build-system) + (propagated-inputs + `(("python-docutils" ,python-docutils) + ("python-jinja2" ,python-jinja2) + ("python-nbconvert" ,python-nbconvert) + ("python-nbformat" ,python-nbformat) + ("python-sphinx" ,python-sphinx) + ("python-traitlets" ,python-traitlets))) + (home-page "https://nbsphinx.readthedocs.io/") + (synopsis "Jupyter Notebook Tools for Sphinx") + (description "@code{python-nbsphinx} is a Sphinx extension that +provides a source parser for @code{*.ipynb} files. Custom Sphinx +directives are used to show Jupyter Notebook code cells (and of course +their results) in both HTML and LaTeX output. Un-evaluated notebooks +- i.e. notebooks without stored output cells - will be automatically +executed during the Sphinx build process.") + (license license:expat))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0007-gnu-Add-python-dataclasses.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0007-gnu-Add-python-dataclasses.patch" >From 69618814e8904ea0baf0515d664de11985525463 Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Wed, 10 Jun 2020 17:00:25 +0200 Subject: [PATCH 7/9] gnu: Add python-dataclasses. * gnu/packages/python-xyz.scm (python-dataclasses): New variable. --- gnu/packages/python-xyz.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 2e3c8b762c..32a7381402 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -22609,3 +22609,24 @@ to the standard @code{typing} module that are supported by the "@code{python-pyre-extensions} defines extensions to the standard @code{typing} module that are supported by the Pyre typechecker.") (license license:expat))) + +(define-public python-dataclasses + (package + (name "python-dataclasses") + (version "0.7") + (source + (origin + (method url-fetch) + (uri (pypi-uri "dataclasses" version)) + (sha256 + (base32 + "1rh8111fbws2vxyf2qy2zw3x6p6cq1jfz8pf904gig5qwg56sjj9")))) + (build-system python-build-system) + (home-page + "https://github.com/ericvsmith/dataclasses") + (synopsis + "Backport of the @code{dataclasses} module for Python 3.6") + (description + "This is an implementation of PEP 557, Data Classes. It is a +backport of the @code{dataclasses} module for Python 3.6.") + (license license:asl2.0))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0008-gnu-Add-python-pywatchman.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="0008-gnu-Add-python-pywatchman.patch" >From 6265a08e96e310cac418bcebf16d259b46d85b95 Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Wed, 10 Jun 2020 17:58:58 +0200 Subject: [PATCH 8/9] gnu: Add python-pywatchman. * gnu/packages/python-xyz.scm (python-pywatchman): New variable. --- gnu/packages/python-xyz.scm | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 32a7381402..df7587749a 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -22630,3 +22630,24 @@ to the standard @code{typing} module that are supported by the "This is an implementation of PEP 557, Data Classes. It is a backport of the @code{dataclasses} module for Python 3.6.") (license license:asl2.0))) + +(define-public python-pywatchman + (package + (name "python-pywatchman") + (version "1.4.1") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pywatchman" version)) + (sha256 + (base32 + "1yf2gm20wc3djpb5larxii3l55xxby0il2ns3q0v1byyfnr7w16h")))) + (build-system python-build-system) + (arguments + `(#:tests? #f)) ;there are none + (home-page + "https://facebook.github.io/watchman/") + (synopsis "Watchman client for python") + (description "@code{python-pywatchman} is a library to connect and +query Watchman to discover file changes.") + (license license:bsd-3))) -- 2.28.0 --------------C8A94F88818EF84A37916187 Content-Type: text/x-patch; charset=UTF-8; name="0009-gnu-Add-python-sanic.patch" Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename="0009-gnu-Add-python-sanic.patch" >From c19961406504ba9e90e836b30751f68f1d4820d9 Mon Sep 17 00:00:00 2001 From: Giacomo Leidi Date: Tue, 20 Oct 2020 12:51:27 +0200 Subject: [PATCH 9/9] gnu: Add python-sanic. * gnu/packages/python-check.scm (python-pytest-sanic): New variable. * gnu/packages/python-web.scm (python-sanic): New variable. --- gnu/packages/python-check.scm | 28 +++++++++++++++++ gnu/packages/python-web.scm | 59 +++++++++++++++++++++++++++++++++++ 2 files changed, 87 insertions(+) diff --git a/gnu/packages/python-check.scm b/gnu/packages/python-check.scm index 498f495584..caab81f18c 100644 --- a/gnu/packages/python-check.scm +++ b/gnu/packages/python-check.scm @@ -1044,3 +1044,31 @@ any Python VM with basically no runtime overhead.") (description "Robber is a Python assertion library for test-driven and behavior-driven development (TDD and BDD).") (license license:expat))) + +;; This is only used by python-sanic +(define-public python-pytest-sanic + (package + (name "python-pytest-sanic") + (version "1.6.2") + (source + (origin + (method url-fetch) + (uri (pypi-uri "pytest-sanic" version)) + (sha256 + (base32 + "02ajd8z77ahi69kzkz200qgxrb4s2j4qb6k8j9ds1kz6qa6fsa34")))) + (build-system python-build-system) + (arguments + ;; Tests depend on python-sanic. + `(#:tests? #f)) + (propagated-inputs + `(("python-aiohttp" ,python-aiohttp) + ("python-async-generator" + ,python-async-generator) + ("python-pytest" ,python-pytest))) + (home-page + "https://github.com/yunstanford/pytest-sanic") + (synopsis "Pytest plugin for Sanic") + (description "A pytest plugin for Sanic. It helps you to test your +code asynchronously.") + (license license:expat))) diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm index b0bbd66583..5aaf9fb03d 100644 --- a/gnu/packages/python-web.scm +++ b/gnu/packages/python-web.scm @@ -39,6 +39,7 @@ ;;; Copyright © 2020 Edouard Klein ;;; Copyright © 2020 Vinicius Monego ;;; Copyright © 2020 Konrad Hinsen +;;; Copyright © 2020 Giacomo Leidi ;;; ;;; This file is part of GNU Guix. ;;; @@ -5185,3 +5186,61 @@ challenges.") "@code{python-hstspreload} contains Chromium HSTS Preload list as a Python package.") (license license:bsd-3))) + +(define-public python-sanic + (package + (name "python-sanic") + (version "20.9.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "sanic" version)) + (sha256 + (base32 + "0h832ja7j1f2w0ylbx5vj0j5gv5j9gn1yhhspvq0yikjyrkg46yr")))) + (build-system python-build-system) + (arguments + '(#:phases + (modify-phases %standard-phases + (add-after 'unpack 'use-recent-pytest + ;; Allow using recent dependencies. + (lambda* (#:key inputs #:allow-other-keys) + (substitute* "setup.py" + (("httpcore==0.3.0") "httpcore") + (("pytest==5.2.1") "pytest")) + #t)) + (replace 'check + (lambda* (#:key inputs outputs #:allow-other-keys) + (add-installed-pythonpath inputs outputs) + (invoke "pytest" "-vv" "./tests" "-k" + "not test_zero_downtime and not test_gunicorn_worker")))))) + (propagated-inputs + `(("python-aiofiles" ,python-aiofiles) + ("python-httptools" ,python-httptools) + ("python-httpx" ,python-httpx) + ("python-multidict" ,python-multidict) + ("python-ujson" ,python-ujson) + ("python-uvloop" ,python-uvloop) + ("python-websockets" ,python-websockets))) + (native-inputs + `(("gunicorn" ,gunicorn) + ("python-beautifulsoup4" ,python-beautifulsoup4) + ("python-hstspreload" ,python-hstspreload) + ("python-httpcore" ,python-httpcore) + ("python-pytest" ,python-pytest) + ("python-pytest-cov" ,python-pytest-cov) + ("python-pytest-benchmark" ,python-pytest-benchmark) + ("python-pytest-sanic" ,python-pytest-sanic) + ("python-pytest-sugar" ,python-pytest-sugar) + ("python-urllib3" ,python-urllib3) + ("python-uvicorn" ,python-uvicorn))) + (home-page + "https://github.com/huge-success/sanic/") + (synopsis + "Async Python 3.6+ web server/framework") + (description + "Sanic is a Python 3.6+ web server and web framework +that's written to go fast. It allows the usage of the +@code{async/await} syntax added in Python 3.5, which makes +your code non-blocking and speedy.") + (license license:expat))) -- 2.28.0 --------------C8A94F88818EF84A37916187--