summaryrefslogtreecommitdiff
path: root/dev-python/hpack
diff options
context:
space:
mode:
authorPalica <palica+gitlab@liguros.net>2020-06-23 22:35:08 +0200
committerPalica <palica+gitlab@liguros.net>2020-06-23 22:35:08 +0200
commitecdac123787b96ce6649f0f91da12ea6458cc2b1 (patch)
treeb89c74d9e6fe6e8aebc4c77bcbeb4ab73214127d /dev-python/hpack
parent1be72aa41cf41dedadeecf59dca9f01de6381f5e (diff)
downloadbaldeagleos-repo-ecdac123787b96ce6649f0f91da12ea6458cc2b1.tar.gz
baldeagleos-repo-ecdac123787b96ce6649f0f91da12ea6458cc2b1.tar.xz
baldeagleos-repo-ecdac123787b96ce6649f0f91da12ea6458cc2b1.zip
Updating liguros repo
Diffstat (limited to 'dev-python/hpack')
-rw-r--r--dev-python/hpack/Manifest2
-rw-r--r--dev-python/hpack/files/hpack-3.0.0-hypothesis-healthcheck.patch21
-rw-r--r--dev-python/hpack/hpack-2.3.0-r1.ebuild40
-rw-r--r--dev-python/hpack/hpack-3.0.0.ebuild42
-rw-r--r--dev-python/hpack/metadata.xml21
5 files changed, 126 insertions, 0 deletions
diff --git a/dev-python/hpack/Manifest b/dev-python/hpack/Manifest
new file mode 100644
index 000000000000..3b19773f6250
--- /dev/null
+++ b/dev-python/hpack/Manifest
@@ -0,0 +1,2 @@
+DIST hpack-2.3.0.tar.gz 41610 BLAKE2B 65fe4f07f64dddff5b24b3a84f7e49de32e358fa59bb1b21e619135ef33d282d4cd24283e93c71bb71c89d7b5b2a3f8ed36f6d406751c54247472a75192bf50b SHA512 a3d13da105482bb258ee3a2314b2629215028777f84127f71359f08819c96af088a3952bb0a74435472035d10ee6e3943cdad689a28f04cbc12cddcc4af9a8a7
+DIST hpack-3.0.0.tar.gz 5305971 BLAKE2B d1df8a1b2a1ce8b91e63cab475d3957f937fb74c0bec343d342971be1bb7cfbc929c53cf041845df2965cef0cfb098345bf0612acabc7ef3e5e23f6f0aa44f2f SHA512 7b9cf5e643dff2a6454bfe419b797c8ed1a0fe6ec3b725d2696da5a820ab96fe87a64e600b1831c7024bd82616b155a0aa058301acb32172155b6538ba0a73c6
diff --git a/dev-python/hpack/files/hpack-3.0.0-hypothesis-healthcheck.patch b/dev-python/hpack/files/hpack-3.0.0-hypothesis-healthcheck.patch
new file mode 100644
index 000000000000..aaabac3b3046
--- /dev/null
+++ b/dev-python/hpack/files/hpack-3.0.0-hypothesis-healthcheck.patch
@@ -0,0 +1,21 @@
+diff --git a/test/conftest.py b/test/conftest.py
+index f5801da..c5e3c66 100644
+--- a/test/conftest.py
++++ b/test/conftest.py
+@@ -4,11 +4,16 @@ import os
+ import json
+ import sys
+
++from hypothesis import settings, HealthCheck
+ from hypothesis.strategies import text
+
+ if sys.version_info[0] == 2:
+ from codecs import open
+
++settings.register_profile("gentoo",
++ suppress_health_check=(HealthCheck.too_slow,))
++settings.load_profile("gentoo")
++
+ # We need to grab one text example from hypothesis to prime its cache.
+ text().example()
+
diff --git a/dev-python/hpack/hpack-2.3.0-r1.ebuild b/dev-python/hpack/hpack-2.3.0-r1.ebuild
new file mode 100644
index 000000000000..89ccb2e23d62
--- /dev/null
+++ b/dev-python/hpack/hpack-2.3.0-r1.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 python3_6)
+
+inherit distutils-r1
+
+DESCRIPTION="Pure-Python HPACK header compression"
+HOMEPAGE="https://python-hyper.org/hpack/en/latest/ https://pypi.org/project/hpack/"
+SRC_URI="mirror://pypi/${P:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ppc ppc64 s390 sparc x86"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND=""
+DEPEND="${RDEPEND}
+ test? (
+ >=dev-python/pytest-2.9.2[${PYTHON_USEDEP}]
+ >=dev-python/pytest-cov-2.3.0[${PYTHON_USEDEP}]
+ >=dev-python/pytest-xdist-1.14.0[${PYTHON_USEDEP}]
+ >=dev-python/hypothesis-3.4.2[${PYTHON_USEDEP}]
+ )
+"
+
+python_prepare_all() {
+ # Remove a test that is not part of the mainstream tests
+ # Also, it's data directory is not included in the release
+ rm test/test_hpack_integration.py || die
+ distutils-r1_python_prepare_all
+}
+
+python_test() {
+ PYTHONPATH="${S}/test:${BUILD_DIR}/lib" \
+ py.test -v hpack test/|| die
+ cd test
+}
diff --git a/dev-python/hpack/hpack-3.0.0.ebuild b/dev-python/hpack/hpack-3.0.0.ebuild
new file mode 100644
index 000000000000..3a62a22097ce
--- /dev/null
+++ b/dev-python/hpack/hpack-3.0.0.ebuild
@@ -0,0 +1,42 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 python3_{6,7,8,9})
+
+inherit distutils-r1
+
+DESCRIPTION="Pure-Python HPACK header compression"
+HOMEPAGE="https://python-hyper.org/hpack/en/latest/ https://pypi.org/project/hpack/"
+SRC_URI="https://github.com/python-hyper/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~mips ppc ppc64 s390 sparc x86"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND=""
+# dev-python/pytest-relaxed causes tests to fail
+DEPEND="${RDEPEND}
+ test? (
+ >=dev-python/pytest-2.9.2[${PYTHON_USEDEP}]
+ >=dev-python/hypothesis-3.4.2[${PYTHON_USEDEP}]
+ !!dev-python/pytest-relaxed[${PYTHON_USEDEP}]
+ )
+"
+
+PATCHES=(
+ "${FILESDIR}"/hpack-3.0.0-hypothesis-healthcheck.patch
+)
+
+python_prepare_all() {
+ # Remove a test that is not part of the mainstream tests
+ # Also, it's data directory is not included in the release
+ rm test/test_hpack_integration.py || die
+ distutils-r1_python_prepare_all
+}
+
+python_test() {
+ pytest -vv hpack test || die "Tests fail with ${EPYTHON}"
+}
diff --git a/dev-python/hpack/metadata.xml b/dev-python/hpack/metadata.xml
new file mode 100644
index 000000000000..6bb152eaf706
--- /dev/null
+++ b/dev-python/hpack/metadata.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>python@gentoo.org</email>
+ <name>Python</name>
+ </maintainer>
+ <upstream>
+ <maintainer>
+ <email>cory@lukasa.co.uk</email>
+ <name>Cory Benfield</name>
+ </maintainer>
+ <remote-id type="pypi">hpack</remote-id>
+ </upstream>
+ <longdescription>This module contains a pure-Python HTTP/2 header encoding
+ (HPACK) logic for use in Python programs that implement HTTP/2. It
+ also contains a compatibility layer that automatically enables the use
+ of nghttp2 if it’s available.
+ </longdescription>
+ <origin>gentoo-staging</origin>
+</pkgmetadata>