From a5474d44a2fe4078517b83694c155578227253d6 Mon Sep 17 00:00:00 2001 From: OscarL Date: Thu, 13 Mar 2025 02:27:05 -0300 Subject: [PATCH] freezegun: drop outdated and unused recipe. (#11935) Never used on-tree since introduced (b573859b386d37a5f37add29f191815e49e716b4). Users should try to `pip install` this, if they need it. --- dev-python/freezegun/freezegun-1.2.2.recipe | 77 --------------------- dev-python/freezegun/patches/397.patch | 26 ------- 2 files changed, 103 deletions(-) delete mode 100644 dev-python/freezegun/freezegun-1.2.2.recipe delete mode 100644 dev-python/freezegun/patches/397.patch diff --git a/dev-python/freezegun/freezegun-1.2.2.recipe b/dev-python/freezegun/freezegun-1.2.2.recipe deleted file mode 100644 index 58d183b1c..000000000 --- a/dev-python/freezegun/freezegun-1.2.2.recipe +++ /dev/null @@ -1,77 +0,0 @@ -SUMMARY="Let your Python tests travel through time" -DESCRIPTION="FreezeGun is a library that allows your Python tests to travel through time by \ -mocking the datetime module." -HOMEPAGE="https://github.com/spulec/freezegun" -COPYRIGHT="2023 Steve Pulec" -LICENSE="Apache v2" -REVISION="1" -SOURCE_URI="https://pypi.python.org/packages/source/f/$portName/$portName-$portVersion.tar.gz" -CHECKSUM_SHA256="cd22d1ba06941384410cd967d8a99d5ae2442f57dfafeff2fda5de8dc5c05446" -PATCHES="397.patch" # from upstream - -ARCHITECTURES="any" - -PROVIDES=" - $portName = $portVersion - " -REQUIRES=" - haiku - " - -BUILD_REQUIRES=" - haiku_devel - " - -PYTHON_PACKAGES=(python39 python310) -PYTHON_VERSIONS=(3.9 3.10) -defaultTestVersion="python39" -for i in "${!PYTHON_PACKAGES[@]}"; do - pythonPackage=${PYTHON_PACKAGES[i]} - pythonVersion=${PYTHON_VERSIONS[$i]} - - eval "PROVIDES_$pythonPackage=\" - ${portName}_$pythonPackage = $portVersion - \"" - eval "REQUIRES_$pythonPackage=\" - haiku - dateutil_$pythonPackage - cmd:python$pythonVersion - \"" - BUILD_REQUIRES+=" - setuptools_$pythonPackage - " - BUILD_PREREQUIRES+=" - cmd:python$pythonVersion - " -done - -TEST_REQUIRES=" - dateutil_$defaultTestVersion - cmd:pytest - " - -INSTALL() -{ - for i in "${!PYTHON_PACKAGES[@]}"; do - pythonPackage=${PYTHON_PACKAGES[i]} - pythonVersion=${PYTHON_VERSIONS[$i]} - - python=python$pythonVersion - installLocation=$prefix/lib/$python/vendor-packages/ - export PYTHONPATH=$installLocation:$PYTHONPATH - - mkdir -p $installLocation - rm -rf build - - $python setup.py build install \ - --root=/ --prefix=$prefix - - packageEntries $pythonPackage \ - $prefix/lib/python* - done -} - -TEST() -{ - pytest -v -} diff --git a/dev-python/freezegun/patches/397.patch b/dev-python/freezegun/patches/397.patch deleted file mode 100644 index 53f67f32e..000000000 --- a/dev-python/freezegun/patches/397.patch +++ /dev/null @@ -1,26 +0,0 @@ -From e63874ce75a74a1159390914045fe8e7955b24c4 Mon Sep 17 00:00:00 2001 -From: Karthikeyan Singaravelan -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: