forked from pool/python-eventlet
Accepting request 1096209 from devel:languages:python
Automatic submission by obs-autosubmit OBS-URL: https://build.opensuse.org/request/show/1096209 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-eventlet?expand=0&rev=51
This commit is contained in:
@@ -1,20 +1,14 @@
|
|||||||
Index: eventlet-0.33.0/setup.py
|
---
|
||||||
===================================================================
|
eventlet.egg-info/SOURCES.txt | 3
|
||||||
--- eventlet-0.33.0.orig/setup.py
|
setup.py | 2
|
||||||
+++ eventlet-0.33.0/setup.py
|
tests/__init__.py | 3
|
||||||
@@ -27,7 +27,7 @@ setuptools.setup(
|
tests/dagpool_test.py | 149 ++++++++++++++++++++----------------------
|
||||||
'README.rst'
|
tests/greenio_test.py | 8 --
|
||||||
)
|
tests/nosewrapper.py | 13 ---
|
||||||
).read(),
|
6 files changed, 83 insertions(+), 95 deletions(-)
|
||||||
- test_suite='nose.collector',
|
|
||||||
+ test_suite='tests',
|
--- a/eventlet.egg-info/SOURCES.txt
|
||||||
classifiers=[
|
+++ b/eventlet.egg-info/SOURCES.txt
|
||||||
"Development Status :: 4 - Beta",
|
|
||||||
"Intended Audience :: Developers",
|
|
||||||
Index: eventlet-0.33.0/eventlet.egg-info/SOURCES.txt
|
|
||||||
===================================================================
|
|
||||||
--- eventlet-0.33.0.orig/eventlet.egg-info/SOURCES.txt
|
|
||||||
+++ eventlet-0.33.0/eventlet.egg-info/SOURCES.txt
|
|
||||||
@@ -175,7 +175,6 @@ tests/greenthread_test.py
|
@@ -175,7 +175,6 @@ tests/greenthread_test.py
|
||||||
tests/hub_test.py
|
tests/hub_test.py
|
||||||
tests/mock.py
|
tests/mock.py
|
||||||
@@ -30,71 +24,19 @@ Index: eventlet-0.33.0/eventlet.egg-info/SOURCES.txt
|
|||||||
-tests/stdlib/test_urllib2_localnet.py
|
-tests/stdlib/test_urllib2_localnet.py
|
||||||
\ No newline at end of file
|
\ No newline at end of file
|
||||||
+tests/stdlib/test_urllib2_localnet.py
|
+tests/stdlib/test_urllib2_localnet.py
|
||||||
Index: eventlet-0.33.0/tests/greenio_test.py
|
--- a/setup.py
|
||||||
===================================================================
|
+++ b/setup.py
|
||||||
--- eventlet-0.33.0.orig/tests/greenio_test.py
|
@@ -30,7 +30,7 @@ setuptools.setup(
|
||||||
+++ eventlet-0.33.0/tests/greenio_test.py
|
'README.rst'
|
||||||
@@ -9,8 +9,6 @@ import socket as _orig_sock
|
)
|
||||||
import sys
|
).read(),
|
||||||
import tempfile
|
- test_suite='nose.collector',
|
||||||
|
+ test_suite='tests',
|
||||||
-from nose.tools import eq_
|
classifiers=[
|
||||||
-
|
"Development Status :: 4 - Beta",
|
||||||
import eventlet
|
"Intended Audience :: Developers",
|
||||||
from eventlet import event, greenio, debug
|
--- a/tests/__init__.py
|
||||||
from eventlet.hubs import get_hub
|
+++ b/tests/__init__.py
|
||||||
@@ -39,7 +37,7 @@ def expect_socket_timeout(function, *arg
|
|
||||||
raise AssertionError("socket.timeout not raised")
|
|
||||||
except socket.timeout as e:
|
|
||||||
assert hasattr(e, 'args')
|
|
||||||
- eq_(e.args[0], 'timed out')
|
|
||||||
+ assert e.args[0] == 'timed out'
|
|
||||||
|
|
||||||
|
|
||||||
def min_buf_size():
|
|
||||||
@@ -674,8 +672,8 @@ class TestGreenSocket(tests.LimitedTestC
|
|
||||||
sender.sendto(b'second', 0, address)
|
|
||||||
|
|
||||||
sender_address = ('127.0.0.1', sender.getsockname()[1])
|
|
||||||
- eq_(receiver.recvfrom(1024), (b'first', sender_address))
|
|
||||||
- eq_(receiver.recvfrom(1024), (b'second', sender_address))
|
|
||||||
+ assert receiver.recvfrom(1024) == (b'first', sender_address)
|
|
||||||
+ assert receiver.recvfrom(1024) == (b'second', sender_address)
|
|
||||||
|
|
||||||
|
|
||||||
def test_get_fileno_of_a_socket_works():
|
|
||||||
Index: eventlet-0.33.0/tests/nosewrapper.py
|
|
||||||
===================================================================
|
|
||||||
--- eventlet-0.33.0.orig/tests/nosewrapper.py
|
|
||||||
+++ eventlet-0.33.0/tests/nosewrapper.py
|
|
||||||
@@ -1,20 +1,13 @@
|
|
||||||
""" This script simply gets the paths correct for testing eventlet with the
|
|
||||||
hub extension for Nose."""
|
|
||||||
-import nose
|
|
||||||
from os.path import dirname, realpath, abspath
|
|
||||||
import sys
|
|
||||||
+import unittest
|
|
||||||
|
|
||||||
|
|
||||||
parent_dir = dirname(dirname(realpath(abspath(__file__))))
|
|
||||||
if parent_dir not in sys.path:
|
|
||||||
sys.path.insert(0, parent_dir)
|
|
||||||
|
|
||||||
-# hudson does a better job printing the test results if the exit value is 0
|
|
||||||
-zero_status = '--force-zero-status'
|
|
||||||
-if zero_status in sys.argv:
|
|
||||||
- sys.argv.remove(zero_status)
|
|
||||||
- launch = nose.run
|
|
||||||
-else:
|
|
||||||
- launch = nose.main
|
|
||||||
-
|
|
||||||
-launch(argv=sys.argv)
|
|
||||||
+if __name__ == '__main__':
|
|
||||||
+ unittest.main()
|
|
||||||
Index: eventlet-0.33.0/tests/__init__.py
|
|
||||||
===================================================================
|
|
||||||
--- eventlet-0.33.0.orig/tests/__init__.py
|
|
||||||
+++ eventlet-0.33.0/tests/__init__.py
|
|
||||||
@@ -20,7 +20,7 @@ import sys
|
@@ -20,7 +20,7 @@ import sys
|
||||||
import unittest
|
import unittest
|
||||||
import warnings
|
import warnings
|
||||||
@@ -112,10 +54,8 @@ Index: eventlet-0.33.0/tests/__init__.py
|
|||||||
raise SkipTest('CPU usage testing not supported (`import resource` failed)')
|
raise SkipTest('CPU usage testing not supported (`import resource` failed)')
|
||||||
|
|
||||||
r1 = resource.getrusage(resource.RUSAGE_SELF)
|
r1 = resource.getrusage(resource.RUSAGE_SELF)
|
||||||
Index: eventlet-0.33.0/tests/dagpool_test.py
|
--- a/tests/dagpool_test.py
|
||||||
===================================================================
|
+++ b/tests/dagpool_test.py
|
||||||
--- eventlet-0.33.0.orig/tests/dagpool_test.py
|
|
||||||
+++ eventlet-0.33.0/tests/dagpool_test.py
|
|
||||||
@@ -5,7 +5,6 @@
|
@@ -5,7 +5,6 @@
|
||||||
@brief Test DAGPool class
|
@brief Test DAGPool class
|
||||||
"""
|
"""
|
||||||
@@ -433,3 +373,60 @@ Index: eventlet-0.33.0/tests/dagpool_test.py
|
|||||||
+ assert dict(pool.wait_each_exception("ab")) == dict(b=bogub)
|
+ assert dict(pool.wait_each_exception("ab")) == dict(b=bogub)
|
||||||
+ assert dict(pool.wait_each_exception("a")) == {}
|
+ assert dict(pool.wait_each_exception("a")) == {}
|
||||||
+ assert dict(pool.wait_each_exception("b")) == dict(b=bogub)
|
+ assert dict(pool.wait_each_exception("b")) == dict(b=bogub)
|
||||||
|
--- a/tests/greenio_test.py
|
||||||
|
+++ b/tests/greenio_test.py
|
||||||
|
@@ -9,8 +9,6 @@ import socket as _orig_sock
|
||||||
|
import sys
|
||||||
|
import tempfile
|
||||||
|
|
||||||
|
-from nose.tools import eq_
|
||||||
|
-
|
||||||
|
import eventlet
|
||||||
|
from eventlet import event, greenio, debug
|
||||||
|
from eventlet.hubs import get_hub
|
||||||
|
@@ -39,7 +37,7 @@ def expect_socket_timeout(function, *arg
|
||||||
|
raise AssertionError("socket.timeout not raised")
|
||||||
|
except socket.timeout as e:
|
||||||
|
assert hasattr(e, 'args')
|
||||||
|
- eq_(e.args[0], 'timed out')
|
||||||
|
+ assert e.args[0] == 'timed out'
|
||||||
|
|
||||||
|
|
||||||
|
def min_buf_size():
|
||||||
|
@@ -674,8 +672,8 @@ class TestGreenSocket(tests.LimitedTestC
|
||||||
|
sender.sendto(b'second', 0, address)
|
||||||
|
|
||||||
|
sender_address = ('127.0.0.1', sender.getsockname()[1])
|
||||||
|
- eq_(receiver.recvfrom(1024), (b'first', sender_address))
|
||||||
|
- eq_(receiver.recvfrom(1024), (b'second', sender_address))
|
||||||
|
+ assert receiver.recvfrom(1024) == (b'first', sender_address)
|
||||||
|
+ assert receiver.recvfrom(1024) == (b'second', sender_address)
|
||||||
|
|
||||||
|
|
||||||
|
def test_get_fileno_of_a_socket_works():
|
||||||
|
--- a/tests/nosewrapper.py
|
||||||
|
+++ b/tests/nosewrapper.py
|
||||||
|
@@ -1,20 +1,13 @@
|
||||||
|
""" This script simply gets the paths correct for testing eventlet with the
|
||||||
|
hub extension for Nose."""
|
||||||
|
-import nose
|
||||||
|
from os.path import dirname, realpath, abspath
|
||||||
|
import sys
|
||||||
|
+import unittest
|
||||||
|
|
||||||
|
|
||||||
|
parent_dir = dirname(dirname(realpath(abspath(__file__))))
|
||||||
|
if parent_dir not in sys.path:
|
||||||
|
sys.path.insert(0, parent_dir)
|
||||||
|
|
||||||
|
-# hudson does a better job printing the test results if the exit value is 0
|
||||||
|
-zero_status = '--force-zero-status'
|
||||||
|
-if zero_status in sys.argv:
|
||||||
|
- sys.argv.remove(zero_status)
|
||||||
|
- launch = nose.run
|
||||||
|
-else:
|
||||||
|
- launch = nose.main
|
||||||
|
-
|
||||||
|
-launch(argv=sys.argv)
|
||||||
|
+if __name__ == '__main__':
|
||||||
|
+ unittest.main()
|
||||||
|
@@ -1,5 +1,9 @@
|
|||||||
diff --git a/eventlet/patcher.py b/eventlet/patcher.py
|
---
|
||||||
index b249d6f19..4eeb93439 100644
|
eventlet/patcher.py | 42 +++++++++++++----
|
||||||
|
tests/isolated/patcher_existing_logging_module_lock.py | 30 ++++++++++++
|
||||||
|
tests/patcher_test.py | 4 +
|
||||||
|
3 files changed, 68 insertions(+), 8 deletions(-)
|
||||||
|
|
||||||
--- a/eventlet/patcher.py
|
--- a/eventlet/patcher.py
|
||||||
+++ b/eventlet/patcher.py
|
+++ b/eventlet/patcher.py
|
||||||
@@ -412,6 +412,23 @@ def _green_existing_locks():
|
@@ -412,6 +412,23 @@ def _green_existing_locks():
|
||||||
@@ -66,9 +70,6 @@ index b249d6f19..4eeb93439 100644
|
|||||||
|
|
||||||
|
|
||||||
def _green_os_modules():
|
def _green_os_modules():
|
||||||
diff --git a/tests/isolated/patcher_existing_logging_module_lock.py b/tests/isolated/patcher_existing_logging_module_lock.py
|
|
||||||
new file mode 100644
|
|
||||||
index 000000000..2acad62ee
|
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/tests/isolated/patcher_existing_logging_module_lock.py
|
+++ b/tests/isolated/patcher_existing_logging_module_lock.py
|
||||||
@@ -0,0 +1,30 @@
|
@@ -0,0 +1,30 @@
|
||||||
@@ -102,11 +103,9 @@ index 000000000..2acad62ee
|
|||||||
+ t.join(timeout=0.1)
|
+ t.join(timeout=0.1)
|
||||||
+ assert not t.is_alive()
|
+ assert not t.is_alive()
|
||||||
+ print("pass")
|
+ print("pass")
|
||||||
diff --git a/tests/patcher_test.py b/tests/patcher_test.py
|
|
||||||
index dbf6e1c71..e8d6f3300 100644
|
|
||||||
--- a/tests/patcher_test.py
|
--- a/tests/patcher_test.py
|
||||||
+++ b/tests/patcher_test.py
|
+++ b/tests/patcher_test.py
|
||||||
@@ -485,6 +485,10 @@ def test_patcher_existing_locks_unlocked():
|
@@ -485,6 +485,10 @@ def test_patcher_existing_locks_unlocked
|
||||||
tests.run_isolated('patcher_existing_locks_unlocked.py')
|
tests.run_isolated('patcher_existing_locks_unlocked.py')
|
||||||
|
|
||||||
|
|
||||||
|
@@ -1,20 +0,0 @@
|
|||||||
--- eventlet-0.33.0.orig/tests/greendns_test.py
|
|
||||||
+++ eventlet-0.33.0/tests/greendns_test.py
|
|
||||||
@@ -888,7 +888,7 @@ class TinyDNSTests(tests.LimitedTestCase
|
|
||||||
# https://github.com/eventlet/eventlet/issues/499
|
|
||||||
# None means we don't want the server to find the IP
|
|
||||||
with tests.dns_tcp_server(None) as dnsaddr:
|
|
||||||
- resolver = Resolver()
|
|
||||||
+ resolver = Resolver(configure=False)
|
|
||||||
resolver.nameservers = [dnsaddr[0]]
|
|
||||||
resolver.nameserver_ports[dnsaddr[0]] = dnsaddr[1]
|
|
||||||
|
|
||||||
@@ -899,7 +899,7 @@ class TinyDNSTests(tests.LimitedTestCase
|
|
||||||
# https://github.com/eventlet/eventlet/issues/499
|
|
||||||
expected_ip = "192.168.1.1"
|
|
||||||
with tests.dns_tcp_server(expected_ip) as dnsaddr:
|
|
||||||
- resolver = Resolver()
|
|
||||||
+ resolver = Resolver(configure=False)
|
|
||||||
resolver.nameservers = [dnsaddr[0]]
|
|
||||||
resolver.nameserver_ports[dnsaddr[0]] = dnsaddr[1]
|
|
||||||
response = resolver.query('host.example.com', 'a', tcp=True)
|
|
@@ -16,8 +16,6 @@ See https://reproducible-builds.org/ for why this matters.
|
|||||||
tests/test_server.crt | 16 ++++++++--------
|
tests/test_server.crt | 16 ++++++++--------
|
||||||
1 file changed, 8 insertions(+), 8 deletions(-)
|
1 file changed, 8 insertions(+), 8 deletions(-)
|
||||||
|
|
||||||
diff --git a/tests/test_server.crt b/tests/test_server.crt
|
|
||||||
index 67c9adc8b..78759e810 100644
|
|
||||||
--- a/tests/test_server.crt
|
--- a/tests/test_server.crt
|
||||||
+++ b/tests/test_server.crt
|
+++ b/tests/test_server.crt
|
||||||
@@ -2,7 +2,7 @@
|
@@ -2,7 +2,7 @@
|
||||||
@@ -29,7 +27,7 @@ index 67c9adc8b..78759e810 100644
|
|||||||
djELMAkGA1UEBhMCVFMxDTALBgNVBAgMBFRlc3QxDTALBgNVBAcMBFRlc3QxFjAU
|
djELMAkGA1UEBhMCVFMxDTALBgNVBAgMBFRlc3QxDTALBgNVBAcMBFRlc3QxFjAU
|
||||||
BgNVBAoMDVRlc3QgRXZlbnRsZXQxDTALBgNVBAsMBFRlc3QxDTALBgNVBAMMBFRl
|
BgNVBAoMDVRlc3QgRXZlbnRsZXQxDTALBgNVBAsMBFRlc3QxDTALBgNVBAMMBFRl
|
||||||
c3QxEzARBgkqhkiG9w0BCQEWBFRlc3QwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAw
|
c3QxEzARBgkqhkiG9w0BCQEWBFRlc3QwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAw
|
||||||
@@ -13,11 +13,11 @@ Lvc6cJHMKaxHCeIBOL+z/9kJqhh30eqsmNB5AXSoV8b2B3MV3glW2vd5WJVYEWxl
|
@@ -13,11 +13,11 @@ Lvc6cJHMKaxHCeIBOL+z/9kJqhh30eqsmNB5AXSo
|
||||||
3+GNgzZJ3KGape7pcBYER7zg/yZLZxgNFlTCOZiysjNxC0liJA9tgUQhRc1gsqA8
|
3+GNgzZJ3KGape7pcBYER7zg/yZLZxgNFlTCOZiysjNxC0liJA9tgUQhRc1gsqA8
|
||||||
dQxzvqW8kuZedmatjyM58WixvjymobC3AgMBAAGjUzBRMB0GA1UdDgQWBBQT3V3f
|
dQxzvqW8kuZedmatjyM58WixvjymobC3AgMBAAGjUzBRMB0GA1UdDgQWBBQT3V3f
|
||||||
8vCoqGXe6zySSjVP+J/P7zAfBgNVHSMEGDAWgBQT3V3f8vCoqGXe6zySSjVP+J/P
|
8vCoqGXe6zySSjVP+J/P7zAfBgNVHSMEGDAWgBQT3V3f8vCoqGXe6zySSjVP+J/P
|
||||||
|
@@ -2,6 +2,8 @@
|
|||||||
Fri Apr 21 12:24:43 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
Fri Apr 21 12:24:43 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
- add sle15_python_module_pythons (jsc#PED-68)
|
- add sle15_python_module_pythons (jsc#PED-68)
|
||||||
|
- Remove upstreamed newdnspython.patch (bsc#1208126).
|
||||||
|
- skip test_raise_dns_tcp test (gh#eventlet/eventlet#803)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Apr 13 22:41:06 UTC 2023 - Matej Cepl <mcepl@suse.com>
|
Thu Apr 13 22:41:06 UTC 2023 - Matej Cepl <mcepl@suse.com>
|
||||||
|
@@ -29,8 +29,6 @@ Source: https://files.pythonhosted.org/packages/source/e/eventlet/eventl
|
|||||||
# PATCH-FEATURE-UPSTREAM remove_nose.patch gh#eventlet/eventlet#638 mcepl@suse.com
|
# PATCH-FEATURE-UPSTREAM remove_nose.patch gh#eventlet/eventlet#638 mcepl@suse.com
|
||||||
# Removes dependency on nose
|
# Removes dependency on nose
|
||||||
Patch0: denose-eventlet.patch
|
Patch0: denose-eventlet.patch
|
||||||
# PATCH-FIX-UPSTREAM newdnspython.patch mcepl@suse.com -- patch is from gh#rthalley/dnspython#519, discussion in gh#eventlet/eventlet#638
|
|
||||||
Patch1: newdnspython.patch
|
|
||||||
# PATCH-FIX-UPSTREAM https://github.com/eventlet/eventlet/pull/643
|
# PATCH-FIX-UPSTREAM https://github.com/eventlet/eventlet/pull/643
|
||||||
Patch2: python-eventlet-FTBFS2028.patch
|
Patch2: python-eventlet-FTBFS2028.patch
|
||||||
# PATCH-FIX-UPSTREAM fix-py3-rlock.patch gh#eventlet/eventlet#754
|
# PATCH-FIX-UPSTREAM fix-py3-rlock.patch gh#eventlet/eventlet#754
|
||||||
@@ -68,8 +66,7 @@ is implicit, which means Eventlet can be used from the Python
|
|||||||
interpreter, or as part of a larger application.
|
interpreter, or as part of a larger application.
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n eventlet-%{version}
|
%autosetup -p1 -n eventlet-%{version}
|
||||||
%autopatch -p1
|
|
||||||
|
|
||||||
# Fix non-executable script
|
# Fix non-executable script
|
||||||
sed -i '1{/^#!/ d}' eventlet/support/greendns.py
|
sed -i '1{/^#!/ d}' eventlet/support/greendns.py
|
||||||
@@ -96,6 +93,8 @@ skiptests+=" or test_leakage_from_tracebacks"
|
|||||||
skiptests+=" or test_017_ssl_zeroreturnerror"
|
skiptests+=" or test_017_ssl_zeroreturnerror"
|
||||||
# it is racy, see: https://lore.kernel.org/all/CADVnQy=AnJY9NZ3w_xNghEG80-DhsXL0r_vEtkr=dmz0ugcoVw@mail.gmail.com/ (bsc#1202188)
|
# it is racy, see: https://lore.kernel.org/all/CADVnQy=AnJY9NZ3w_xNghEG80-DhsXL0r_vEtkr=dmz0ugcoVw@mail.gmail.com/ (bsc#1202188)
|
||||||
skiptests+=" or test_018b_http_10_keepalive_framing"
|
skiptests+=" or test_018b_http_10_keepalive_framing"
|
||||||
|
# gh#eventlet/eventlet#803
|
||||||
|
skiptests+=" or test_raise_dns_tcp"
|
||||||
|
|
||||||
# Unknown Python 3.6 specific errors
|
# Unknown Python 3.6 specific errors
|
||||||
# TypeError: _wrap_socket() argument 1 must be _socket.socket, not SSLSocket
|
# TypeError: _wrap_socket() argument 1 must be _socket.socket, not SSLSocket
|
||||||
|
Reference in New Issue
Block a user