[arch-commits] Commit in python-falcon/trunk (PKGBUILD)

David Runge dvzrv at gemini.archlinux.org
Mon Apr 4 19:12:07 UTC 2022


    Date: Monday, April 4, 2022 @ 19:12:07
  Author: dvzrv
Revision: 1181374

upgpkg: python-falcon 3.1.0-1: Upgrade to 3.1.0.

Remove unneeded quotes and curly braces.
Switch to github tarball as the sdist tarball does not contain all files for testing.
Switch to PEP517.

Modified:
  python-falcon/trunk/PKGBUILD

----------+
 PKGBUILD |   65 ++++++++++++++++++++++++++++++-------------------------------
 1 file changed, 32 insertions(+), 33 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2022-04-04 18:54:11 UTC (rev 1181373)
+++ PKGBUILD	2022-04-04 19:12:07 UTC (rev 1181374)
@@ -2,50 +2,49 @@
 
 _name=falcon
 pkgname=python-falcon
-pkgver=3.0.1
-pkgrel=3
-pkgdesc="Web API framework for building fast and reliable microservices, proxies, and app backends in Python"
-arch=('x86_64')
+pkgver=3.1.0
+pkgrel=1
+pkgdesc="Web API framework for fast and reliable microservices, proxies, and app backends"
+arch=(x86_64)
 url="https://falconframework.org/"
-license=('Apache')
-depends=('python')
-makedepends=('cython' 'python-setuptools')
+license=(Apache)
+depends=(python)
+makedepends=(cython python-build python-installer python-setuptools python-wheel)
 # TODO: add python-daphne
-checkdepends=('gunicorn' 'hypercorn' 'python-aiofiles' 'python-cbor2'
-'python-httpx' 'python-jsonschema' 'python-mimeparse' 'python-msgpack'
-'python-mujson' 'python-orjson' 'python-pecan' 'python-pytest'
-'python-pytest-asyncio' 'python-pytest-runner' 'python-rapidjson'
-'python-requests' 'python-testtools' 'python-ujson' 'python-websockets'
-'python-yaml' 'uvicorn')
-optdepends=('python-django: for falcon-bench'
-            'python-flask: for falcon-bench'
-            'python-pecan: for falcon-bench'
-            'python-bottle: for falcon-bench'
-            'python-pprofile: for falcon-bench'
-            'python-vmprof: for falcon-bench')
-source=("https://files.pythonhosted.org/packages/source/${_name::1}/${_name}/${_name}-${pkgver}.tar.gz")
-sha512sums=('c59c9868aad1536a6872790ca658b47546f64db02a3c5bcacce55d6091f2f29707bf052940b8dee530ddd19a99c286d6c18f31517a9c83417a550deab082026f')
-b2sums=('34325b756695eaa05eb05940c256cd663c652779e6c1070187b0638dc9572db19b6f29519366b40f96b4c03c6160407c926453c9f0ff3c9f5f47e0355c3c3ddd')
+checkdepends=(gunicorn hypercorn python-aiofiles python-cbor2 python-httpx
+python-jsonschema python-mimeparse python-msgpack python-mujson python-orjson
+python-pecan python-pytest python-pytest-asyncio python-pytest-runner
+python-rapidjson python-requests python-testtools python-ujson
+python-websockets python-yaml uvicorn)
+optdepends=(
+  'python-django: for falcon-bench'
+  'python-flask: for falcon-bench'
+  'python-pecan: for falcon-bench'
+  'python-bottle: for falcon-bench'
+  'python-pprofile: for falcon-bench'
+  'python-vmprof: for falcon-bench'
+)
+# not all required files for tests contained in pypi sdist tarball: https://github.com/falconry/falcon/issues/2051
+# source=(https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz)
+source=($_name-$pkgver.tar.gz::https://github.com/falconry/$_name/archive/refs/tags/$pkgver.tar.gz)
+sha512sums=('9da76dd92dfce1611ef681588d8e0e2fc7e906b5c0bc4b60a4620e2e9907564783763b7776c9cc2ccb296116c985e527b2f429520a1c601567cf4eb15e98f8cc')
+b2sums=('183623c8d7e8b86ed9915cbf3757fd526f7f3a8a97ae5fdf86294bcc65052c5c827d4a920d93e9fa0198a8d255c7b56ecff465a36d9b0ea31581abd87d55ccd0')
 
-prepare() {
-  mv -v "${_name}-$pkgver" "$pkgname-$pkgver"
-}
-
 build() {
-  cd "$pkgname-$pkgver"
-  python setup.py build
+  cd $_name-$pkgver
+  python -m build --wheel --no-isolation
 }
 
 check() {
   local python_version=$(python -c 'import sys; print(".".join(map(str, sys.version_info[:2])))')
 
-  cd "$pkgname-$pkgver"
-  export PYTHONPATH="build/lib.linux-$CARCH-${python_version}:$PWD:${PYTHONPATH}"
+  cd $_name-$pkgver
+  export PYTHONPATH="build/lib.linux-$CARCH-$python_version:$PWD:$PYTHONPATH"
   pytest -v --ignore "tests/asgi/test_cythonized_asgi.py" tests
 }
 
 package() {
-  cd "$pkgname-$pkgver"
-  python setup.py install --optimize=1 --root="${pkgdir}"
-  install -vDm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
+  cd $_name-$pkgver
+  python -m installer --destdir="$pkgdir" dist/*.whl
+  install -vDm 644 README.rst -t "$pkgdir/usr/share/doc/$pkgname/"
 }



More information about the arch-commits mailing list