15
0

- disable django support on SLE15 also

* Fix peek when value is so large that a file is used
  * Support pathlib.Path as directory argument

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-diskcache?expand=0&rev=31
This commit is contained in:
2025-07-05 14:54:02 +00:00
committed by Git OBS Bridge
commit f77d20dd52
5 changed files with 223 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
.osc

BIN
diskcache-5.6.3.tar.gz LFS Normal file

Binary file not shown.

112
python-diskcache.changes Normal file
View File

@@ -0,0 +1,112 @@
-------------------------------------------------------------------
Sat Jul 5 14:53:34 UTC 2025 - Dirk Müller <dmueller@suse.com>
- disable django support on SLE15 also
-------------------------------------------------------------------
Thu Jun 5 06:01:37 UTC 2025 - Steve Kowalik <steven.kowalik@suse.com>
- Switch to pyproject macros.
-------------------------------------------------------------------
Tue Oct 1 10:19:39 UTC 2024 - Daniel Garcia <daniel.garcia@suse.com>
- Make Django build-requirement conditional and disable by default for
SUSE:SLFO:Main, bsc#1231124
-------------------------------------------------------------------
Wed Sep 27 12:15:19 UTC 2023 - ecsos <ecsos@opensuse.org>
- Add %{?sle15_python_module_pythons}
-------------------------------------------------------------------
Mon Sep 4 15:58:51 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 5.6.3:
* Fix peek when value is so large that a file is used
-------------------------------------------------------------------
Wed Apr 26 06:24:33 UTC 2023 - Dirk Müller <dmueller@suse.com>
- update to 5.6.1
* Close the cache explictly before deleting the reference
* pylint fixes
* Add maxlen parameter to diskcache.Deque
* update docs
* Support pathlib.Path as directory argument
-------------------------------------------------------------------
Sat Jan 15 17:42:10 UTC 2022 - Dirk Müller <dmueller@suse.com>
- update to 5.4.0:
* test django 3.2
* Fix DjangoCache.delete to return True/False
* remove unused imports
* run isort
-------------------------------------------------------------------
Mon Dec 27 13:20:49 UTC 2021 - Ben Greiner <code@bnavigator.de>
- Update to 5.3.0
* Support for Python 3.10 in testing (#238)
* Add support for Python 3.10
* Update copyright to 2022
* Bump version to 5.3.0
* Add Python 3.10 to the README
- Avoid django test collections errors on python 3.6:#
no python36-Django 4
- Keep ignoring djangocache tests due to
gh#grantjenks/python-diskcache#210
-------------------------------------------------------------------
Tue Nov 17 05:43:53 UTC 2020 - Steve Kowalik <steven.kowalik@suse.com>
- Update to 5.1.0:
* Support transactions in FanoutCache (probably a bad idea)
* Prevent cache shard attribute access when unsafe
-------------------------------------------------------------------
Thu Sep 17 11:24:06 UTC 2020 - Dirk Mueller <dmueller@suse.com>
- update to 5.0.3:
* drop python 2.7 support
* python 3.8 fixes
* add documentation about cache volume caveats
-------------------------------------------------------------------
Thu Feb 27 05:15:40 UTC 2020 - Steve Kowalik <steven.kowalik@suse.com>
- Update to 4.1.0:
* Move zero-expiration logic into memoize (rather than Cache.set)
* Provide JSONDisk with diskcache (#124)
* Add check for DEFAULT_TIMEOUT in DjangoCache.memoize
-------------------------------------------------------------------
Thu Nov 14 15:10:00 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to pull in full python due to the dependencies
-------------------------------------------------------------------
Thu Jul 25 10:52:27 UTC 2019 - pgajdos@suse.com
- version update to 4.0.0
* no upstream changelog
-------------------------------------------------------------------
Fri Mar 8 13:19:48 UTC 2019 - Tomáš Chvátal <tchvatal@suse.com>
- Update to 3.1.1:
* Fix various timeouts
* Small fixes around
-------------------------------------------------------------------
Sun Jun 10 10:24:35 UTC 2018 - jengelh@inai.de
- Remove metadata redundancies from description.
-------------------------------------------------------------------
Fri Jun 8 13:51:38 UTC 2018 - petr@cervinka.net
- Initial package version
- Django related tests are excluded from python3 tests. Tests are made for Django1
only. Django1 is for python2 only in distribution.

84
python-diskcache.spec Normal file
View File

@@ -0,0 +1,84 @@
#
# spec file for package python-diskcache
#
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%if 0%{?suse_version} == 1600 || 0%{?suse_version} == 1500
# No django in SLFO:Main or SLE15
%bcond_with django
%else
%bcond_without django
%endif
%{?sle15_python_module_pythons}
Name: python-diskcache
Version: 5.6.3
Release: 0
Summary: Disk and file backed cache
License: Apache-2.0
URL: https://grantjenks.com/docs/diskcache/
Source: https://github.com/grantjenks/python-diskcache/archive/v%{version}.tar.gz#/diskcache-%{version}.tar.gz
BuildRequires: %{python_module pip}
BuildRequires: %{python_module pytest-xdist}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module wheel}
BuildRequires: %{pythons}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
%if %{with django}
BuildRequires: %{python_module Django}
BuildRequires: %{python_module pytest-django}
%endif
Requires: python
BuildArch: noarch
%python_subpackages
%description
DiskCache: Disk Backed Cache
DiskCache is a disk and file backed cache library, written
in pure Python, and compatible with Django.
%prep
%setup -q
sed -i '/--cov/d' tox.ini
%build
%pyproject_wheel
%install
%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
%if %{without django}
python_flags=("--ignore" "tests/test_doctest.py" "-k" "not README.rst")
%else
# No python36-Django 4 on TW
python36_flags=("--ignore" "tests/test_doctest.py" "-k" "not README.rst")
%endif
# Broken since Django 3.2 -- https://github.com/grantjenks/python-diskcache/issues/210
donttest_djangocache="--ignore tests/test_djangocache.py"
%pytest "${$python_flags[@]}" "${python_flags[@]}" ${donttest_djangocache}
%files %{python_files}
%license LICENSE
%doc README.rst
%{python_sitelib}/diskcache
%{python_sitelib}/diskcache-%{version}*-info
%changelog