diff --git a/pymemcache-3.5.2.tar.gz b/pymemcache-3.5.2.tar.gz deleted file mode 100644 index 27c65c6..0000000 --- a/pymemcache-3.5.2.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8923ab59840f0d5338f1c52dba229fa835545b91c3c2f691c118e678d0fb974e -size 65351 diff --git a/pymemcache-4.0.0.tar.gz b/pymemcache-4.0.0.tar.gz new file mode 100644 index 0000000..508d8ff --- /dev/null +++ b/pymemcache-4.0.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:27bf9bd1bbc1e20f83633208620d56de50f14185055e49504f4f5e94e94aff94 +size 70176 diff --git a/python-pymemcache-no-mock.patch b/python-pymemcache-no-mock.patch deleted file mode 100644 index cbc90dc..0000000 --- a/python-pymemcache-no-mock.patch +++ /dev/null @@ -1,47 +0,0 @@ -diff --git a/pymemcache/test/test_client.py b/pymemcache/test/test_client.py -index 8b323ded..f0aac442 100644 ---- a/pymemcache/test/test_client.py -+++ b/pymemcache/test/test_client.py -@@ -1,5 +1,4 @@ - # Copyright 2012 Pinterest.com --# -*- coding: utf-8 -*- - # - # Licensed under the Apache License, Version 2.0 (the "License"); - # you may not use this file except in compliance with the License. -@@ -20,8 +19,8 @@ - import functools - import json - import os --import mock - import platform -+from unittest import mock - import re - import socket - import sys -diff --git a/pymemcache/test/test_client_hash.py b/pymemcache/test/test_client_hash.py -index ad3f2dac..ceab7052 100644 ---- a/pymemcache/test/test_client_hash.py -+++ b/pymemcache/test/test_client_hash.py -@@ -7,7 +7,7 @@ - import unittest - import os - import pytest --import mock -+from unittest import mock - import socket - - -diff --git a/pymemcache/test/test_client_retry.py b/pymemcache/test/test_client_retry.py -index 230a941..de64a46 100644 ---- a/pymemcache/test/test_client_retry.py -+++ b/pymemcache/test/test_client_retry.py -@@ -2,8 +2,8 @@ - - import functools - import unittest -+from unittest import mock - --import mock - import pytest - - from .test_client import ClientTestMixin, MockSocket diff --git a/python-pymemcache.changes b/python-pymemcache.changes index c450505..aa8392e 100644 --- a/python-pymemcache.changes +++ b/python-pymemcache.changes @@ -1,3 +1,37 @@ +------------------------------------------------------------------- +Mon Dec 12 17:10:07 UTC 2022 - Daniel Garcia + +- Disable broken tests in i586. + +------------------------------------------------------------------- +Wed Dec 7 13:33:02 UTC 2022 - Daniel Garcia + +- Fix launch of memcached for tests + +------------------------------------------------------------------- +Wed Dec 7 13:11:08 UTC 2022 - Daniel Garcia + +- Remove python-pymemcache-no-mock.patch +- More specific python_sitelib in %files +- Remove python_module macro definition +- Update to 4.0.0: + * Drop python support for 2.7, 3.4 and 3.5 by @jogo in #321 + * Use default for get ignore_exc by @jogo in #351 + * Return default from hash client by @Pankrat in #352 + * Return default from hash client when using positional argument by @Pankrat + in #354 + * Support noreply for hash flush_all by @jogo in #361 + * Drop support for Python 3.6 by @jparise in #363 + * Add official support for Python 3.10 by @jparise in #365 + * Handle a blank stat value by @liquidpele in #388 + * Small buffer pass optimization as discussed in #395. by @martinnj in #402 + * Expand Client with a method for sending arbitrary commands. by @martinnj in + #395 + * add pluggable compression serde by @sontek in #407 + * Start to add type hints by @jogo in #415 + * Add py.typed file by @jogo in #421 + * Fix key_prefix issue with stats and cache_memlimit by @jogo in #433 + ------------------------------------------------------------------- Thu Apr 7 09:31:23 UTC 2022 - pgajdos@suse.com diff --git a/python-pymemcache.spec b/python-pymemcache.spec index ed075a6..17af6ab 100644 --- a/python-pymemcache.spec +++ b/python-pymemcache.spec @@ -17,30 +17,27 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} %bcond_without python2 Name: python-pymemcache -Version: 3.5.2 +Version: 4.0.0 Release: 0 Summary: A pure Python memcached client License: Apache-2.0 Group: Development/Languages/Python URL: https://github.com/Pinterest/pymemcache Source: https://files.pythonhosted.org/packages/source/p/pymemcache/pymemcache-%{version}.tar.gz -# https://github.com/pinterest/pymemcache/commit/0bf1baa4f539dedf8e4e4b2e48f8da5d66ed57b5 -Patch0: python-pymemcache-no-mock.patch BuildRequires: %{python_module setuptools} BuildRequires: fdupes BuildRequires: memcached BuildRequires: python-rpm-macros -Requires: python-six BuildArch: noarch # SECTION test requirements BuildRequires: %{python_module gevent} +BuildRequires: %{python_module Faker} BuildRequires: %{python_module pylibmc} BuildRequires: %{python_module pytest} BuildRequires: %{python_module python-memcached} -BuildRequires: %{python_module six} +BuildRequires: %{python_module zstd} # /SECTION %if %{with python2} BuildRequires: python-future @@ -74,14 +71,32 @@ sed -i 's/tool:pytest/tool:ignore-pytest-cov/' setup.cfg %python_expand %fdupes %{buildroot}%{$python_sitelib} %check -%{_sbindir}/memcached & +if [ -f %{_sbindir}/memcached ]; then + %{_sbindir}/memcached & +elif [ -f %{_bindir}/memcached ]; then + %{_bindir}/memcached & +fi + +cat << EOF > pytest.ini +[pytest] +markers = + unit + integration + benchmark +EOF + # TLS tests depend on setting up a memcached equivalent to # https://github.com/scoriacorp/docker-tls-memcached -%pytest -rs -k 'not tls' +donttest="tls" +# In i586 zlib.compress doesn't compress the CustomInt instance so these tests +# fails +donttest+=" or test_compressed_complex" +%pytest -rs -k "not (${donttest})" -m "unit or integration" %files %{python_files} %license LICENSE.txt %doc README.rst -%{python_sitelib}/* +%{python_sitelib}/pymemcache +%{python_sitelib}/pymemcache-%{version}*-info %changelog