From 7788dfc206776c0ccda4b431124a55fb9f11be74 Mon Sep 17 00:00:00 2001 From: Celeste <20312-Celeste@users.gitlab.alpinelinux.org> Date: Tue, 5 Dec 2023 04:56:38 +0000 Subject: [PATCH] community/py3-freezegun: upgrade to 1.3.1 also, fix lint warnings by not using $_pyname in source --- community/py3-freezegun/APKBUILD | 11 +++----- .../python3.10-staticmethods.patch | 26 ------------------- 2 files changed, 4 insertions(+), 33 deletions(-) delete mode 100644 community/py3-freezegun/python3.10-staticmethods.patch diff --git a/community/py3-freezegun/APKBUILD b/community/py3-freezegun/APKBUILD index 15dc0161cc24..53ef9abf1699 100644 --- a/community/py3-freezegun/APKBUILD +++ b/community/py3-freezegun/APKBUILD @@ -2,8 +2,8 @@ # Maintainer: Robert Sacks <robert@sacks.email> pkgname=py3-freezegun _pyname=freezegun -pkgver=1.2.2 -pkgrel=3 +pkgver=1.3.1 +pkgrel=0 pkgdesc="Let your Python tests travel through time" url="https://github.com/spulec/freezegun" arch="noarch" @@ -12,9 +12,7 @@ depends="python3 py3-dateutil" makedepends="py3-gpep517 py3-setuptools py3-wheel" checkdepends="py3-mock py3-pytest py3-pytest-cov" subpackages="$pkgname-pyc" -source="https://files.pythonhosted.org/packages/source/${_pyname%${_pyname#?}}/$_pyname/$_pyname-$pkgver.tar.gz - python3.10-staticmethods.patch - " +source="https://files.pythonhosted.org/packages/source/f/freezegun/freezegun-$pkgver.tar.gz" builddir="$srcdir/$_pyname-$pkgver" build() { @@ -33,6 +31,5 @@ package() { } sha512sums=" -c6dc3da66a2d3063f819a104b6bc98eb3d4b772b8edb06bde130a6e355d96e1861e650c44eb691be892223150a652a528fda4237bd77b1bdcee1fcfad74f307c freezegun-1.2.2.tar.gz -fcb6a561ace557aa0292fdb8e680042ab35fa21200c5449c142e67f184f165e946d0e4ffcf74ea26bd838103574d07151db6abf68dabaf07bc40c72520937bb4 python3.10-staticmethods.patch +7524c85ad4d49fdf86d132085845ec9c67d06600cfa25e0d650cc0a565d1830f9f83315930fd6516ae924c2395721473a04c1ecfeb1735ee31e894370267ef95 freezegun-1.3.1.tar.gz " diff --git a/community/py3-freezegun/python3.10-staticmethods.patch b/community/py3-freezegun/python3.10-staticmethods.patch deleted file mode 100644 index f89e6deec8f1..000000000000 --- a/community/py3-freezegun/python3.10-staticmethods.patch +++ /dev/null @@ -1,26 +0,0 @@ -From e63874ce75a74a1159390914045fe8e7955b24c4 Mon Sep 17 00:00:00 2001 -From: Karthikeyan Singaravelan <tir.karthi@gmail.com> -Date: Fri, 7 May 2021 15:51:33 +0000 -Subject: [PATCH] Fix decorate_class for Python 3.10 where staticmethod is - callable. - ---- - freezegun/api.py | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) - -diff --git a/freezegun/api.py b/freezegun/api.py -index cab9ebe..55a80c7 100644 ---- a/freezegun/api.py -+++ b/freezegun/api.py -@@ -598,7 +598,10 @@ def tearDownClass(cls): - continue - seen.add(attr) - -- if not callable(attr_value) or inspect.isclass(attr_value): -+ # staticmethods are callable from Python 3.10 . Hence skip them from decoration -+ if (not callable(attr_value) -+ or inspect.isclass(attr_value) -+ or isinstance(attr_value, staticmethod)): - continue - - try: -- GitLab