Date: Thursday, September 1, 2022 @ 10:37:42 Author: dvzrv Revision: 1290110
upgpkg: python-cachecontrol 1:0.12.11-1: Upgrade to 0.12.11. Remove unnecesary quotes and curly braces. Add python-redis to checkdepends and optdepends. Remove unnecessary patch. Switch to PEP517. Update maintainer info. Modified: python-cachecontrol/trunk/PKGBUILD Deleted: python-cachecontrol/trunk/0001-Remove-unnecessary-console-script.patch ----------------------------------------------+ 0001-Remove-unnecessary-console-script.patch | 26 ---------- PKGBUILD | 60 ++++++++++++------------- 2 files changed, 30 insertions(+), 56 deletions(-) Deleted: 0001-Remove-unnecessary-console-script.patch =================================================================== --- 0001-Remove-unnecessary-console-script.patch 2022-09-01 10:35:57 UTC (rev 1290109) +++ 0001-Remove-unnecessary-console-script.patch 2022-09-01 10:37:42 UTC (rev 1290110) @@ -1,26 +0,0 @@ -From 5949227996ba403eecaf6fb961c2f2a6aca4d3e2 Mon Sep 17 00:00:00 2001 -From: Eli Schwartz <[email protected]> -Date: Thu, 7 Jun 2018 12:39:59 -0400 -Subject: [PATCH] Remove unnecessary console script - -The purpose of this module is to cache things, not to test if they -*can* be cached. This clutters up the $PATH. ---- - setup.py | 1 - - 1 file changed, 1 deletion(-) - -diff --git a/setup.py b/setup.py -index 34f5f44..95e1741 100644 ---- a/setup.py -+++ b/setup.py -@@ -19,7 +19,6 @@ setup_params = dict( - long_description=long_description, - install_requires=["requests", "msgpack"], - extras_require={"filecache": ["lockfile>=0.9"], "redis": ["redis>=2.10.5"]}, -- entry_points={"console_scripts": ["doesitcache = cachecontrol._cmd:main"]}, - python_requires=">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*", - classifiers=[ - "Development Status :: 4 - Beta", --- -2.17.1 - Modified: PKGBUILD =================================================================== --- PKGBUILD 2022-09-01 10:35:57 UTC (rev 1290109) +++ PKGBUILD 2022-09-01 10:37:42 UTC (rev 1290110) @@ -1,44 +1,44 @@ -# Maintainer: Eli Schwartz <[email protected]> +# Maintainer: David Runge <[email protected]> +# Contributor: Eli Schwartz <[email protected]> -_pkgname=cachecontrol +_name=cachecontrol pkgname=python-cachecontrol -# Before bumping, watch out for: -# https://github.com/ionrock/cachecontrol/issues/262 -pkgver=0.12.6 -pkgrel=4 +pkgver=0.12.11 +pkgrel=1 epoch=1 pkgdesc="httplib2 caching for requests" -arch=('any') -url="https://github.com/ionrock/${_pkgname}" -license=('Apache') -depends=('python-msgpack' 'python-requests') -makedepends=('python-setuptools') -checkdepends=('python-mock' 'python-pytest' 'python-lockfile' 'python-cherrypy') -optdepends=('python-lockfile: for the FileCache') -source=("${_pkgname}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz" - "0001-Remove-unnecessary-console-script.patch") -sha256sums=('2ec120838f445bff473cd8b8206ddae3650679142976927179743fabb876f3e3' - 'a2c93d4852887152027140bdd54030d5363876b02e5eabee6a018d4e946a87b1') +arch=(any) +url="https://github.com/ionrock/${_name}" +license=(Apache) +depends=(python-msgpack python-requests) +makedepends=(python-build python-installer python-setuptools python-wheel) +checkdepends=(python-cherrypy python-lockfile python-mock python-pytest python-redis) +optdepends=( + 'python-lockfile: for filecache' + 'python-redis: for redis cache' +) +# not tests in dist tarball on pypi.org: https://github.com/ionrock/cachecontrol/issues/281 +# source=(https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz) +source=($_name-$pkgver.tar.gz::https://github.com/ionrock/$_name/archive/refs/tags/v$pkgver.tar.gz) +sha256sums=('06f9ad43ed6bb9ed23883fda838bacada949a00dc557e7f41aecbd19787efdcf') +b2sums=('09ce2336216b69dbe9796d658db9f5b0d378259484cba3a78ecd789843e19683adc2b1b90d579cea8700d07ed55a93ecc3a56e5da2c8ab025e5084d2847d4dbf') -prepare() { - cd "${srcdir}"/${_pkgname}-${pkgver} - - patch -p1 -i ../0001-Remove-unnecessary-console-script.patch -} - build() { - cd "${srcdir}"/${_pkgname}-${pkgver} - - python setup.py build + cd $_name-$pkgver + python -m build --wheel --no-isolation } check() { - cd "${srcdir}"/${_pkgname}-${pkgver} + local _site_packages=$(python -c "import site; print(site.getsitepackages()[0])") - python -m pytest + cd $_name-$pkgver + python -m installer --destdir=test_dir dist/*.whl + export PYTHONPATH="test_dir/$_site_packages:$PYTHONPATH" + pytest -vv } package() { - cd "${srcdir}"/${_pkgname}-${pkgver} - python setup.py install --root="${pkgdir}" --optimize=1 --skip-build + cd $_name-$pkgver + python -m installer --destdir="$pkgdir" dist/*.whl + install -vDm 644 README.rst -t "$pkgdir/usr/share/doc/$pkgname/" }
