From 35cd380d0df47667b91b817f30f38c7873896a0bdfcfb6b9c266b53459f2c724 Mon Sep 17 00:00:00 2001 From: Nico Krapp Date: Fri, 23 Aug 2024 08:57:04 +0000 Subject: [PATCH] Accepting request 1195203 from home:yeey:branches:devel:languages:python - Update to version 4.8.0 * Return consistent responses after Websocket connection ends * Migrate Python package metadata to pyproject.toml * Remove Python 3.7 from builds * Internal code restructure (no functional changes) OBS-URL: https://build.opensuse.org/request/show/1195203 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-python-engineio?expand=0&rev=12 --- python-311.patch | 54 ---------------------------------- python-engineio-4.3.4.tar.gz | 3 -- python-engineio-4.8.0.tar.gz | 3 ++ python-python-engineio.changes | 9 ++++++ python-python-engineio.spec | 19 +++++++----- 5 files changed, 23 insertions(+), 65 deletions(-) delete mode 100644 python-311.patch delete mode 100644 python-engineio-4.3.4.tar.gz create mode 100644 python-engineio-4.8.0.tar.gz diff --git a/python-311.patch b/python-311.patch deleted file mode 100644 index 0ad4f76..0000000 --- a/python-311.patch +++ /dev/null @@ -1,54 +0,0 @@ -diff --git a/tests/asyncio/test_asyncio_server.py b/tests/asyncio/test_asyncio_server.py -index 47b3e6e..a55e1e0 100644 ---- a/tests/asyncio/test_asyncio_server.py -+++ b/tests/asyncio/test_asyncio_server.py -@@ -278,9 +278,9 @@ def test_connect_custom_ping_times(self, import_module): - assert packets[0].data['pingTimeout'] == 123000 - assert packets[0].data['pingInterval'] == 456000 - -- @mock.patch('engineio.asyncio_socket.AsyncSocket') - @mock.patch('importlib.import_module') -- def test_connect_bad_poll(self, import_module, AsyncSocket): -+ @mock.patch('engineio.asyncio_server.asyncio_socket.AsyncSocket') -+ def test_connect_bad_poll(self, AsyncSocket, import_module): - a = self.get_async_mock() - import_module.side_effect = [a] - AsyncSocket.return_value = self._get_mock_socket() -@@ -290,9 +290,9 @@ def test_connect_bad_poll(self, import_module, AsyncSocket): - assert a._async['make_response'].call_count == 1 - assert a._async['make_response'].call_args[0][0] == '400 BAD REQUEST' - -- @mock.patch('engineio.asyncio_socket.AsyncSocket') - @mock.patch('importlib.import_module') -- def test_connect_transport_websocket(self, import_module, AsyncSocket): -+ @mock.patch('engineio.asyncio_server.asyncio_socket.AsyncSocket') -+ def test_connect_transport_websocket(self, AsyncSocket, import_module): - a = self.get_async_mock( - { - 'REQUEST_METHOD': 'GET', -@@ -312,9 +312,9 @@ def test_connect_transport_websocket(self, import_module, AsyncSocket): - == packet.OPEN - ) - -- @mock.patch('engineio.asyncio_socket.AsyncSocket') - @mock.patch('importlib.import_module') -- def test_http_upgrade_case_insensitive(self, import_module, AsyncSocket): -+ @mock.patch('engineio.asyncio_server.asyncio_socket.AsyncSocket') -+ def test_http_upgrade_case_insensitive(self, AsyncSocket, import_module): - a = self.get_async_mock( - { - 'REQUEST_METHOD': 'GET', -@@ -334,11 +334,10 @@ def test_http_upgrade_case_insensitive(self, import_module, AsyncSocket): - == packet.OPEN - ) - -- @mock.patch('engineio.asyncio_socket.AsyncSocket') - @mock.patch('importlib.import_module') -+ @mock.patch('engineio.asyncio_server.asyncio_socket.AsyncSocket') - def test_connect_transport_websocket_closed( -- self, import_module, AsyncSocket -- ): -+ self, AsyncSocket, import_module): - a = self.get_async_mock( - { - 'REQUEST_METHOD': 'GET', diff --git a/python-engineio-4.3.4.tar.gz b/python-engineio-4.3.4.tar.gz deleted file mode 100644 index c84e968..0000000 --- a/python-engineio-4.3.4.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:1f6ff1c3b3463a453b8eafa7a81f1dd52bd1728bf524988f9ab99b71c31a8d8e -size 300665 diff --git a/python-engineio-4.8.0.tar.gz b/python-engineio-4.8.0.tar.gz new file mode 100644 index 0000000..d328ece --- /dev/null +++ b/python-engineio-4.8.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2a32585d8fecd0118264fe0c39788670456ca9aa466d7c026d995cfff68af164 +size 88626 diff --git a/python-python-engineio.changes b/python-python-engineio.changes index 652c198..7e200b2 100644 --- a/python-python-engineio.changes +++ b/python-python-engineio.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Wed Aug 14 00:46:24 UTC 2024 - Guang Yee + +- Update to version 4.8.0 + * Return consistent responses after Websocket connection ends + * Migrate Python package metadata to pyproject.toml + * Remove Python 3.7 from builds + * Internal code restructure (no functional changes) + ------------------------------------------------------------------- Fri Dec 1 16:43:25 UTC 2023 - Antonio Larrosa diff --git a/python-python-engineio.spec b/python-python-engineio.spec index 2f012b0..69996bd 100644 --- a/python-python-engineio.spec +++ b/python-python-engineio.spec @@ -1,7 +1,7 @@ # # spec file for package python-python-engineio # -# Copyright (c) 2023 SUSE LLC +# Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -18,15 +18,16 @@ %{?sle15_python_module_pythons} Name: python-python-engineio -Version: 4.3.4 +Version: 4.8.0 Release: 0 Summary: EngineIO server License: MIT URL: http://github.com/miguelgrinberg/python-engineio/ Source: https://github.com/miguelgrinberg/python-engineio/archive/v%{version}.tar.gz#/python-engineio-%{version}.tar.gz -# PATCH-FIX-UPSTREAM python-311.patch gh#miguelgrinberg/python-engineio@ac3911356fbe -Patch0: python-311.patch +BuildRequires: %{python_module pip} BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module simple-websocket >= 0.10.0} +BuildRequires: %{python_module wheel} BuildRequires: fdupes BuildRequires: python-rpm-macros Recommends: python-eventlet @@ -51,17 +52,19 @@ Python implementation of the Engine.IO realtime server. %autosetup -p1 -n python-engineio-%{version} %build -%python_build +%pyproject_wheel %install -%python_install +%pyproject_install %python_expand %fdupes %{buildroot}%{$python_sitelib} %check -%pytest -rs -k 'not test_logger' +# FIXME: disable the static files tests because the tests/async/files is missing from +# the release tarball. Hence those tests will always fail. +%pytest -rs -k 'not test_logger and not test_static_file_routing and not test_static_files' %files %{python_files} -%doc README.rst +%doc README.md %license LICENSE %{python_sitelib}/engineio %{python_sitelib}/python_engineio-%{version}*-info