diff options
Diffstat (limited to 'dev-python/flask-api')
-rw-r--r-- | dev-python/flask-api/Manifest | 5 | ||||
-rw-r--r-- | dev-python/flask-api/files/flask-api-2.0-fix-pypy-tests.patch | 22 | ||||
-rw-r--r-- | dev-python/flask-api/flask-api-2.0.ebuild | 13 | ||||
-rw-r--r-- | dev-python/flask-api/metadata.xml | 1 |
4 files changed, 34 insertions, 7 deletions
diff --git a/dev-python/flask-api/Manifest b/dev-python/flask-api/Manifest index 346da0bca9d6..4ad298dd4cf3 100644 --- a/dev-python/flask-api/Manifest +++ b/dev-python/flask-api/Manifest @@ -1,3 +1,4 @@ +AUX flask-api-2.0-fix-pypy-tests.patch 1150 BLAKE2B 571b48be64f135706a010648b667032132d38fafad20fa86220766c3c4a2a4953260cdeb1933936cf0369886f171736b0a55415b73086c2f4492679f3a091b9f SHA512 df0ab5fb20ef9d79ba1c1c3aa9b33b5b7a426039dbd18743297d1c6de484ea94047edd6b4a8b6a18060b8ed494c283f1091f622c11060170a67bd4480e640453 DIST flask-api-2.0.tar.gz 235593 BLAKE2B fadd746d91cc2c797a2e40ee6b11532eb0184a1289a692f8de844501a6656eaa1e87d10811119f267344185b22ed5c12bca43198d64d50ca8055ce95d0f62f19 SHA512 631e69e5a786598e6b5ef7e02c5c4f293eadd84d86fdf0155771d04fb6e87be5686756db90ab265cc097ae3d623c31dcebf5096a62c660d6f7d6fb1c3f3d4e3f -EBUILD flask-api-2.0.ebuild 682 BLAKE2B a471ae91b87ec3b644dd274edb0b6fe78508dbfc7f6fd47d3aead5598abc85aefec87b1e78fc5ff082e497230689e9cdd144278493d749e7f6abda762e47eec5 SHA512 4385a2880b33bb1dd99bc36f399eb1abd4c4df4433035488d956e43e85dd8b0c85acc2cddea828d674382249ac5c136335e9eb1c2bca3268e8bb712c4869841a -MISC metadata.xml 617 BLAKE2B 3da9d7dd713ae8f74c5ef2115935858737181082e2b86612927efcf6e47d9bce5a0d8117668155f530327180277d70ada57fc13e6a00e612440fb3321e29229a SHA512 d51812d4a625cc9f05847be119f068a574df2f9f4d51e8021b91a355faf3514c5911ebcf49c1f87f58ac64e56eb39ec4b2d0178af1680fae8c178f35d3d213a7 +EBUILD flask-api-2.0.ebuild 762 BLAKE2B 60cbfcc398b3242db93f0823cc0f6fc35b8d2bbb090f27be33eb8494d4595d1623c06f89d35a5e474d4bab496b024430e7972f323cf8ea86d75dd9f9000475cf SHA512 e333376852149a53cacc89d9a1ad293687d3aeb71c17c835d6198a03f59fa6b704be3ce88805b0b1b8d5c908294c9cf18ee12d6173c81cd5d698c73b03aceb9d +MISC metadata.xml 670 BLAKE2B b483d7c98922bd61e034f6caf6c2fb1b93f9f0c3f1942ecd3d8f2d9382faeeb93218c8f366362fa374fe55218d13e005e2b3463b8e8660742f8557a7c743e054 SHA512 d83d0b8b3ad74f71aa74b8df9fb4d691889f037f358c0671aa18e13fbce433d56dabd9af5c998efa5ca57a9454ad292a438e7366ee5fdde12e4f78135db5445c diff --git a/dev-python/flask-api/files/flask-api-2.0-fix-pypy-tests.patch b/dev-python/flask-api/files/flask-api-2.0-fix-pypy-tests.patch new file mode 100644 index 000000000000..4d30691b60d3 --- /dev/null +++ b/dev-python/flask-api/files/flask-api-2.0-fix-pypy-tests.patch @@ -0,0 +1,22 @@ +commit beb6a364de93a429398a9491e16f60a7aa82f51d +Author: Louis Sautier <sautier.louis@gmail.com> +Date: Tue Sep 22 00:46:38 2020 +0200 + + Fix tests with PyPy, remove unused Python2-related code + +diff --git a/flask_api/tests/test_parsers.py b/flask_api/tests/test_parsers.py +index 90a6b83..b7968f6 100644 +--- a/flask_api/tests/test_parsers.py ++++ b/flask_api/tests/test_parsers.py +@@ -36,9 +36,9 @@ class ParserTests(unittest.TestCase): + with self.assertRaises(exceptions.ParseError) as context: + parser.parse(stream, mediatypes.MediaType('application/json')) + detail = str(context.exception) +- expected_py2 = 'JSON parse error - Expecting property name: line 1 column 1 (char 1)' ++ expected_pypy = 'JSON parse error - Key name must be string at char: line 1 column 2 (char 1)' + expected_py3 = 'JSON parse error - Expecting property name enclosed in double quotes: line 1 column 2 (char 1)' +- self.assertIn(detail, (expected_py2, expected_py3)) ++ self.assertIn(detail, (expected_pypy, expected_py3)) + + def test_invalid_multipart(self): + parser = parsers.MultiPartParser() diff --git a/dev-python/flask-api/flask-api-2.0.ebuild b/dev-python/flask-api/flask-api-2.0.ebuild index e2fe9c1ce9dc..65d2fb330244 100644 --- a/dev-python/flask-api/flask-api-2.0.ebuild +++ b/dev-python/flask-api/flask-api-2.0.ebuild @@ -3,12 +3,12 @@ EAPI=7 -PYTHON_COMPAT=( python3_{6,7,8} ) +PYTHON_COMPAT=( pypy3 python3_{6,7,8,9} ) inherit distutils-r1 DESCRIPTION="Browsable web APIs for Flask" -HOMEPAGE="https://github.com/flask-api/flask-api" +HOMEPAGE="https://www.flaskapi.org/" # pypi mirror don't have docs folder SRC_URI="https://github.com/flask-api/flask-api/archive/v${PV}.tar.gz -> ${P}.tar.gz" @@ -16,10 +16,13 @@ LICENSE="BSD-2" SLOT="0" KEYWORDS="~amd64 ~x86" -RDEPEND="dev-python/flask[${PYTHON_USEDEP}] - dev-python/markdown[${PYTHON_USEDEP}]" +RDEPEND=" + dev-python/flask[${PYTHON_USEDEP}] + dev-python/markdown[${PYTHON_USEDEP}] +" -DEPEND="${RDEPEND}" +# https://github.com/flask-api/flask-api/pull/117 +PATCHES=( "${FILESDIR}/${P}-fix-pypy-tests.patch" ) distutils_enable_tests pytest diff --git a/dev-python/flask-api/metadata.xml b/dev-python/flask-api/metadata.xml index f29542a4355a..58477491510b 100644 --- a/dev-python/flask-api/metadata.xml +++ b/dev-python/flask-api/metadata.xml @@ -15,5 +15,6 @@ </maintainer> <upstream> <remote-id type="github">flask-api/flask-api</remote-id> + <remote-id type="pypi">Flask-API</remote-id> </upstream> </pkgmetadata> |