summaryrefslogtreecommitdiff
path: root/gnu/packages/python-web.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/python-web.scm')
-rw-r--r--gnu/packages/python-web.scm96
1 files changed, 86 insertions, 10 deletions
diff --git a/gnu/packages/python-web.scm b/gnu/packages/python-web.scm
index 0beff7d6e0..4aec58282a 100644
--- a/gnu/packages/python-web.scm
+++ b/gnu/packages/python-web.scm
@@ -2977,6 +2977,63 @@ other HTTP libraries.")
"Cheroot is a high-performance, pure-Python HTTP server.")
(license license:bsd-3)))
+(define-public python-cherrypy
+ (package
+ (name "python-cherrypy")
+ (version "18.10.0")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/cherrypy/cherrypy")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1mhs64z75mj3rk4rgxc3xm1yksaj253rj9czhk4632blz5yi0kbn"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list
+ #:test-flags
+ #~(map
+ (lambda (test)
+ (string-append "--deselect=cherrypy/test/" test))
+ (list
+ ;; XXX: Unraisable exceptions.
+ "test_config_server.py::ServerConfigTests::testMaxRequestSize"
+ "test_core.py::CoreRequestHandlingTest::testRanges"
+ "test_core.py::CoreRequestHandlingTest::testRedirect"
+ "test_encoding.py::EncodingTests::\
+test_multipart_decoding_bigger_maxrambytes"
+ "test_encoding.py::EncodingTests::\
+test_test_http.py::HTTPTests::test_post_filename_with_special_characters"
+ "test_http.py::HTTPTests::test_post_multipart"
+ "test_http.py::HTTPTests::test_post_filename_with_special_characters"
+ "test_mime.py::SafeMultipartHandlingTest::test_Flash_Upload"
+ "test_tutorials.py::TutorialTest::test09Files"))))
+ (propagated-inputs
+ (list python-cheroot
+ python-jaraco-collections
+ python-more-itertools
+ python-portend
+ python-zc-lockfile))
+ (native-inputs
+ (list python-objgraph
+ python-path
+ python-pytest
+ python-pytest-cov
+ python-pytest-forked
+ python-pytest-services
+ python-pytest-sugar
+ python-requests-toolbelt
+ python-setuptools))
+ (home-page "https://www.cherrypy.dev")
+ (synopsis "Object-Oriented HTTP framework")
+ (description
+ "CherryPy is a pythonic, object-oriented web framework. It helps in
+building web applications in the same way any other object-oriented Python
+program would be built.")
+ (license license:bsd-3)))
+
(define-public httpie
(package
(name "httpie")
@@ -6078,23 +6135,42 @@ HTTP via a UNIX domain socket.")
(define-public python-requests-unixsocket
(deprecated-package "python-requests-unixsocket" python-requests-unixsocket2))
-(define-public python-requests_ntlm
+(define-public python-requests-ntlm
(package
- (name "python-requests_ntlm")
- (version "1.2.0")
+ (name "python-requests-ntlm")
+ (version "1.3.0")
(source
(origin
- (method url-fetch)
- (uri (pypi-uri "requests_ntlm" version))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/requests/requests-ntlm")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
(sha256
- (base32
- "1a0np7lk8ma1plv1s4aw5q9h2z3aljprkl9qsfypqcaf0zsqbhik"))))
- (build-system python-build-system)
+ (base32 "0snsk66zdihdlyfjz2zgpyfgdyjg814m3cc4g3my09hdnb5xvagv"))))
+ (build-system pyproject-build-system)
+ (arguments
+ (list
+ #:test-flags
+ ;; XXX: Connection refused.
+ #~(list "-k" (string-join
+ (list "not test_ntlm_http_with_cbt"
+ "test_ntlm_http_without_cbt"
+ "test_ntlm_https_with_cbt"
+ "test_ntlm_https_without_cbt")
+ " and not "))
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'check 'spawn-test-server
+ (lambda _
+ ;; Taken from .github/workflows/ci.yml.
+ (spawn "python"
+ (list "python" "-m" "tests.test_server")))))))
(propagated-inputs
(list python-cryptography python-pyspnego python-requests))
+ (native-inputs (list python-flask python-pytest python-setuptools))
(home-page "https://github.com/requests/requests-ntlm")
- (synopsis
- "NTLM authentication support for Requests")
+ (synopsis "NTLM authentication support for Requests")
(description
"This package allows for HTTP NTLM authentication using the requests
library.")