2025-03-08 13:12:02 +00:00

39 lines
1.1 KiB
Plaintext

# Contributor: Iztok Fister, Jr. <iztok@iztok-jr-fister.eu>
# Maintainer: Iztok Fister, Jr. <iztok@iztok-jr-fister.eu>
pkgname=py3-datapi
_pkgorig=datapi
pkgver=0.3.0
pkgrel=0
pkgdesc="ESEE Data Stores API Python Client"
url="https://github.com/ecmwf-projects/datapi"
arch="noarch"
license="Apache-2.0"
depends="py3-attrs py3-requests py3-tqdm py3-setuptools"
makedepends="py3-gpep517 py3-wheel"
checkdepends="py3-pytest-xdist"
subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/d/datapi/datapi-$pkgver.tar.gz"
builddir="$srcdir/$_pkgorig-$pkgver"
options="!check" # we need API key for test
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
.testenv/bin/python3 -m pytest -n auto
}
package() {
python3 -m installer -d "$pkgdir" \
.dist/*.whl
}
sha512sums="
df125ffc4d63cbe0499f3d454d268f2edc1107ccab9b01a39e3aeff05f32ca834471f5873f4aa6b38c00992fd97841784cb3c33cd05ae6bbace9027c4fd12e79 py3-datapi-0.3.0.tar.gz
"