[PATCH 1/2] gnu: python-hypercorn: Rename to hypercorn.

  • Done
  • quality assurance status badge
Details
3 participants
  • Efraim Flashner
  • Maxime Devos
  • Vinicius Monego
Owner
unassigned
Submitted by
Vinicius Monego
Severity
normal
V
V
Vinicius Monego wrote on 6 May 2021 21:17
(address . guix-patches@gnu.org)(name . Vinicius Monego)(address . monego@posteo.net)
20210506191726.103393-1-monego@posteo.net
* gnu/packages/python-web.scm (python-hypercorn): Rename to hypercorn.
---
This package provides the same use case for "gunicorn" that we have and both are used as binaries. I keep the inputs propagated because hypercorn also exposes some functionality over a module. See https://pgjones.gitlab.io/hypercorn/how_to_guides/api_usage.htmlfor reference.

gnu/packages/python-web.scm | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

Toggle diff (27 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 4f34502e86..223aca85a6 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -37,7 +37,7 @@
;;; Copyright © 2020 Holger Peters <holger.peters@posteo.de>
;;; Copyright © 2020 Noisytoot <noisytoot@gmail.com>
;;; Copyright © 2020 Edouard Klein <edk@beaver-labs.com>
-;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
+;;; Copyright © 2020, 2021 Vinicius Monego <monego@posteo.net>
;;; Copyright © 2020 Konrad Hinsen <konrad.hinsen@fastmail.net>
;;; Copyright © 2020 Giacomo Leidi <goodoldpaul@autistici.org>
;;; Copyright © 2021 Ekaitz Zarraga <ekaitz@elenq.tech>
@@ -1575,9 +1575,9 @@ choose to use, ensuring that you can communicate via WebSockets, as defined in
RFC6455, regardless of your programming paradigm.")
(license license:expat)))
-(define-public python-hypercorn
+(define-public hypercorn
(package
- (name "python-hypercorn")
+ (name "hypercorn")
(version "0.10.2")
(source
(origin
--
2.31.1
V
V
Vinicius Monego wrote on 6 May 2021 21:20
[PATCH 2/2] gnu: hypercorn: Update to 0.11.2.
(address . 48263@debbugs.gnu.org)(name . Vinicius Monego)(address . monego@posteo.net)
20210506192039.103711-1-monego@posteo.net
* gnu/packages/python-web.scm (hypercorn): Update to 0.11.2.
(python-h11): Update to 0.12.0.
[arguments]: Add 'test-target' keyword. Do not replace check phase.
[native-inputs]: Add python-pytest-runner.
---
Both packages have to updated at the same time or the hypercorn tests will fail (if either is updated first). I rebuilt the h11 dependents succesfully.

gnu/packages/python-web.scm | 17 +++++++----------
1 file changed, 7 insertions(+), 10 deletions(-)

Toggle diff (50 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 223aca85a6..59702ac62e 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -892,22 +892,19 @@ for use in Python programs that implement HTTP/2.")
(define-public python-h11
(package
(name "python-h11")
- (version "0.9.0")
+ (version "0.12.0")
(source
(origin
(method url-fetch)
(uri (pypi-uri "h11" version))
(sha256
- (base32 "1qfad70h59hya21vrzz8dqyyaiqhac0anl2dx3s3k80gpskvrm1k"))))
+ (base32 "0hk0nll6qazsambp3kl8cxxsbl4gv5y9252qadyk0jky0sv2q8j7"))))
(build-system python-build-system)
(arguments
- `(#:phases
- (modify-phases %standard-phases
- (replace 'check
- (lambda _
- (invoke "pytest" "-vv"))))))
+ `(#:test-target "pytest"))
(native-inputs
- `(("python-pytest" ,python-pytest)))
+ `(("python-pytest" ,python-pytest)
+ ("python-pytest-runner" ,python-pytest-runner)))
(home-page "https://github.com/python-hyper/h11")
(synopsis "Pure-Python, bring-your-own-I/O implementation of HTTP/1.1")
(description
@@ -1578,13 +1575,13 @@ RFC6455, regardless of your programming paradigm.")
(define-public hypercorn
(package
(name "hypercorn")
- (version "0.10.2")
+ (version "0.11.2")
(source
(origin
(method url-fetch)
(uri (pypi-uri "Hypercorn" version))
(sha256
- (base32 "15dgy47a18w2ls3hwykra1cyf7yzxmfjqnsqml482p12cxr2xwqr"))))
+ (base32 "16kai5d12f05jr89mj611zslxqri4cd7ixcgd6yhl211qlcyg8av"))))
(build-system python-build-system)
(arguments
`(#:phases
--
2.31.1
M
M
Maxime Devos wrote on 24 Jul 2021 20:42
Re: [bug#49123] [PATCH 09/24] gnu: python-hyperframe: Update to 6.0.1.
7f7754df6714b6c925b452e6dbde4c5a80afa017.camel@telenet.be
Vinicius Monego schreef op za 24-07-2021 om 18:30 [+0000]:
Toggle quote (12 lines)
> Em sáb, 2021-07-24 às 17:22 +0200, Maxime Devos escreveu:
>
> > The
> > dependency 'python-hypercorn' now fails to compile (*). Aside from
> > that, this
> > patch LGTM. This build failure seems to be caused by the update of
> > python-h11
> > (and not python-hyperframe), however.
>
> That is true (see [1]). python-hypercorn will build again if updated to
> the latest version.

Ok, we'll have to apply the '48263' patch before the '49123' patch series
then. FWIW, the '48263' patch looks good to me, but I only looked at
the patch itself and didn't do any other checks.

A comment about the commit message though:
Toggle quote (9 lines)
> * gnu/packages/python-web.scm (hypercorn): Update to 0.11.2.
> (python-h11): Update to 0.12.0.
> [arguments]: Add 'test-target' keyword. Do not replace check phase.
> [native-inputs]: Add python-pytest-runner.
> ---
> Both packages have to updated at the same time
> or the hypercorn tests will fail (if either is updated first). I
> rebuilt the h11 dependents succesfully.

Why not include this rationale in the commit message itself?

Toggle quote (2 lines)
Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYPxfJBccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7iSeAP0R3v9E2Zk396mR987Dv69RuiBI
5Y5HU7grW6bMPuPl2AEA4Epztpe5RaglmJEOdyZaoR2m1UImkVDS2u4xFJAMdAQ=
=mk5s
-----END PGP SIGNATURE-----


V
V
Vinicius Monego wrote on 12 Aug 2021 02:04
(name . Maxime Devos)(address . maximedevos@telenet.be)(address . 48263@debbugs.gnu.org)
878s17cyv6.fsf@posteo.net
Maxime Devos <maximedevos@telenet.be> writes:

Toggle quote (14 lines)
> A comment about the commit message though:
>> * gnu/packages/python-web.scm (hypercorn): Update to 0.11.2.
>> (python-h11): Update to 0.12.0.
>> [arguments]: Add 'test-target' keyword. Do not replace check
>> phase.
>> [native-inputs]: Add python-pytest-runner.
>> ---
>> Both packages have to updated at the same time
>> or the hypercorn tests will fail (if either is updated
>> first). I
>> rebuilt the h11 dependents succesfully.
>
> Why not include this rationale in the commit message itself?

It would be an implicit fact for me, and it's uncommon to explain
changes in the commit message. But if it improves clarity, I'm OK
with
including it.
V
V
Vinicius Monego wrote on 30 Oct 2021 19:30
[PATCH v2 1/3] gnu: python-hypercorn: Remove "python-" prefix from name.
(address . 48263@debbugs.gnu.org)(name . Vinicius Monego)(address . monego@posteo.net)
20211030173048.53815-1-monego@posteo.net
Hypercorn is mainly a CLI application but also supports a module interface.

* gnu/packages/python-web.scm (python-hypercorn): New deprecated variable.
(hypercorn): Renamed from the respective above.
---
gnu/packages/python-web.scm | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)

Toggle diff (38 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 2b5379950d..7a4e62ddf6 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -1615,9 +1615,9 @@ choose to use, ensuring that you can communicate via WebSockets, as defined in
RFC6455, regardless of your programming paradigm.")
(license license:expat)))
-(define-public python-hypercorn
+(define-public hypercorn
(package
- (name "python-hypercorn")
+ (name "hypercorn")
(version "0.10.2")
(source
(origin
@@ -1633,6 +1633,7 @@ RFC6455, regardless of your programming paradigm.")
(lambda* (#:key inputs outputs #:allow-other-keys)
(add-installed-pythonpath inputs outputs)
(invoke "pytest" "-vv"))))))
+ ;; Propagate because Hypercorn also exposes functionality over a module.
(propagated-inputs
`(("python-h11" ,python-h11)
("python-h2" ,python-h2)
@@ -1657,6 +1658,9 @@ WebSockets (over HTTP/1 and HTTP/2), ASGI/2, and ASGI/3 specifications. It can
utilise asyncio, uvloop, or trio worker types.")
(license license:expat)))
+(define-public python-hypercorn
+ (deprecated-package "python-hypercorn" hypercorn))
+
(define-public python-querystring-parser
(package
(name "python-querystring-parser")

base-commit: e1261ddd38cf02a0f046f3a5360502d659b4e7d4
--
2.30.2
V
V
Vinicius Monego wrote on 30 Oct 2021 19:30
[PATCH v2 2/3] gnu: hypercorn: Update to 0.11.2.
(address . 48263@debbugs.gnu.org)(name . Vinicius Monego)(address . monego@posteo.net)
20211030173048.53815-2-monego@posteo.net
* gnu/packages/python-web.scm (hypercorn): Update to 0.11.2.
---
gnu/packages/python-web.scm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Toggle diff (22 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 7a4e62ddf6..287574301d 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -1618,13 +1618,13 @@ RFC6455, regardless of your programming paradigm.")
(define-public hypercorn
(package
(name "hypercorn")
- (version "0.10.2")
+ (version "0.11.2")
(source
(origin
(method url-fetch)
(uri (pypi-uri "Hypercorn" version))
(sha256
- (base32 "15dgy47a18w2ls3hwykra1cyf7yzxmfjqnsqml482p12cxr2xwqr"))))
+ (base32 "16kai5d12f05jr89mj611zslxqri4cd7ixcgd6yhl211qlcyg8av"))))
(build-system python-build-system)
(arguments
`(#:phases
--
2.30.2
V
V
Vinicius Monego wrote on 30 Oct 2021 19:30
[PATCH v2 3/3] gnu: hypercorn: Honor #:tests? in 'check' phase.
(address . 48263@debbugs.gnu.org)(name . Vinicius Monego)(address . monego@posteo.net)
20211030173048.53815-3-monego@posteo.net
* gnu/packages/python-web.scm (hypercorn)[arguments]: Honor #:tests? in
'check' phase.
---
gnu/packages/python-web.scm | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)

Toggle diff (20 lines)
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 287574301d..204059a08a 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -1630,9 +1630,10 @@ RFC6455, regardless of your programming paradigm.")
`(#:phases
(modify-phases %standard-phases
(replace 'check
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (add-installed-pythonpath inputs outputs)
- (invoke "pytest" "-vv"))))))
+ (lambda* (#:key inputs outputs tests? #:allow-other-keys)
+ (when tests?
+ (add-installed-pythonpath inputs outputs)
+ (invoke "python" "-m" "pytest")))))))
;; Propagate because Hypercorn also exposes functionality over a module.
(propagated-inputs
`(("python-h11" ,python-h11)
--
2.30.2
E
E
Efraim Flashner wrote on 8 Nov 2021 21:38
Re: [bug#48263] [PATCH v2 1/3] gnu: python-hypercorn: Remove "python-" prefix from name.
(address . 48263-done@debbugs.gnu.org)
YYmKq/+fphyWzm7z@3900XT
Thanks! Patch pushed.

--
Efraim Flashner <efraim@flashner.co.il> ????? ?????
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAmGJiqsACgkQQarn3Mo9
g1H0/RAAtNyVfxzMFRl1BBzvtLLhgZ2I3H8Sk9OYWWUUPk4O+61xJmETY7RVNIK8
LldfymmVVAeJEdcfUsX191csscEgGHmwlDXl/04uEeJhnPvmAWeBmGCLCDEwXEY3
XIctkMFN/6aqINbnPjE3VkeChzIwEn/b9k4+JuMW8iTWXMQWLeBqFbicVTmSSZX2
NBS20H7Jb1AveVy09BlkRakZ7KB0yrZAvJ6LItMXf4tCMtHhQbi9imNTHphQFdID
YvNFPE7oUpwOey03CjoCWygLcchZo5/L8Hxkh3hQaOan0WgkjkOp+/eTV7jPNYId
JjTbjFKrsXDw1DC+65gctXY+sUrICaa+YJqBZBAezy6sJhEHx0/XmG0Mncd6Nhon
rJ2mEwsQgm+MJ598WUzsPpQMrxZC02jPaMmWtyjAPiW5a+QjHvvbd9VlfrdB35Ct
iocuIiJjr/pORanesKVjEudLN+pRESBeT6mFV4BN5B73HFGNT1miKOER8Yzn9YUQ
1Bz1rvsARRjdapyJ1cpKNz1YgLWakxYrUz2FZFrZj1XR6r+RmRns6AyehnN0kMzw
Zmi9Z5bVejV2kLjm3lWhPeoEcxnycJRLVaGd71HA8tWuOQHn6eeZxsjc9maJwu0/
5QjBxwZ7mhZ7IaKkoacNFiHFMfBHLaoe8i8a/62i/HR7lGXUX6k=
=L5uZ
-----END PGP SIGNATURE-----


Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 48263@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 48263
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch