blob: 7493e81f642c3eb295a60f850945de9316a7b352 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
# Maintainer: envolution
# Contributor: Carl Smedstad <carsme@archlinux.org>
# Contributor: AngrySoft - Sebastian Zwierzchowski
# shellcheck shell=bash disable=SC2034,SC2154
pkgname=python-sse-starlette
_pkgname=${pkgname#python-}
pkgver=2.2.1
pkgrel=3
pkgdesc="Server Sent Events (SSE) for Starlette and FastAPI"
arch=(any)
url="https://github.com/sysid/sse-starlette"
license=(BSD-3-Clause)
depends=(
python
uvicorn
python-anyio
python-starlette
)
makedepends=(
python-build
python-installer
python-setuptools
python-pdm-backend
python-wheel
)
checkdepends=(
python-async-timeout
python-asgi-lifespan
python-fastapi
python-httpx
python-psutil
python-pytest
python-pytest-asyncio
python-portend
)
source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz")
sha256sums=('3f069376789418b98c28a6a1d7c94636380caadc2cb8cd62dc032718a117c457')
build() {
cd "$_pkgname-$pkgver"
python -m build --wheel --no-isolation
}
check() {
# rm -rf test-env
# python -m venv --system-site-packages test-env
# test-env/bin/python -m installer "$_pkgname-$pkgver"/dist/*.whl
# test-env/bin/python -m pytest "$_pkgname-$pkgver"/tests -k "not test_sse_multiple_consumers" --ignore=tests/integration/test_multiple_consumers.py
echo "Skipping tests until they start to behave"
}
package() {
cd "$_pkgname-$pkgver"
python -m installer --destdir="$pkgdir" dist/*.whl
install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE
}
# vim:set ts=2 sw=2 et:
|