Hello community, here is the log from the commit of package python-zodbpickle for openSUSE:Leap:15.2 checked in at 2020-03-15 13:35:37 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Leap:15.2/python-zodbpickle (Old) and /work/SRC/openSUSE:Leap:15.2/.python-zodbpickle.new.3160 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-zodbpickle" Sun Mar 15 13:35:37 2020 rev:13 rq:783173 version:2.0.0 Changes: -------- --- /work/SRC/openSUSE:Leap:15.2/python-zodbpickle/python-zodbpickle.changes 2020-03-02 13:25:21.150636377 +0100 +++ /work/SRC/openSUSE:Leap:15.2/.python-zodbpickle.new.3160/python-zodbpickle.changes 2020-03-15 13:35:37.726811886 +0100 @@ -1,0 +2,12 @@ +Mon Mar 9 10:35:56 UTC 2020 - [email protected] + +- version update to 2.0.0 + - CPython 2: Make ``zodbpickle.binary`` objects smaller and untracked + by the garbage collector. Now they behave more like the native bytes + object. Just like it, and just like on Python 3, they cannot have + arbitrary attributes or be weakly referenced. See `issue 53 + <https://github.com/zopefoundation/zodbpickle/issues/53>`_. + - Add support for Python 3.8. + - Drop support for Python 3.4. + +------------------------------------------------------------------- Old: ---- zodbpickle-1.0.4.tar.gz New: ---- zodbpickle-2.0.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-zodbpickle.spec ++++++ --- /var/tmp/diff_new_pack.UN2YHY/_old 2020-03-15 13:35:38.674812451 +0100 +++ /var/tmp/diff_new_pack.UN2YHY/_new 2020-03-15 13:35:38.722812480 +0100 @@ -1,7 +1,7 @@ # # spec file for package python-zodbpickle # -# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -18,7 +18,7 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-zodbpickle -Version: 1.0.4 +Version: 2.0.0 Release: 0 Summary: Fork of Python 3 pickle module License: Python-2.0 AND ZPL-2.1 ++++++ zodbpickle-1.0.4.tar.gz -> zodbpickle-2.0.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/.gitignore new/zodbpickle-2.0.0/.gitignore --- old/zodbpickle-1.0.4/.gitignore 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/.gitignore 1970-01-01 01:00:00.000000000 +0100 @@ -1,16 +0,0 @@ -*.egg-info -*.pyc -*.so -.coverage -.coverage.py* -.dir-locals.el -.installed.cfg -.tox -__pycache__ -bin -build -coverage.xml -develop-eggs -dist -htmlcov -parts diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/.manylinux-install.sh new/zodbpickle-2.0.0/.manylinux-install.sh --- old/zodbpickle-1.0.4/.manylinux-install.sh 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/.manylinux-install.sh 2019-11-13 13:40:47.000000000 +0100 @@ -5,10 +5,10 @@ # Compile wheels for PYBIN in /opt/python/*/bin; do if [[ "${PYBIN}" == *"cp27"* ]] || \ - [[ "${PYBIN}" == *"cp34"* ]] || \ [[ "${PYBIN}" == *"cp35"* ]] || \ [[ "${PYBIN}" == *"cp36"* ]] || \ - [[ "${PYBIN}" == *"cp37"* ]]; then + [[ "${PYBIN}" == *"cp37"* ]] || \ + [[ "${PYBIN}" == *"cp38"* ]]; then "${PYBIN}/pip" install -e /io/ "${PYBIN}/pip" wheel /io/ -w wheelhouse/ rm -rf /io/build /io/*.egg-info diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/.manylinux.sh new/zodbpickle-2.0.0/.manylinux.sh --- old/zodbpickle-1.0.4/.manylinux.sh 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/.manylinux.sh 2019-11-13 13:40:47.000000000 +0100 @@ -2,8 +2,4 @@ set -e -x -docker pull $DOCKER_IMAGE - -docker run --rm -v `pwd`:/io $DOCKER_IMAGE $PRE_CMD /io/.manylinux-install.sh - -pip install twine && twine upload -u zope.wheelbuilder -p $PYPIPASSWORD wheelhouse/* +docker run --rm -v "$(pwd)":/io $DOCKER_IMAGE $PRE_CMD /io/.manylinux-install.sh diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/.travis.yml new/zodbpickle-2.0.0/.travis.yml --- old/zodbpickle-1.0.4/.travis.yml 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/.travis.yml 1970-01-01 01:00:00.000000000 +0100 @@ -1,76 +0,0 @@ -language: python -sudo: false -python: - - 2.7 - - 3.4 - - 3.5 - - 3.6 - - pypy - - pypy3 -matrix: - include: - - python: 3.7 - dist: xenial - sudo: true - # It's important to use 'macpython' builds to get the least - # restrictive wheel tag. It's also important to avoid - # 'homebrew 3' because it floats instead of being a specific version. - - os: osx - language: generic - env: TERRYFY_PYTHON='macpython 2.7' - - os: osx - language: generic - env: TERRYFY_PYTHON='macpython 3.4' - - os: osx - language: generic - env: TERRYFY_PYTHON='macpython 3.5' - - os: osx - language: generic - env: TERRYFY_PYTHON='macpython 3.6.1' - - os: osx - language: generic - env: TERRYFY_PYTHON='macpython 3.7.0' - - services: - - docker - env: DOCKER_IMAGE=quay.io/pypa/manylinux1_x86_64 - before_install: - - if [[ $TRAVIS_TAG ]]; then bash .manylinux.sh; fi - - exit 0 - - services: - - docker - env: - - DOCKER_IMAGE=quay.io/pypa/manylinux1_i686 - - PRE_CMD=linux32 - before_install: - - if [[ $TRAVIS_TAG ]]; then bash .manylinux.sh; fi - - exit 0 -before_install: - - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then git clone https://github.com/MacPython/terryfy; fi - - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then source terryfy/travis_tools.sh; fi - - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then get_python_environment $TERRYFY_PYTHON venv; fi -install: - - pip install -U pip setuptools - - pip install -U coveralls coverage - - pip install . -script: - - coverage run setup.py test -q -notifications: - email: false -after_success: - - coveralls - - echo [distutils] > ~/.pypirc - - echo index-servers = pypi >> ~/.pypirc - - echo [pypi] >> ~/.pypirc - - echo username=zope.wheelbuilder >> ~/.pypirc - - echo password=$PYPIPASSWORD >> ~/.pypirc - - if [[ $TRAVIS_TAG && "$TRAVIS_OS_NAME" == "osx" ]]; then pip install twine; fi - - if [[ $TRAVIS_TAG && "$TRAVIS_OS_NAME" == "osx" ]]; then python setup.py bdist_wheel; fi - - if [[ $TRAVIS_TAG && "$TRAVIS_OS_NAME" == "osx" ]]; then twine upload dist/*; fi -env: - global: - secure: "edbJQIhe7grjaug7dxExoyB0zkrLca5IphzuQd2IfjGjBCY6Dn+QEBtDOMOcPjUsSvgxWL2XG2ZGIFF33bsoFlq0bZFPMtv5ZQ6jcpYQEpPX61fHsNzPs2RXavpHgHFC4aXt1o7jH7aSeImV98WWsNZTL5rhW4aHbgOM/jnnWdc=" - -cache: pip - -before_cache: - - rm -f $HOME/.cache/pip/log/debug.log diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/CHANGES.rst new/zodbpickle-2.0.0/CHANGES.rst --- old/zodbpickle-1.0.4/CHANGES.rst 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/CHANGES.rst 2019-11-13 13:40:47.000000000 +0100 @@ -2,6 +2,23 @@ Changelog =========== +2.0.0 (2019-11-13) +================== + +- CPython 2: Make ``zodbpickle.binary`` objects smaller and untracked + by the garbage collector. Now they behave more like the native bytes + object. Just like it, and just like on Python 3, they cannot have + arbitrary attributes or be weakly referenced. See `issue 53 + <https://github.com/zopefoundation/zodbpickle/issues/53>`_. + +1.1 (2019-11-09) +================ + +- Add support for Python 3.8. + +- Drop support for Python 3.4. + + 1.0.4 (2019-06-12) ================== diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/MANIFEST.in new/zodbpickle-2.0.0/MANIFEST.in --- old/zodbpickle-1.0.4/MANIFEST.in 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/MANIFEST.in 2019-11-13 13:40:47.000000000 +0100 @@ -8,9 +8,4 @@ include .coveragerc include *.sh -recursive-include src * - -global-exclude *.dll -global-exclude *.pyc -global-exclude *.pyo -global-exclude *.so +recursive-include src *.c diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/PKG-INFO new/zodbpickle-2.0.0/PKG-INFO --- old/zodbpickle-1.0.4/PKG-INFO 2019-06-12 07:56:00.000000000 +0200 +++ new/zodbpickle-2.0.0/PKG-INFO 2019-11-13 13:40:47.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: zodbpickle -Version: 1.0.4 +Version: 2.0.0 Summary: Fork of Python 2 and 3 pickle module. Home-page: https://github.com/zopefoundation/zodbpickle Author: Python and Zope Foundation @@ -177,6 +177,23 @@ Changelog =========== + 2.0.0 (2019-11-13) + ================== + + - CPython 2: Make ``zodbpickle.binary`` objects smaller and untracked + by the garbage collector. Now they behave more like the native bytes + object. Just like it, and just like on Python 3, they cannot have + arbitrary attributes or be weakly referenced. See `issue 53 + <https://github.com/zopefoundation/zodbpickle/issues/53>`_. + + 1.1 (2019-11-09) + ================ + + - Add support for Python 3.8. + + - Drop support for Python 3.4. + + 1.0.4 (2019-06-12) ================== @@ -344,10 +361,10 @@ Classifier: Programming Language :: Python :: 2 Classifier: Programming Language :: Python :: 2.7 Classifier: Programming Language :: Python :: 3 -Classifier: Programming Language :: Python :: 3.4 Classifier: Programming Language :: Python :: 3.5 Classifier: Programming Language :: Python :: 3.6 Classifier: Programming Language :: Python :: 3.7 +Classifier: Programming Language :: Python :: 3.8 Classifier: Programming Language :: Python :: Implementation :: CPython Classifier: Programming Language :: Python :: Implementation :: PyPy Classifier: Programming Language :: Python :: Implementation :: Jython @@ -358,4 +375,3 @@ Classifier: Operating System :: Unix Classifier: Operating System :: MacOS :: MacOS X Provides-Extra: test -Provides-Extra: testing diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/appveyor.yml new/zodbpickle-2.0.0/appveyor.yml --- old/zodbpickle-1.0.4/appveyor.yml 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/appveyor.yml 2019-11-13 13:40:47.000000000 +0100 @@ -7,17 +7,24 @@ matrix: - python: 27 - python: 27-x64 - - python: 34 - - python: 34-x64 - python: 35 - python: 35-x64 - python: 36 - python: 36-x64 - python: 37 - python: 37-x64 + - python: 38 + - python: 38-x64 install: - "SET PATH=C:\\Python%PYTHON%;c:\\Python%PYTHON%\\scripts;%PATH%" + - ps: | + $env:PYTHON = "C:\\Python${env:PYTHON}" + if (-not (Test-Path $env:PYTHON)) { + curl -o install_python.ps1 https://raw.githubusercontent.com/matthew-brett/multibuild/11a389d78892cf90addac8f69433d5e22bfa422a/install_python.ps1 + .\install_python.ps1 + } + - ps: if (-not (Test-Path $env:PYTHON)) { throw "No $env:PYTHON" } - echo "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd" /x64 > "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64\vcvars64.bat" - pip install -e . @@ -27,7 +34,7 @@ - python -W ignore setup.py -q bdist_wheel test_script: - - python setup.py test -q + - python setup.py -q test artifacts: - path: 'dist\*.whl' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/setup.py new/zodbpickle-2.0.0/setup.py --- old/zodbpickle-1.0.4/setup.py 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/setup.py 2019-11-13 13:40:47.000000000 +0100 @@ -19,9 +19,11 @@ from setuptools import Extension, find_packages, setup here = os.path.abspath(os.path.dirname(__file__)) -README = (open(os.path.join(here, 'README.rst')).read() - + '\n\n' + - open(os.path.join(here, 'CHANGES.rst')).read()) +def read(fname): + with open(os.path.join(here, fname)) as f: + return f.read() + +README = read('README.rst') + '\n\n' + read('CHANGES.rst') if sys.version_info[:1] < (3,): EXT = 'src/zodbpickle/_pickle_27.c' @@ -33,7 +35,7 @@ is_pypy = py_impl() == 'PyPy' is_jython = py_impl() == 'Jython' is_pure = 'PURE_PYTHON' in os.environ -if is_pypy or is_jython or is_pure: +if is_pypy or is_jython: ext_modules = [] else: ext_modules = [Extension(name='zodbpickle._pickle', @@ -42,7 +44,7 @@ setup( name='zodbpickle', - version='1.0.4', + version='2.0.0', description='Fork of Python 2 and 3 pickle module.', author='Python and Zope Foundation', author_email='[email protected]', @@ -57,10 +59,10 @@ 'Programming Language :: Python :: 2', 'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', + 'Programming Language :: Python :: 3.8', 'Programming Language :: Python :: Implementation :: CPython', 'Programming Language :: Python :: Implementation :: PyPy', 'Programming Language :: Python :: Implementation :: Jython', @@ -78,7 +80,6 @@ ext_modules=ext_modules, extras_require={ 'test': [], - 'testing': ['nose', 'coverage'], }, test_suite='zodbpickle.tests.test_pickle.test_suite', install_requires=[ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/src/zodbpickle/__init__.py new/zodbpickle-2.0.0/src/zodbpickle/__init__.py --- old/zodbpickle-1.0.4/src/zodbpickle/__init__.py 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/src/zodbpickle/__init__.py 2019-11-13 13:40:47.000000000 +0100 @@ -1,11 +1,24 @@ import sys +__all__ = [ + 'binary', +] + if sys.version_info[0] < 3: - class binary(bytes): - """Mark a given string as explicitly binary + try: + from zodbpickle._pickle import binary + except ImportError: + # we get ImportError if the module isn't around at all, + # e.g., on PyPy. We get AttributeError if it doesn't define + # the binary attribute, which would be the case if we have an + # old version of the C extension library. That might happen in + # development but shouldn't in production; let it raise. + class binary(bytes): + """Mark a given string as explicitly binary - I.e., it should be unpickled as bytes on Py3k, rather than being + I.e., it should be unpickled as bytes on Py3k, rather than being forcibly promoted to unicode. - """ + """ + __slots__ = () else: binary = bytes diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/src/zodbpickle/_pickle_27.c new/zodbpickle-2.0.0/src/zodbpickle/_pickle_27.c --- old/zodbpickle-1.0.4/src/zodbpickle/_pickle_27.c 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/src/zodbpickle/_pickle_27.c 2019-11-13 13:40:47.000000000 +0100 @@ -118,7 +118,6 @@ static PyObject *UnpickleableError; static PyObject *UnpicklingError; static PyObject *BadPickleGet; -static PyObject *BinaryType; /* from zodbpickle import binary */ /* As the name says, an empty tuple. */ static PyObject *empty_tuple; @@ -144,6 +143,56 @@ *read_str, *readline_str, *__main___str, *dispatch_table_str; +static PyTypeObject BinaryType_t = { + PyVarObject_HEAD_INIT(NULL, 0) + "zodbpickle.binary", /* tp_name */ + /* the sizes are filled in from PyString_Type later */ + 0, /* tp_basicsize */ + 0, /* tp_itemsize */ + 0, /* tp_dealloc */ + 0, /* tp_print */ + 0, /* tp_getattr */ + 0, /* tp_setattr */ + 0, /* tp_compare */ + 0, /* tp_repr */ + 0, /* tp_as_number */ + 0, /* tp_as_sequence */ + 0, /* tp_as_mapping */ + 0, /* tp_hash */ + 0, /* tp_call */ + 0, /* tp_str */ + 0, /* tp_getattro */ + 0, /* tp_setattro */ + 0, /* tp_as_buffer */ + Py_TPFLAGS_DEFAULT | Py_TPFLAGS_CHECKTYPES | + Py_TPFLAGS_BASETYPE | Py_TPFLAGS_STRING_SUBCLASS | + Py_TPFLAGS_HAVE_NEWBUFFER, + NULL, /* tp_doc */ + 0, /* tp_traverse */ + 0, /* tp_clear */ + 0, /* tp_richcompare */ + 0, /* tp_weaklistoffset */ + 0, /* tp_iter */ + 0, /* tp_iternext */ + 0, /* tp_methods */ + 0, /* tp_members */ + 0, /* tp_getset */ + /* The Windows compiler compalins that this is not a constant. */ + /* So initialize later. */ + /* &PyString_Type, */ /* tp_base */ + 0, /* tp_base */ + 0, /* tp_dict */ + 0, /* tp_descr_get */ + 0, /* tp_descr_set */ + 0, /* tp_dictoffset */ + 0, /* tp_init */ + 0, /* tp_alloc */ + 0, /* tp_new */ + 0, /* tp_free */ +}; + +static PyObject* BinaryType = (PyObject*)&BinaryType_t; + /************************************************************************* Internal Data type for pickle data. */ @@ -2716,10 +2765,6 @@ switch (type->tp_name[0]) { case 'b': - if (strcmp(type->tp_name, "binary") == 0) { - res = save_bytes(self, args); - goto finally; - } if (args == Py_False || args == Py_True) { res = save_bool(self, args); goto finally; @@ -2768,6 +2813,14 @@ } break; #endif + case 'z': + /* No need to also support plain 'binary' as we would get from a type + defined in Python; if we're running then our C BinaryType should be + in use. */ + if (strcmp(type->tp_name, "zodbpickle.binary") == 0) { + res = save_bytes(self, args); + goto finally; + } } if (Py_REFCNT(args) > 1) { @@ -6159,6 +6212,7 @@ { NULL, NULL } }; + static int init_stuff(PyObject *module_dict) { @@ -6170,6 +6224,11 @@ return -1; if (PyType_Ready(&Picklertype) < 0) return -1; + BinaryType_t.tp_basicsize = PyString_Type.tp_basicsize; + BinaryType_t.tp_itemsize = PyString_Type.tp_itemsize; + BinaryType_t.tp_base = &PyString_Type; + if (PyType_Ready(&BinaryType_t) < 0) + return -1; INIT_STR(__class__); INIT_STR(__getinitargs__); @@ -6288,6 +6347,10 @@ BadPickleGet) < 0) return -1; + if (PyDict_SetItemString(module_dict, "binary", + BinaryType) < 0) + return -1; + PycString_IMPORT; return 0; @@ -6308,6 +6371,7 @@ Py_TYPE(&Picklertype) = &PyType_Type; Py_TYPE(&Unpicklertype) = &PyType_Type; Py_TYPE(&PdataType) = &PyType_Type; + Py_TYPE(&BinaryType_t) = &PyType_Type; /* Initialize some pieces. We need to do this before module creation, * so we're forced to use a temporary dictionary. :( @@ -6342,18 +6406,6 @@ if (i < 0) return; - if (BinaryType == NULL) { - PyObject *zodbpickle_module = PyImport_ImportModule("zodbpickle"); - if (zodbpickle_module == NULL) { - return; - } - BinaryType = PyObject_GetAttrString(zodbpickle_module, "binary"); - Py_DECREF(zodbpickle_module); - if (BinaryType == NULL) { - return; - } - } - /* These are purely informational; no code uses them. */ /* File format version we write. */ format_version = PyString_FromString("2.0"); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/src/zodbpickle/tests/test_pickle_2.py new/zodbpickle-2.0.0/src/zodbpickle/tests/test_pickle_2.py --- old/zodbpickle-1.0.4/src/zodbpickle/tests/test_pickle_2.py 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/src/zodbpickle/tests/test_pickle_2.py 2019-11-13 13:40:47.000000000 +0100 @@ -339,14 +339,54 @@ _pickle.dumps(res) +class BinaryTests(unittest.TestCase): + + def test_has_no_attrs(self): + from zodbpickle import binary + b = binary('abc') + with self.assertRaises(AttributeError): + setattr(b, 'attr', 42) + + def test_can_subclass(self): + from zodbpickle import binary + class MyBinary(binary): + pass + + my = MyBinary('') + my.attr = 42 + self.assertEqual(my, '') + self.assertEqual(my.attr, 42) + +class cBinaryTests(unittest.TestCase): + + def test_same_size(self): + # PyPy doesn't support sys.getsizeof, but + # we don't run these tests there. + import sys + from zodbpickle import binary + + s = b'abcdef' + b = binary(s) + self.assertEqual(sys.getsizeof(b), sys.getsizeof(s)) + + def test_not_tracked_by_gc(self): + # PyPy doesn't have gc.is_tracked, but we don't + # run these tests there. + import gc + from zodbpickle import binary + s = b'abcdef' + b = binary(s) + self.assertFalse(gc.is_tracked(s)) + self.assertFalse(gc.is_tracked(b)) + def test_suite(): - import unittest tests = [ unittest.makeSuite(PickleTests), unittest.makeSuite(PicklerTests), unittest.makeSuite(PersPicklerTests), unittest.makeSuite(PicklerUnpicklerObjectTests), unittest.makeSuite(PickleBigmemPickleTests), + unittest.makeSuite(BinaryTests), ] if has_c_implementation: @@ -364,6 +404,7 @@ unittest.makeSuite(cPickleDeepRecursive), unittest.makeSuite(cPicklePicklerUnpicklerObjectTests), unittest.makeSuite(cPickleBigmemPickleTests), + unittest.makeSuite(cBinaryTests), ]) return unittest.TestSuite(tests) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/src/zodbpickle.egg-info/PKG-INFO new/zodbpickle-2.0.0/src/zodbpickle.egg-info/PKG-INFO --- old/zodbpickle-1.0.4/src/zodbpickle.egg-info/PKG-INFO 2019-06-12 07:56:00.000000000 +0200 +++ new/zodbpickle-2.0.0/src/zodbpickle.egg-info/PKG-INFO 2019-11-13 13:40:47.000000000 +0100 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: zodbpickle -Version: 1.0.4 +Version: 2.0.0 Summary: Fork of Python 2 and 3 pickle module. Home-page: https://github.com/zopefoundation/zodbpickle Author: Python and Zope Foundation @@ -177,6 +177,23 @@ Changelog =========== + 2.0.0 (2019-11-13) + ================== + + - CPython 2: Make ``zodbpickle.binary`` objects smaller and untracked + by the garbage collector. Now they behave more like the native bytes + object. Just like it, and just like on Python 3, they cannot have + arbitrary attributes or be weakly referenced. See `issue 53 + <https://github.com/zopefoundation/zodbpickle/issues/53>`_. + + 1.1 (2019-11-09) + ================ + + - Add support for Python 3.8. + + - Drop support for Python 3.4. + + 1.0.4 (2019-06-12) ================== @@ -344,10 +361,10 @@ Classifier: Programming Language :: Python :: 2 Classifier: Programming Language :: Python :: 2.7 Classifier: Programming Language :: Python :: 3 -Classifier: Programming Language :: Python :: 3.4 Classifier: Programming Language :: Python :: 3.5 Classifier: Programming Language :: Python :: 3.6 Classifier: Programming Language :: Python :: 3.7 +Classifier: Programming Language :: Python :: 3.8 Classifier: Programming Language :: Python :: Implementation :: CPython Classifier: Programming Language :: Python :: Implementation :: PyPy Classifier: Programming Language :: Python :: Implementation :: Jython @@ -358,4 +375,3 @@ Classifier: Operating System :: Unix Classifier: Operating System :: MacOS :: MacOS X Provides-Extra: test -Provides-Extra: testing diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/src/zodbpickle.egg-info/SOURCES.txt new/zodbpickle-2.0.0/src/zodbpickle.egg-info/SOURCES.txt --- old/zodbpickle-1.0.4/src/zodbpickle.egg-info/SOURCES.txt 2019-06-12 07:56:00.000000000 +0200 +++ new/zodbpickle-2.0.0/src/zodbpickle.egg-info/SOURCES.txt 2019-11-13 13:40:47.000000000 +0100 @@ -1,8 +1,6 @@ .coveragerc -.gitignore .manylinux-install.sh .manylinux.sh -.travis.yml CHANGES.rst LICENSE.txt MANIFEST.in diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/src/zodbpickle.egg-info/requires.txt new/zodbpickle-2.0.0/src/zodbpickle.egg-info/requires.txt --- old/zodbpickle-1.0.4/src/zodbpickle.egg-info/requires.txt 2019-06-12 07:56:00.000000000 +0200 +++ new/zodbpickle-2.0.0/src/zodbpickle.egg-info/requires.txt 2019-11-13 13:40:47.000000000 +0100 @@ -1,7 +1,3 @@ setuptools [test] - -[testing] -nose -coverage diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/zodbpickle-1.0.4/tox.ini new/zodbpickle-2.0.0/tox.ini --- old/zodbpickle-1.0.4/tox.ini 2019-06-12 07:55:59.000000000 +0200 +++ new/zodbpickle-2.0.0/tox.ini 2019-11-13 13:40:47.000000000 +0100 @@ -1,14 +1,13 @@ [tox] # Jython 2.7rc2 does work, but unfortunately has an issue running # with Tox 1.9.2 (http://bugs.jython.org/issue2325) -envlist = py27,py34,py35,py36,py37,pypy,pypy3,coverage-report +envlist = py27,py35,py36,py37,py38,pypy,pypy3,coverage-report [testenv] usedevelop = True commands = - coverage run setup.py test -q + coverage run setup.py -q test deps = - . coverage setenv = COVERAGE_FILE=.coverage.{envname}
