From 2fed4eba0b6a90d9681b3b3bb7978dbf2dee910d Mon Sep 17 00:00:00 2001 From: =?utf8?q?Elan=20Ruusam=C3=A4e?= Date: Sat, 30 May 2015 17:43:09 +0300 Subject: [PATCH] attempt to convert known failures to new format --- known_failures-pld.patch | 86 ++++++++++++++++++++++++++++++++++++++++ known_failures-pld.txt | 76 ----------------------------------- python-gevent.spec | 12 +++--- 3 files changed, 91 insertions(+), 83 deletions(-) create mode 100644 known_failures-pld.patch delete mode 100644 known_failures-pld.txt diff --git a/known_failures-pld.patch b/known_failures-pld.patch new file mode 100644 index 0000000..93daebb --- /dev/null +++ b/known_failures-pld.patch @@ -0,0 +1,86 @@ +--- gevent-1.0.1/known_failures.py~ 2014-04-30 17:45:07.000000000 +0300 ++++ gevent-1.0.1/known_failures.py 2015-05-30 17:35:36.317971589 +0300 +@@ -21,6 +21,83 @@ + # Sometimes fails with AssertionError: ...\nIOError: close() called during concurrent operation on the same file object.\n' + # Sometimes it contains "\nUnhandled exception in thread started by \nsys.excepthook is missing\nlost sys.stderr\n" + "FLAKY test__subprocess_interrupted.py", ++ ++###################################################### ++# Problems which should be investigated ++ ++# AttributeError: 'module' object has no attribute '_url_collapse_path_split' ++'monkey_test --Event test_httpservers.py', ++'monkey_test test_httpservers.py', ++ ++# AssertionError: The 304 response must have no body ++# and: ++# File "/home/users/jajcus/rpm/BUILD/gevent-1.0/gevent/hub.py", line 331, in s ++# return greenlet.switch(self) ++# Timeout: 1 second: test timed out ++'test__pywsgi.py', ++ ++###################################################### ++# Tests which fail when building with system libev ++ ++# test__core_stat.py fails on 32-bit builders when using system ++# libev ++# ++## Watcher reacted after 0.0019 seconds (write) ++## Watcher reacted after 0.0019 seconds (unlink) ++## Traceback (most recent call last): ++## File "test__core_stat.py", line 54, in ++## assert watcher.attr is None, watcher.attr ++## AssertionError: posix.stat_result(st_mode=2001, st_ino=0L, st_dev=581509237251768320L, st_nlink=1000, st_uid=0, st_gid=0, st_size=5983298792366014472L, st_atime=1393095309, st_mtime=0, st_ctime=-1) ++#* * * -u test__core_stat.py ++ ++ ++# When building with system libev the 'fileno()' method of the ++# loop object is not implemented. It seems to be used only be the ++# test code, though. ++ ++# | /usr/bin/python -u test__destroy.py ++# Traceback (most recent call last): ++# File "test__destroy.py", line 14, in ++# assert saved_loop.fileno() is None, saved_loop ++# AttributeError: 'gevent.core.loop' object has no attribute 'fileno' ++'test__destroy.py', ++ ++# | /usr/bin/python -u test_close_backend_fd.py ++# Traceback (most recent call last): ++# File "test_close_backend_fd.py", line 11, in ++# fileno = hub.loop.fileno() ++# AttributeError: 'gevent.core.loop' object has no attribute 'fileno' ++'test_close_backend_fd.py', ++ ++###################################################### ++# Tests which may fail on our builders ++ ++# attempts to bind to port 53 ++'test_ares_timeout.py', ++ ++# depends on external service ++'test__socket_ssl.py', ++ ++# depends on external URL accessibility ++'monkey_test test_urllib2net.py', ++'monkey_test --Event test_urllib2net.py', ++ ++# requires webpy, not in PLD ++# has expectations on local TCP ports availability ++'test___example_servers.py', ++ ++# File "test__socket.py", line 140, in test_sendall_timeout ++# self.assertRaises(self.TIMEOUT_ERROR, client.sendall, data_sent) ++# AssertionError: timeout not raised ++'test__socket.py', ++ ++# uses DNS and external URLs, ++# requires 'sendfile' python module ++'test__examples.py', ++ ++# expects local TCP port 6000 being available ++'test__example_echoserver.py' ++ + ] + + diff --git a/known_failures-pld.txt b/known_failures-pld.txt deleted file mode 100644 index 3461aa4..0000000 --- a/known_failures-pld.txt +++ /dev/null @@ -1,76 +0,0 @@ -###################################################### -# Problems which should be investigated - -# AttributeError: 'module' object has no attribute '_url_collapse_path_split' -* * * -u -m monkey_test --Event test_httpservers.py -* * * -u -m monkey_test test_httpservers.py - -# AssertionError: The 304 response must have no body -# and: -# File "/home/users/jajcus/rpm/BUILD/gevent-1.0/gevent/hub.py", line 331, in s -# return greenlet.switch(self) -# Timeout: 1 second: test timed out -* * * -u test__pywsgi.py - -###################################################### -# Tests which fail when building with system libev - -# test__core_stat.py fails on 32-bit builders when using system -# libev -# -## Watcher reacted after 0.0019 seconds (write) -## Watcher reacted after 0.0019 seconds (unlink) -## Traceback (most recent call last): -## File "test__core_stat.py", line 54, in -## assert watcher.attr is None, watcher.attr -## AssertionError: posix.stat_result(st_mode=2001, st_ino=0L, st_dev=581509237251768320L, st_nlink=1000, st_uid=0, st_gid=0, st_size=5983298792366014472L, st_atime=1393095309, st_mtime=0, st_ctime=-1) -#* * * -u test__core_stat.py - - -# When building with system libev the 'fileno()' method of the -# loop object is not implemented. It seems to be used only be the -# test code, though. - -# | /usr/bin/python -u test__destroy.py -# Traceback (most recent call last): -# File "test__destroy.py", line 14, in -# assert saved_loop.fileno() is None, saved_loop -# AttributeError: 'gevent.core.loop' object has no attribute 'fileno' -* * * -u test__destroy.py - -# | /usr/bin/python -u test_close_backend_fd.py -# Traceback (most recent call last): -# File "test_close_backend_fd.py", line 11, in -# fileno = hub.loop.fileno() -# AttributeError: 'gevent.core.loop' object has no attribute 'fileno' -* * * -u test_close_backend_fd.py - -###################################################### -# Tests which may fail on our builders - -# attempts to bind to port 53 -* * * -u test_ares_timeout.py - -# depends on external service -* * * -u test__socket_ssl.py - -# depends on external URL accessibility -* * * -u -m monkey_test test_urllib2net.py -* * * -u -m monkey_test --Event test_urllib2net.py - -# requires webpy, not in PLD -# has expectations on local TCP ports availability -* * * -u test___example_servers.py - -# File "test__socket.py", line 140, in test_sendall_timeout -# self.assertRaises(self.TIMEOUT_ERROR, client.sendall, data_sent) -# AssertionError: timeout not raised -* * * -u test__socket.py - -# uses DNS and external URLs, -# requires 'sendfile' python module -* * * -u test__examples.py - -# expects local TCP port 6000 being available -* * * -u test__example_echoserver.py - diff --git a/python-gevent.spec b/python-gevent.spec index b116164..c09e894 100644 --- a/python-gevent.spec +++ b/python-gevent.spec @@ -2,7 +2,7 @@ # TODO: # - SSL Broken with python 2.7.9 # https://github.com/gevent/gevent/issues/477 -# +# # - test__core_stat.py fails on 32-bit builds with system libev # investigate/fix that and enable system libev # @@ -21,10 +21,10 @@ Version: 1.0.1 Release: 1 License: MIT Group: Development/Languages -URL: http://www.gevent.org/ Source0: http://pypi.python.org/packages/source/g/gevent/%{module}-%{version}.tar.gz # Source0-md5: 7b952591d1a0174d6eb6ac47bd975ab6 -Source1: known_failures-pld.txt +Patch0: known_failures-pld.patch +URL: http://www.gevent.org/ %{?with_system_c_ares:BuildRequires: c-ares-devel >= 1.10.0} %{?with_system_libev:BuildRequires: libev-devel >= 4.11} #BuildRequires: python-Cython @@ -54,9 +54,7 @@ Features include: %prep %setup -q -n %{module}-%{version} -%if %{with tests} -cat known_failures.py %{SOURCE1} > known_failures-merged.py -%endif +%patch0 -p1 %build # when Cython-generated files are to be rebuilt @@ -71,7 +69,7 @@ CFLAGS="%{rpmcflags}" \ %if %{with tests} cd greentest -PYTHONPATH=.. python testrunner.py --config ../known_failures-merged.py +PYTHONPATH=.. python testrunner.py --config ../known_failures.py cd .. %endif -- 2.44.0