diff options
Diffstat (limited to 'community/py3-aiohttp/APKBUILD')
-rw-r--r-- | community/py3-aiohttp/APKBUILD | 87 |
1 files changed, 73 insertions, 14 deletions
diff --git a/community/py3-aiohttp/APKBUILD b/community/py3-aiohttp/APKBUILD index ca5d4e2447e..7e8acdf842a 100644 --- a/community/py3-aiohttp/APKBUILD +++ b/community/py3-aiohttp/APKBUILD @@ -2,31 +2,90 @@ # Maintainer: Francesco Colista <fcolista@alpinelinux.org> pkgname=py3-aiohttp _pkgname=aiohttp -pkgver=3.7.4 -pkgrel=2 +pkgver=3.9.3 +pkgrel=0 pkgdesc="HTTP client/server for asyncio" -url="https://pypi.python.org/pypi/aiohttp" +url="https://pypi.org/project/aiohttp" arch="all" license="Apache-2.0" -depends="python3 py3-async-timeout py3-chardet py3-multidict py3-yarl - py3-idna-ssl py3-attrs py3-typing-extensions" -makedepends="python3-dev py3-setuptools" -subpackages="$pkgname-dev" -source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz - 0001-bump-chardet-from-3.0.4-to-4.0.0.patch +depends=" + py3-aiosignal + py3-async-timeout + py3-attrs + py3-brotli + py3-charset-normalizer + py3-idna-ssl + py3-multidict + py3-typing-extensions + py3-yarl + python3 " +makedepends=" + python3-dev + py3-gpep517 + py3-setuptools + py3-wheel + " +checkdepends=" + py3-async_generator + py3-freezegun + py3-gunicorn + py3-pytest + py3-pytest-cov + py3-pytest-mock + py3-re-assert + " +subpackages="$pkgname-pyc" +source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz" builddir="$srcdir/$_pkgname-$pkgver" +case "$CARCH" in +s390x) + # fails due to speed and the event loop closes + options="$options !check" + ;; +esac + +# secfixes: +# 3.9.3-r0: +# - CVE-2024-23334 +# - CVE-2024-23829 + build() { - python3 setup.py build + gpep517 build-wheel \ + --wheel-dir .dist \ + --output-fd 3 3>&1 >&2 } check() { - python3 setup.py check + # requires https://github.com/abhinavsingh/proxy.py + local ignore="--ignore tests/test_proxy_functional.py" + + # requires python_on_whales and a docker service running + ignore="$ignore --ignore tests/autobahn/test_autobahn.py" + + local k='not test_no_warnings and not test_request_tracing_url_params' + + # requires network/DNS + k="$k and not test_client_session_timeout" + + # https://github.com/aio-libs/aiohttp/issues/8234 + k="$k and not test_aiohttp_plugin" + + # known to be flaky on slower machines + # https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/62488#note_386063 + k="$k and not test_import_time" + + PYTHONPATH="$(echo build/lib.*)" \ + pytest -W ignore::DeprecationWarning -v --no-cov -k "$k" \ + $ignore } package() { - python3 setup.py install --root="$pkgdir" --optimize=1 + python3 -m installer -d "$pkgdir" \ + .dist/*.whl } -sha512sums="66fcc837b388020dc998cbaa2db31e48ecec75bcfaa8af9108e2ea265588dafa5684ca96a8fe3ad6759b22e09a4ae6d4efd8653fb76126eccdc826c15cbbe2e6 py3-aiohttp-3.7.4.tar.gz -4a53179cec15aeafa4eea68d1a9b1762c96a876391610c5553f31057ab1ded1f27ea75f896ca2f5c29b6673b56f32627aaef79ada78cb30812c9d73642a16e71 0001-bump-chardet-from-3.0.4-to-4.0.0.patch" + +sha512sums=" +6236f27b6def0c3bba1b5fc59f4af74f8076aa369cf5c1b9bd9ff9dee1c71ee49387ded812875da9450130e92d2091fd01f0608b25b03ff37e99162b89120fd7 py3-aiohttp-3.9.3.tar.gz +" |