1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-15 04:05:15 +03:00
aports/community/py3-twilio/APKBUILD
2025-05-07 06:14:40 +00:00

62 lines
1.6 KiB
Text

# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
pkgname=py3-twilio
pkgver=9.6.0
pkgrel=0
arch="noarch"
pkgdesc="Twilio API client and TwiML generator"
url="https://pypi.python.org/project/twilio"
license="MIT"
depends="
py3-requests
py3-jwt
py3-aiohttp
py3-aiohttp-retry
"
makedepends="
py3-gpep517
py3-setuptools
py3-wheel
"
# missing py3-pyngrok, py3-autoflake, py3-recommonmark
checkdepends="
black
py3-sphinx
py3-mock
py3-pytest
py3-pytest-cov
py3-aiounittest
py3-flake8
py3-cryptography
py3-django
py3-multidict
"
subpackages="$pkgname-pyc"
_pyname=twilio-python
source="$pkgname-$pkgver.tar.gz::https://github.com/twilio/twilio-python/archive/refs/tags/$pkgver.tar.gz"
builddir="$srcdir"/$_pyname-$pkgver
build() {
gpep517 build-wheel \
--wheel-dir .dist \
--output-fd 3 3>&1 >&2
}
check() {
python3 -m venv --clear --without-pip --system-site-packages .testenv
.testenv/bin/python3 -m installer .dist/*.whl
# tests/cluster require Twilio API access
# test_request_retries_until_{max, success}:fails due to issue with latest release of py3-aiohttp-retry, see
# https://github.com/twilio/twilio-python/pull/819
.testenv/bin/python3 -m pytest -v --ignore=tests/cluster \
-k 'not test_request_retries_until_max and not test_request_retries_until_success'
}
package() {
python3 -m installer -d "$pkgdir" \
.dist/*.whl
}
sha512sums="
637634fa90b9f6bc2faa5e10472c903b84fcdcb9bb4bb7a73104f6d7b7adab9c762192deefa3ab087034863cc46f8e22618ca9a28f0a0cf4a2703d98abf7e84f py3-twilio-9.6.0.tar.gz
"