diff options
author | V3n3RiX <venerix@koprulu.sector> | 2024-03-07 19:06:59 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2024-03-07 19:06:59 +0000 |
commit | 4c5e0520b3ae5cce70461c3f7fceb313186d6ea2 (patch) | |
tree | fb41297e31179e75cb87887a943ea03bdf1ba258 /dev-python/httpbin | |
parent | 1b97f0352e38f8346984329b82a8be71632220a6 (diff) |
gentoo auto-resync : 07:03:2024 - 19:06:58
Diffstat (limited to 'dev-python/httpbin')
-rw-r--r-- | dev-python/httpbin/Manifest | 5 | ||||
-rw-r--r-- | dev-python/httpbin/files/httpbin-0.10.1-werkzeug-3.patch | 78 | ||||
-rw-r--r-- | dev-python/httpbin/httpbin-0.10.1-r5.ebuild | 55 | ||||
-rw-r--r-- | dev-python/httpbin/httpbin-0.10.2.ebuild | 2 |
4 files changed, 2 insertions, 138 deletions
diff --git a/dev-python/httpbin/Manifest b/dev-python/httpbin/Manifest index 98184f6a78e3..40aad939eb05 100644 --- a/dev-python/httpbin/Manifest +++ b/dev-python/httpbin/Manifest @@ -1,7 +1,4 @@ AUX httpbin-0.10.1-optional-flasgger.patch 2246 BLAKE2B f96db03047b779625f5107aff167eba52f6819b99c4fcded932e1c4337e02e00be15901a3a3dacaf708933c04cdf9b687a78eedd7b03fb13aac868163ee0f632 SHA512 1e161b7ead872cccda833fa7a21e82229563dd996f9d5511550becf5e5623a61a7c85034e8ccb125d39eeaf9cbefb67616d692d08554f93b1fb0295ce5530ccc -AUX httpbin-0.10.1-werkzeug-3.patch 2753 BLAKE2B eb335f980867d0f55b4f790689b890c4c92246e870f3714fcda88ec302491ff76e6cc46929d227d0ef3b5b5682152d0ad83dd97e46a16729282de1497935c5e5 SHA512 b232558f609425f7cb674bf34fa0116c76e69d93ce52df656a4d76a7fec8e5a9d6f872abc681bbafede7aa5c7187439a695fbbf18ebc5c8271001bc7776a7fb7 -DIST httpbin-0.10.1.tar.gz 107058 BLAKE2B a46732946fc3454e2ae71c4eec4f88521e190b736445c54f555021a273a75f57acbc9234237e6973a21fc3bf8f71d8c8b51d6422d719f03546ecd6887a20fe1b SHA512 e3b851253c347893a80e866e7d0188c572f2a87a540125de3d9cbe0b8c3f1ddfab2c60ee3ffde3fd7274fc662294c978c39b1b52acfd92c52fd552966da203be DIST httpbin-0.10.2.tar.gz 107327 BLAKE2B 39ab1e518c9f7e1ede9cd0aa2e3155f7e36267c83d1d2537a5b6cb5aa1c9e70efe96c5bf98a5b22cd05e70368d1495f8e5364032fcf2f476d62512b7e7322652 SHA512 731b842090be516d9eccb1d2bb8303128d2b2e24b1ebf0b2018a2f0b8629b164c7de686e1775841cd57417ec89941d98fc81f878a284c7242bfef4db481a781b -EBUILD httpbin-0.10.1-r5.ebuild 1273 BLAKE2B 8e9f8928bb6a813c87e7928b6f4364a1b5103efd9458196f02c323bdbbf83f1626d563d321494c12a2ca70aab06232ebd7f5c4fa4263ca804b15264dda04dddb SHA512 6e712edf26e963d4b43db50538b3d1868a0056141c4f95cde4850127421e042b2e2c2d271ea18e1698ffde93c4930fa1918eab165bf19f1a2da36a573c9f4c35 -EBUILD httpbin-0.10.2.ebuild 1257 BLAKE2B b81b45016e613376f41e96326efbf5879d9a5a25573cb4dad7d3514c54e1e66a69a4f0accd3e697a91a4ca736a99bf96da62d1cb677b48cbeab8c36526476f46 SHA512 2df24d0f07e2207b077bbb01e72130c58a80318f982f6f506b72df8cab1a4559f0eaead0c86ab3de586ad1acc125af32b57216e262413787a497a8f759ba1ed6 +EBUILD httpbin-0.10.2.ebuild 1249 BLAKE2B 22a9a804b3845ea19c0f6597c1907a230ca5e800fcdbe1fe4e2071ff87df3a8cf14378980a3d33d3660e85a905e34014de08123fcc686c942af027ed596d9b3f SHA512 c50d5cea1fe1aa05d57fbad22dd196df3dd81dc96d380dc7ab7dffb0042e80e49dc561813a4fd5129eb62c0513bce70e0fb9acbcde0a4d1feb02a42ecbf6b139 MISC metadata.xml 445 BLAKE2B c577334830bc0d51f9df221e224c231c254b3db9129e4028d53cbd96a4481728e3b721b44f569c243deeecfb38e8dc81a7566a0b7ccd665d51b1a69a3687eb18 SHA512 fcdbd0c24e12d91df89af24befa6c9600f28083c3fe38e88ebec9856f4fb5c4c137c3b85f2271422c513bbd7c31a457f8290ebc2dd755d9117d57aa42883eec8 diff --git a/dev-python/httpbin/files/httpbin-0.10.1-werkzeug-3.patch b/dev-python/httpbin/files/httpbin-0.10.1-werkzeug-3.patch deleted file mode 100644 index 5ad6f2743400..000000000000 --- a/dev-python/httpbin/files/httpbin-0.10.1-werkzeug-3.patch +++ /dev/null @@ -1,78 +0,0 @@ -diff --git a/httpbin/core.py b/httpbin/core.py -index 5c1783a1..a82c1b88 100644 ---- a/httpbin/core.py -+++ b/httpbin/core.py -@@ -32,7 +32,7 @@ - from werkzeug.wrappers import Response - except ImportError: # werkzeug < 2.1 - from werkzeug.wrappers import BaseResponse as Response --from werkzeug.http import parse_authorization_header -+ - from flasgger import Swagger, NO_SANITIZER - - from . import filters -@@ -47,6 +47,7 @@ - H, - ROBOT_TXT, - ANGRY_ASCII, -+ parse_authorization_header, - parse_multi_value_header, - next_stale_after_value, - digest_challenge_response, -@@ -636,16 +637,13 @@ def redirect_to(): - args_dict = request.args.items() - args = CaseInsensitiveDict(args_dict) - -- # We need to build the response manually and convert to UTF-8 to prevent -- # werkzeug from "fixing" the URL. This endpoint should set the Location -- # header to the exact string supplied. - response = app.make_response("") - response.status_code = 302 - if "status_code" in args: - status_code = int(args["status_code"]) - if status_code >= 300 and status_code < 400: - response.status_code = status_code -- response.headers["Location"] = args["url"].encode("utf-8") -+ response.headers["Location"] = args["url"] - - return response - -diff --git a/httpbin/helpers.py b/httpbin/helpers.py -index b29e1835..836c8026 100644 ---- a/httpbin/helpers.py -+++ b/httpbin/helpers.py -@@ -13,8 +13,14 @@ - import time - import os - from hashlib import md5, sha256, sha512 --from werkzeug.http import parse_authorization_header - from werkzeug.datastructures import WWWAuthenticate -+from werkzeug.http import dump_header -+ -+try: -+ from werkzeug.http import parse_authorization_header -+except ImportError: # werkzeug < 2.3 -+ from werkzeug.datastructures import Authorization -+ parse_authorization_header = Authorization.from_header - - from flask import request, make_response - from six.moves.urllib.parse import urlparse, urlunparse -@@ -466,9 +472,14 @@ def digest_challenge_response(app, qop, algorithm, stale = False): - ]), algorithm) - opaque = H(os.urandom(10), algorithm) - -- auth = WWWAuthenticate("digest") -- auth.set_digest('me@kennethreitz.com', nonce, opaque=opaque, -- qop=('auth', 'auth-int') if qop is None else (qop,), algorithm=algorithm) -- auth.stale = stale -+ values = { -+ 'realm': 'me@kennethreitz.com', -+ 'nonce': nonce, -+ 'opaque': opaque, -+ 'qop': dump_header(('auth', 'auth-int') if qop is None else (qop,)), -+ 'algorithm': algorithm, -+ 'stale': stale, -+ } -+ auth = WWWAuthenticate("digest", values=values) - response.headers['WWW-Authenticate'] = auth.to_header() - return response diff --git a/dev-python/httpbin/httpbin-0.10.1-r5.ebuild b/dev-python/httpbin/httpbin-0.10.1-r5.ebuild deleted file mode 100644 index d34c543e7976..000000000000 --- a/dev-python/httpbin/httpbin-0.10.1-r5.ebuild +++ /dev/null @@ -1,55 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -DISTUTILS_USE_PEP517=setuptools -PYTHON_COMPAT=( python3_{10..12} pypy3 ) - -inherit distutils-r1 optfeature pypi - -DESCRIPTION="HTTP Request and Response Service" -HOMEPAGE=" - https://github.com/psf/httpbin/ - https://pypi.org/project/httpbin/ -" - -LICENSE="|| ( MIT ISC )" -SLOT="0" -KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86" -IUSE="test-rust" - -RDEPEND=" - dev-python/brotlicffi[${PYTHON_USEDEP}] - dev-python/decorator[${PYTHON_USEDEP}] - >=dev-python/flask-2.2.4[${PYTHON_USEDEP}] - dev-python/itsdangerous[${PYTHON_USEDEP}] - dev-python/markupsafe[${PYTHON_USEDEP}] - dev-python/six[${PYTHON_USEDEP}] -" -BDEPEND=" - test? ( - test-rust? ( - dev-python/flasgger[${PYTHON_USEDEP}] - ) - ) -" - -distutils_enable_tests pytest - -src_prepare() { - local PATCHES=( - # https://github.com/psf/httpbin/pull/29 - "${FILESDIR}/${P}-werkzeug-3.patch" - # https://github.com/psf/httpbin/pull/44 (simplified) - "${FILESDIR}/${P}-optional-flasgger.patch" - ) - - # remove unnecessary deps - sed -i -e '/greenlet/d' -e '/flasgger/d' pyproject.toml || die - distutils-r1_src_prepare -} - -pkg_postinst() { - optfeature "Fancy index" dev-python/flasgger -} diff --git a/dev-python/httpbin/httpbin-0.10.2.ebuild b/dev-python/httpbin/httpbin-0.10.2.ebuild index a6c4050a2c16..6aecdd6bc65a 100644 --- a/dev-python/httpbin/httpbin-0.10.2.ebuild +++ b/dev-python/httpbin/httpbin-0.10.2.ebuild @@ -16,7 +16,7 @@ HOMEPAGE=" LICENSE="|| ( MIT ISC )" SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~mips ppc ppc64 ~riscv ~s390 sparc x86" IUSE="test-rust" RDEPEND=" |