- update to 5.1:

* Add support for Python 3.12.
- drop python312.patch (upstream)
- add python312.patch to build with python 3.12
  * Fix copying of PersistentList and PersistentMapping using copy.copy
  * Fix the Python implementation of the PickleCache to be able to
    store objects that cannot be weakly referenced.
  * Packaging-only release: get manylinux wheel built
  * Avoid raising a SystemError: error return without exception
    set when loading an object with slots whose jar generates an
  * Fix the hashcode of Python TimeStamp objects on 64-bit
    Python on Windows. See
  * Stop calling gc.collect every time PickleCache.incrgc is
    called (every transaction boundary) in pure-Python mode (PyPy).
    This means that the reported size of the cache may be wrong
  * Stop clearing the dict and slots of objects added to
    PickleCache.new_ghost (typically these values are passed to
  * Fix __setstate__ interning when state parameter is not a
  * Drop use of ctypes for determining maximum integer size, to
    increase pure-Python compatibility. See
  * Ensure that __slots__ attributes are cleared when a
    override __new__. See
  * Fix the hashcode of C TimeStamp objects on 64-bit Python 3
  * Fixed the Python(/PYPY) implementation TimeStamp.timeTime
  * When testing PURE_PYTHON environments under tox, avoid
  * Fix manifest and re-upload to fix stray files included in
  * Make the Python implementation of Persistent and PickleCache
    behave more similarly to the C implementation. In particular,
    the Python version can now run the complete ZODB and ZEO test

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-persistent?expand=0&rev=34
This commit is contained in:
Dirk Mueller 2024-01-07 20:16:55 +00:00 committed by Git OBS Bridge
parent a0cf5fa7c0
commit cdc4316ee6
5 changed files with 38 additions and 128 deletions

BIN
persistent-5.0.tar.gz (Stored with Git LFS)

Binary file not shown.

3
persistent-5.1.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:97ccc2fa26cc9bdcc3be1fc65aa4f4f28afe5204c2d4fd24a67445908db7469b
size 132854

View File

@ -1,7 +1,14 @@
-------------------------------------------------------------------
Sun Jan 7 20:15:51 UTC 2024 - Dirk Müller <dmueller@suse.com>
- update to 5.1:
* Add support for Python 3.12.
- drop python312.patch (upstream)
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Aug 14 21:52:43 UTC 2023 - Dirk Müller <dmueller@suse.com> Mon Aug 14 21:52:43 UTC 2023 - Dirk Müller <dmueller@suse.com>
- add python312.patch to build with python 3.12 - add python312.patch to build with python 3.12
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Jun 9 12:35:32 UTC 2023 - ecsos <ecsos@opensuse.org> Fri Jun 9 12:35:32 UTC 2023 - ecsos <ecsos@opensuse.org>
@ -85,12 +92,12 @@ Thu Mar 12 11:54:12 UTC 2020 - Marketa Calabkova <mcalabkova@suse.com>
- update to 4.6.1 - update to 4.6.1
* Stop installing C header files on PyPy * Stop installing C header files on PyPy
* Fix slicing of PersistentList to always return instances of the same class. * Fix slicing of PersistentList to always return instances of the same class.
* Fix copying of PersistentList and PersistentMapping using copy.copy * Fix copying of PersistentList and PersistentMapping using copy.copy
to also copy the underlying data object. to also copy the underlying data object.
* Update the handling of the PURE_PYTHON environment variable. * Update the handling of the PURE_PYTHON environment variable.
* Add preliminary support for Python 3.9a3+. * Add preliminary support for Python 3.9a3+.
* Fix the Python implementation of the PickleCache to be able to * Fix the Python implementation of the PickleCache to be able to
store objects that cannot be weakly referenced. store objects that cannot be weakly referenced.
* Add support for Python 3.8. * Add support for Python 3.8.
------------------------------------------------------------------- -------------------------------------------------------------------
@ -160,54 +167,54 @@ Sat Jun 24 11:10:40 UTC 2017 - aloisio@gmx.com
- Update to 4.2.4.2 - Update to 4.2.4.2
* Packaging-only release: fix Python 2.7 manylinux wheels. * Packaging-only release: fix Python 2.7 manylinux wheels.
4.2.4.1: 4.2.4.1:
* Packaging-only release: get manylinux wheel built * Packaging-only release: get manylinux wheel built
automatically. automatically.
4.2.4: 4.2.4:
* Avoid raising a SystemError: error return without exception * Avoid raising a SystemError: error return without exception
set when loading an object with slots whose jar generates an set when loading an object with slots whose jar generates an
exception (such as a ZODB POSKeyError) in setstate. exception (such as a ZODB POSKeyError) in setstate.
4.2.3: 4.2.3:
* Fix the hashcode of Python TimeStamp objects on 64-bit * Fix the hashcode of Python TimeStamp objects on 64-bit
Python on Windows. See Python on Windows. See
https://github.com/zopefoundation/persistent/pull/55 https://github.com/zopefoundation/persistent/pull/55
* Stop calling gc.collect every time PickleCache.incrgc is * Stop calling gc.collect every time PickleCache.incrgc is
called (every transaction boundary) in pure-Python mode (PyPy). called (every transaction boundary) in pure-Python mode (PyPy).
This means that the reported size of the cache may be wrong This means that the reported size of the cache may be wrong
(until the next GC), but it is much faster. This should not (until the next GC), but it is much faster. This should not
have any observable effects for user code. have any observable effects for user code.
* Stop clearing the dict and slots of objects added to * Stop clearing the dict and slots of objects added to
PickleCache.new_ghost (typically these values are passed to PickleCache.new_ghost (typically these values are passed to
__new__ from the pickle data) in pure-Python mode (PyPy). This __new__ from the pickle data) in pure-Python mode (PyPy). This
matches the behaviour of the C code. matches the behaviour of the C code.
* Add support for Python 3.6. * Add support for Python 3.6.
* Fix __setstate__ interning when state parameter is not a * Fix __setstate__ interning when state parameter is not a
built-in dict built-in dict
4.2.2: 4.2.2:
* Drop use of ctypes for determining maximum integer size, to * Drop use of ctypes for determining maximum integer size, to
increase pure-Python compatibility. See increase pure-Python compatibility. See
https://github.com/zopefoundation/persistent/pull/31 https://github.com/zopefoundation/persistent/pull/31
* Ensure that __slots__ attributes are cleared when a * Ensure that __slots__ attributes are cleared when a
persistent object is ghostified. (This excluses classes that persistent object is ghostified. (This excluses classes that
override __new__. See override __new__. See
https://github.com/zopefoundation/persistent/wiki/Notes_on_state_ https://github.com/zopefoundation/persistent/wiki/Notes_on_state_
new_and_slots if youre curious.) new_and_slots if youre curious.)
4.2.1: 4.2.1:
* Fix the hashcode of C TimeStamp objects on 64-bit Python 3 * Fix the hashcode of C TimeStamp objects on 64-bit Python 3
on Windows. on Windows.
4.2.0: 4.2.0:
* Fixed the Python(/PYPY) implementation TimeStamp.timeTime * Fixed the Python(/PYPY) implementation TimeStamp.timeTime
method to have subsecond precision. method to have subsecond precision.
* When testing PURE_PYTHON environments under tox, avoid * When testing PURE_PYTHON environments under tox, avoid
poisoning the users global wheel cache. poisoning the users global wheel cache.
* Add support for Python 3.5. * Add support for Python 3.5.
* Drop support for Python 2.6 and 3.2. * Drop support for Python 2.6 and 3.2.
4.1.1: 4.1.1:
* Fix manifest and re-upload to fix stray files included in * Fix manifest and re-upload to fix stray files included in
4.1.0. 4.1.0.
4.1.0: 4.1.0:
* Make the Python implementation of Persistent and PickleCache * Make the Python implementation of Persistent and PickleCache
behave more similarly to the C implementation. In particular, behave more similarly to the C implementation. In particular,
the Python version can now run the complete ZODB and ZEO test the Python version can now run the complete ZODB and ZEO test
suites. suites.
* Fix the hashcode of the Python TimeStamp on 32-bit platforms. * Fix the hashcode of the Python TimeStamp on 32-bit platforms.

View File

@ -1,7 +1,7 @@
# #
# spec file for package python-persistent # spec file for package python-persistent
# #
# Copyright (c) 2023 SUSE LLC # Copyright (c) 2024 SUSE LLC
# Copyright (c) 2013-2023 LISA GmbH, Bingen, Germany. # Copyright (c) 2013-2023 LISA GmbH, Bingen, Germany.
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
@ -19,13 +19,12 @@
%{?sle15_python_module_pythons} %{?sle15_python_module_pythons}
Name: python-persistent Name: python-persistent
Version: 5.0 Version: 5.1
Release: 0 Release: 0
Summary: Translucent persistent objects Summary: Translucent persistent objects
License: ZPL-2.1 License: ZPL-2.1
URL: https://github.com/zopefoundation/persistent URL: https://github.com/zopefoundation/persistent
Source: https://files.pythonhosted.org/packages/source/p/persistent/persistent-%{version}.tar.gz Source: https://files.pythonhosted.org/packages/source/p/persistent/persistent-%{version}.tar.gz
Patch1: python312.patch
BuildRequires: %{python_module cffi} BuildRequires: %{python_module cffi}
BuildRequires: %{python_module devel} BuildRequires: %{python_module devel}
BuildRequires: %{python_module manuel} BuildRequires: %{python_module manuel}

View File

@ -1,96 +0,0 @@
From 2195d2edd96ad209568cbaa8499eb87c2fb8fc4e Mon Sep 17 00:00:00 2001
From: Michael Howitz <mh@gocept.com>
Date: Thu, 30 Mar 2023 08:34:00 +0200
Subject: [PATCH] Add preliminary support for Python 3.12a6.
---
.github/workflows/tests.yml | 34 +++++++++++++++++++++---
.manylinux-install.sh | 11 ++++++--
.meta.toml | 4 +--
CHANGES.rst | 2 +-
appveyor.yml | 3 +++
setup.cfg | 2 +-
src/persistent/tests/test_persistence.py | 5 ----
src/persistent/tests/test_picklecache.py | 5 ----
tox.ini | 5 +++-
9 files changed, 50 insertions(+), 21 deletions(-)
Index: persistent-5.0/.manylinux-install.sh
===================================================================
--- persistent-5.0.orig/.manylinux-install.sh
+++ persistent-5.0/.manylinux-install.sh
@@ -28,6 +28,7 @@ yum -y install libffi-devel
tox_env_map() {
case $1 in
+ *"cp312"*) echo 'py312';;
*"cp37"*) echo 'py37';;
*"cp38"*) echo 'py38';;
*"cp39"*) echo 'py39';;
@@ -40,13 +41,19 @@ tox_env_map() {
# Compile wheels
for PYBIN in /opt/python/*/bin; do
if \
+ [[ "${PYBIN}" == *"cp312"* ]] || \
[[ "${PYBIN}" == *"cp311"* ]] || \
[[ "${PYBIN}" == *"cp37"* ]] || \
[[ "${PYBIN}" == *"cp38"* ]] || \
[[ "${PYBIN}" == *"cp39"* ]] || \
[[ "${PYBIN}" == *"cp310"* ]] ; then
- "${PYBIN}/pip" install -e /io/
- "${PYBIN}/pip" wheel /io/ -w wheelhouse/
+ if [[ "${PYBIN}" == *"cp312"* ]] ; then
+ "${PYBIN}/pip" install --pre -e /io/
+ "${PYBIN}/pip" wheel /io/ --pre -w wheelhouse/
+ else
+ "${PYBIN}/pip" install -e /io/
+ "${PYBIN}/pip" wheel /io/ -w wheelhouse/
+ fi
if [ `uname -m` == 'aarch64' ]; then
cd /io/
${PYBIN}/pip install tox
Index: persistent-5.0/setup.cfg
===================================================================
--- persistent-5.0.orig/setup.cfg
+++ persistent-5.0/setup.cfg
@@ -19,7 +19,7 @@ ignore =
force_single_line = True
combine_as_imports = True
sections = FUTURE,STDLIB,THIRDPARTY,ZOPE,FIRSTPARTY,LOCALFOLDER
-known_third_party = six, docutils, pkg_resources
+known_third_party = six, docutils, pkg_resources, pytz
known_zope =
known_first_party =
default_section = ZOPE
Index: persistent-5.0/src/persistent/tests/test_persistence.py
===================================================================
--- persistent-5.0.orig/src/persistent/tests/test_persistence.py
+++ persistent-5.0/src/persistent/tests/test_persistence.py
@@ -29,11 +29,6 @@ from collections import UserDict as Iter
class _Persistent_Base:
- # py2/3 compat
- assertRaisesRegex = getattr(unittest.TestCase,
- 'assertRaisesRegex',
- unittest.TestCase.assertRaisesRegexp)
-
def _getTargetClass(self):
# concrete testcase classes must override
raise NotImplementedError()
Index: persistent-5.0/src/persistent/tests/test_picklecache.py
===================================================================
--- persistent-5.0.orig/src/persistent/tests/test_picklecache.py
+++ persistent-5.0/src/persistent/tests/test_picklecache.py
@@ -60,11 +60,6 @@ def _len(seq):
class PickleCacheTestMixin:
- # py2/3 compat
- assertRaisesRegex = getattr(unittest.TestCase,
- 'assertRaisesRegex',
- unittest.TestCase.assertRaisesRegexp)
-
def _getTargetClass(self):
from persistent.picklecache import PickleCachePy as BasePickleCache
class PickleCache(BasePickleCache):