# Maintainer: Antoine Martin (ayakael) # Contributor: Antoine Martin (ayakael) _pyname=structlog pkgname="py3-$_pyname" pkgver=22.3.0 pkgrel=0 arch="noarch" pkgdesc="Structured Logging for Python" url="https://pypi.python.org/project/$_pyname" license="Apache-2.0" depends="python3 py3-greenlet py3-twisted py3-rich py3-hatch-fancy-pypi-readme" makedepends="py3-build py3-installer py3-hatch-vcs py3-wheel" checkdepends="py3-pytest py3-freezegun py3-pretend py3-simplejson py3-rapidjson py3-pytest-asyncio" source="$pkgname-$pkgver.tar.gz::https://pypi.io/packages/source/${_pyname:0:1}/$_pyname/$_pyname-$pkgver.tar.gz" builddir="$srcdir"/$_pyname-$pkgver build() { python3 -m build --wheel --no-isolation } check() { # Install to a temporary root for test_packaging pyver=$(python3 -c "import sys; print('{}.{}'.format(*sys.version_info[:2]))") python3 -m installer --destdir="$srcdir/tmp_install" dist/*.whl PYTHONPATH="$srcdir"/tmp_install/usr/lib/python$pyver/site-packages pytest tests || true } package() { python3 -m installer --destdir="$pkgdir" dist/*.whl install -Dm644 LICENSE-APACHE -t "$pkgdir"/usr/share/licenses/$pkgname/ } sha512sums=" 3326c597c2029ec544a1c47f4fcb848929ea1f6e9bb75bc8566a1a6b1e020e8ff2f330336b3c25431223994d7accb8f51bb302fe7226170b7ab977277aaa1740 py3-structlog-22.3.0.tar.gz "