diff --git a/fix-build-requirements.patch b/fix-build-requirements.patch deleted file mode 100644 index 3a34358..0000000 --- a/fix-build-requirements.patch +++ /dev/null @@ -1,28 +0,0 @@ -From: Antonio Larrosa -Subject: Fix build requirements which were in fact tests requirements - -pytest-asyncio was build requirement by pyee's setup.py file, but -it was only used for tests. Fix it so we can build for all python flavors -and run tests only for python3 (where pytest-asyncio is available). - -Index: pyee-6.0.0/setup.py -=================================================================== ---- pyee-6.0.0.orig/setup.py 2019-04-13 19:47:29.000000000 +0200 -+++ pyee-6.0.0/setup.py 2019-04-25 09:47:13.860816108 +0200 -@@ -14,11 +14,14 @@ setup( - - packages=find_packages(), - setup_requires=[ -+ 'vcversioner' -+ ], -+ tests_require=[ -+ 'twisted', -+ 'futures; python_version < "3.0"', - 'pytest-runner', - 'pytest-asyncio; python_version > "3.4"', -- 'vcversioner' - ], -- tests_require=['twisted', 'futures; python_version < "3.0"'], - include_package_data=True, - - description="A port of node.js's EventEmitter to python.", diff --git a/pyee-6.0.0.tar.gz b/pyee-6.0.0.tar.gz deleted file mode 100644 index 11decd7..0000000 --- a/pyee-6.0.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a9c9b60e8693a260dd942ef5a71358cfcbba15792d5e72caf0e3c891c4e91c3b -size 10255 diff --git a/pyee-7.0.1.tar.gz b/pyee-7.0.1.tar.gz new file mode 100644 index 0000000..ed48708 --- /dev/null +++ b/pyee-7.0.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b0e5b89b17c8bd52a3c6517a545187907a8c69ce90169d29ebd8d2d5d7e4bc7d +size 14754 diff --git a/python-pyee-import-asyncio.exceptions.patch b/python-pyee-import-asyncio.exceptions.patch new file mode 100644 index 0000000..68395b2 --- /dev/null +++ b/python-pyee-import-asyncio.exceptions.patch @@ -0,0 +1,13 @@ +Index: pyee-7.0.1/tests/test_async.py +=================================================================== +--- pyee-7.0.1.orig/tests/test_async.py 2020-01-30 21:22:49.000000000 +0100 ++++ pyee-7.0.1/tests/test_async.py 2020-03-27 10:10:34.734403451 +0100 +@@ -4,7 +4,7 @@ import pytest + import pytest_asyncio.plugin # noqa + + from asyncio import Future, wait_for +-from concurrent.futures import TimeoutError ++from asyncio.exceptions import TimeoutError + from mock import Mock + + from twisted.internet.defer import ensureDeferred, succeed diff --git a/python-pyee.changes b/python-pyee.changes index 7c7080c..0edb3d9 100644 --- a/python-pyee.changes +++ b/python-pyee.changes @@ -1,3 +1,16 @@ +------------------------------------------------------------------- +Thu Mar 26 14:04:57 UTC 2020 - pgajdos@suse.com + +- version update to 7.0.1 + - Some tweaks to the docs + - Added a ``TrioEventEmitter`` class for intended use with trio + - ``AsyncIOEventEmitter`` now correctly handles cancellations + - Add a new experimental ``pyee.uplift`` API for adding new functionality to + existing event emitters +- deleted patches + - fix-build-requirements.patch (upstreamed) +- Add patch python-pyee-import-asyncio.exceptions.patch + ------------------------------------------------------------------- Thu Apr 25 07:50:21 UTC 2019 - pgajdos@suse.com diff --git a/python-pyee.spec b/python-pyee.spec index 132a1e7..3c67080 100644 --- a/python-pyee.spec +++ b/python-pyee.spec @@ -1,7 +1,7 @@ # # spec file for package python-pyee # -# 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 @@ -17,9 +17,8 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} -%bcond_without test Name: python-pyee -Version: 6.0.0 +Version: 7.0.1 Release: 0 Summary: A port of node.js's EventEmitter to python License: MIT @@ -27,8 +26,9 @@ Group: Development/Languages/Python URL: https://github.com/jfhbrook/pyee Source: https://files.pythonhosted.org/packages/source/p/pyee/pyee-%{version}.tar.gz Source99: https://raw.githubusercontent.com/jfhbrook/pyee/master/LICENSE -# PATCH-FIX-UPSTREAM fix-build-requirements.patch -Patch0: fix-build-requirements.patch +# test_async.py: import asyncio.exception.TimeoutError +# https://github.com/jfhbrook/pyee/issues/68 +Patch0: python-pyee-import-asyncio.exceptions.patch BuildRequires: %{python_module PyHamcrest} BuildRequires: %{python_module setuptools} BuildRequires: %{python_module vcversioner} @@ -36,12 +36,11 @@ BuildRequires: fdupes BuildRequires: python-rpm-macros BuildArch: noarch # SECTION test requirements -%if %{with test} BuildRequires: %{python_module Twisted} BuildRequires: %{python_module mock} BuildRequires: %{python_module pytest-runner} BuildRequires: python3-pytest-asyncio -%endif +BuildRequires: python3-pytest-trio # /SECTION %python_subpackages @@ -62,15 +61,13 @@ cp %{SOURCE99} . %python_install %python_expand %fdupes %{buildroot}%{$python_sitelib} -%if %{with test} && 0%{?suse_version} >= 1500 %check -# Only run tests for python3 +# Only run tests for python3 (see test requirements) %{python_expand # if [ "${python_flavor}" == "python3" ]; then python3 setup.py test fi } -%endif %files %{python_files} %doc README.rst