From 42bbcb2109fce82937f80acdd8f650eb705542be4a353a43c4c4814edabc4e43 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Thu, 12 Sep 2019 09:29:55 +0000 Subject: [PATCH 1/8] - Remove duplicate entry OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=111 --- python-tornado.changes | 5 +++++ python-tornado.spec | 6 ++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/python-tornado.changes b/python-tornado.changes index dd9ba59..ac14ca0 100644 --- a/python-tornado.changes +++ b/python-tornado.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Sep 12 09:29:42 UTC 2019 - Tomáš Chvátal + +- Remove duplicate entry + ------------------------------------------------------------------- Wed Aug 14 15:09:36 UTC 2019 - Todd R diff --git a/python-tornado.spec b/python-tornado.spec index 9d9e285..720c9b6 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -22,13 +22,11 @@ Version: 4.5.3 Release: 0 Summary: Open source version of scalable, non-blocking web server that power FriendFeed License: Apache-2.0 -Source0: README.suse Group: Development/Languages/Python -Url: http://www.tornadoweb.org -BuildRequires: %{pythons} +URL: http://www.tornadoweb.org +Source0: README.suse BuildRequires: python-rpm-macros Requires: python-tornado-impl = %{version} -Requires: python-tornado-impl = %{version} BuildArch: noarch %python_subpackages From 884c5752ad525d86ec3c41ebca846b90802eff680b24164f4a5ab680c7bf74c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 17 Sep 2019 11:03:59 +0000 Subject: [PATCH 2/8] - Provide %oldpython-tornado symbol too OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=112 --- python-tornado.changes | 5 +++++ python-tornado.spec | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/python-tornado.changes b/python-tornado.changes index ac14ca0..70fa8f3 100644 --- a/python-tornado.changes +++ b/python-tornado.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Sep 17 11:03:40 UTC 2019 - Tomáš Chvátal + +- Provide %oldpython-tornado symbol too + ------------------------------------------------------------------- Thu Sep 12 09:29:42 UTC 2019 - Tomáš Chvátal diff --git a/python-tornado.spec b/python-tornado.spec index 720c9b6..eb98039 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -16,6 +16,7 @@ # +%define oldpython %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-tornado Version: 4.5.3 @@ -27,6 +28,9 @@ URL: http://www.tornadoweb.org Source0: README.suse BuildRequires: python-rpm-macros Requires: python-tornado-impl = %{version} +%ifpython2 +Provides: %{oldpython}-tornado = %{version} +%endif BuildArch: noarch %python_subpackages From 5a9c7acffc96ef61f310be33db2574fd5a7a16aea3febc429389596fdd3abe8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 17 Sep 2019 18:04:51 +0000 Subject: [PATCH 3/8] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=113 --- python-tornado.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/python-tornado.spec b/python-tornado.spec index eb98039..aa4b56a 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -16,7 +16,7 @@ # -%define oldpython +%define oldpython python %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-tornado Version: 4.5.3 From 0d219f81414bcc5452aba43726a4c19fa3f4190f2cef9977d59fd940b5b401ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Wed, 18 Sep 2019 08:06:53 +0000 Subject: [PATCH 4/8] - Minimal version is 3.5 and as such remove 3.4 compat deps - Change this package back to latest python tornado to use same approach like we do with pytest - Reduce the conflicts even more - Remove cruft dependencies that should not be needed - Conflicts fixes - Use a different conflicts with other tornado versions. - Rename to python-tornado6 to handle version incompatibilities - Update to 6.0.3 + Bug fixes * `.gen.with_timeout` always treats ``asyncio.CancelledError`` as a ``quiet_exception`` (this improves compatibility with Python 3.8, which changed ``CancelledError`` to a ``BaseException``). * ``IOStream`` now checks for closed streams earlier, avoiding spurious logged errors in some situations (mainly with websockets). - Update to 6.0.2 + Bug fixes * `.WebSocketHandler.set_nodelay` works again. * Accessing ``HTTPResponse.body`` now returns an empty byte string instead of raising ``ValueError`` for error responses that don't have a body (it returned None in this case in Tornado 5). - Update to 6.0.1 + Bug fixes * Fixed issues with type annotations that caused errors while importing Tornado on Python 3.5.2. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=114 --- README.suse | 6 - python-tornado.changes | 571 ++++++++++++++++++++++++++++++++ python-tornado.spec | 56 +++- skip-failing-tests.patch | 40 +++ tornado-6.0.3.tar.gz | 3 + tornado-testsuite_timeout.patch | 20 ++ 6 files changed, 677 insertions(+), 19 deletions(-) delete mode 100644 README.suse create mode 100644 skip-failing-tests.patch create mode 100644 tornado-6.0.3.tar.gz create mode 100644 tornado-testsuite_timeout.patch diff --git a/README.suse b/README.suse deleted file mode 100644 index a6e8212..0000000 --- a/README.suse +++ /dev/null @@ -1,6 +0,0 @@ -This package should always depend on the preferred numbered -version of tornado, so "python-tornadoX" where "X" is the -major version number. - -Currently that is python-tornado4 as other packages -transition to this format diff --git a/python-tornado.changes b/python-tornado.changes index 70fa8f3..751c198 100644 --- a/python-tornado.changes +++ b/python-tornado.changes @@ -1,18 +1,40 @@ +------------------------------------------------------------------- +Wed Sep 18 07:58:23 UTC 2019 - Tomáš Chvátal + +- Minimal version is 3.5 and as such remove 3.4 compat deps +- Change this package back to latest python tornado to use + same approach like we do with pytest + ------------------------------------------------------------------- Tue Sep 17 11:03:40 UTC 2019 - Tomáš Chvátal - Provide %oldpython-tornado symbol too +------------------------------------------------------------------- +Tue Sep 17 11:03:20 UTC 2019 - Tomáš Chvátal + +- Reduce the conflicts even more + ------------------------------------------------------------------- Thu Sep 12 09:29:42 UTC 2019 - Tomáš Chvátal - Remove duplicate entry +------------------------------------------------------------------- +Thu Sep 12 09:27:05 UTC 2019 - Tomáš Chvátal + +- Remove cruft dependencies that should not be needed + ------------------------------------------------------------------- Wed Aug 14 15:09:36 UTC 2019 - Todd R - Switch to tornado 4 temporarily. +------------------------------------------------------------------- +Fri Aug 9 17:26:02 UTC 2019 - Todd R + +- Conflicts fixes + ------------------------------------------------------------------- Fri Aug 9 16:49:01 UTC 2019 - Todd R @@ -29,6 +51,555 @@ Fri Aug 9 16:30:37 UTC 2019 - Todd R * skip-failing-tests.patch * tornado-testsuite_timeout.patch +------------------------------------------------------------------- +Fri Aug 9 15:59:16 UTC 2019 - Todd R + +- Use a different conflicts with other tornado versions. + +------------------------------------------------------------------- +Mon Jul 29 16:15:27 UTC 2019 - Todd R + +- Rename to python-tornado6 to handle version incompatibilities +- Update to 6.0.3 + + Bug fixes + * `.gen.with_timeout` always treats ``asyncio.CancelledError`` as a + ``quiet_exception`` (this improves compatibility with Python 3.8, + which changed ``CancelledError`` to a ``BaseException``). + * ``IOStream`` now checks for closed streams earlier, avoiding + spurious logged errors in some situations (mainly with websockets). +- Update to 6.0.2 + + Bug fixes + * `.WebSocketHandler.set_nodelay` works again. + * Accessing ``HTTPResponse.body`` now returns an empty byte string + instead of raising ``ValueError`` for error responses that don't + have a body (it returned None in this case in Tornado 5). +- Update to 6.0.1 + + Bug fixes + * Fixed issues with type annotations that caused errors while + importing Tornado on Python 3.5.2. +- Update to 6.0.0 + + Backwards-incompatible changes + * Python 2.7 and 3.4 are no longer supported; the minimum supported + Python version is 3.5.2. + * APIs deprecated in Tornado 5.1 have been removed. This includes the + ``tornado.stack_context`` module and most ``callback`` arguments + throughout the package. All removed APIs emitted + `DeprecationWarning` when used in Tornado 5.1, so running your + application with the ``-Wd`` Python command-line flag or the + environment variable ``PYTHONWARNINGS=d`` should tell you whether + your application is ready to move to Tornado 6.0. + * ``.WebSocketHandler.get`` is now a coroutine and must be called + accordingly in any subclasses that override this method (but note + that overriding ``get`` is not recommended; either ``prepare`` or + ``open`` should be used instead). + + General changes + * Tornado now includes type annotations compatible with ``mypy``. + These annotations will be used when type-checking your application + with ``mypy``, and may be usable in editors and other tools. + * Tornado now uses native coroutines internally, improving performance. + + tornado.auth + * All ``callback`` arguments in this package have been removed. Use + the coroutine interfaces instead. + * The ``OAuthMixin._oauth_get_user`` method has been removed. + Override `~.OAuthMixin._oauth_get_user_future` instead. + + tornado.concurrent + * The ``callback`` argument to `.run_on_executor` has been removed. + * ``return_future`` has been removed. + + tornado.gen + * Some older portions of this module have been removed. This includes + ``engine``, ``YieldPoint``, ``Callback``, ``Wait``, ``WaitAll``, + ``MultiYieldPoint``, and ``Task``. + * Functions decorated with ``@gen.coroutine`` no longer accept + ``callback`` arguments. + + tornado.httpclient + * The behavior of ``raise_error=False`` has changed. Now only + suppresses the errors raised due to completed responses with non-200 + status codes (previously it suppressed all errors). + * The ``callback`` argument to `.AsyncHTTPClient.fetch` has been removed. + + tornado.httputil + * ``HTTPServerRequest.write`` has been removed. Use the methods of + ``request.connection`` instead. + * Unrecognized ``Content-Encoding`` values now log warnings only for + content types that we would otherwise attempt to parse. + + tornado.ioloop + * ``IOLoop.set_blocking_signal_threshold``, + ``IOLoop.set_blocking_log_threshold``, ``IOLoop.log_stack``, + and ``IOLoop.handle_callback_exception`` have been removed. + * Improved performance of `.IOLoop.add_callback`. + + tornado.iostream + * All ``callback`` arguments in this module have been removed except + for `.BaseIOStream.set_close_callback`. + * ``streaming_callback`` arguments to `.BaseIOStream.read_bytes` and + `.BaseIOStream.read_until_close` have been removed. + * Eliminated unnecessary logging of "Errno 0". + + tornado.log + * Log files opened by this module are now explicitly set to UTF-8 encoding. + + tornado.netutil + * The results of ``getaddrinfo`` are now sorted by address family to + avoid partial failures and deadlocks. + + tornado.platform.twisted + * ``TornadoReactor`` and ``TwistedIOLoop`` have been removed. + + tornado.simple_httpclient + * The default HTTP client now supports the ``network_interface`` + request argument to specify the source IP for the connection. + * If a server returns a 3xx response code without a ``Location`` + header, the response is raised or returned directly instead of + trying and failing to follow the redirect. + * When following redirects, methods other than ``POST`` will no longer + be transformed into ``GET`` requests. 301 (permanent) redirects are + now treated the same way as 302 (temporary) and 303 (see other) + redirects in this respect. + * Following redirects now works with ``body_producer``. + + tornado.stack_context + * The ``tornado.stack_context`` module has been removed. + + tornado.tcpserver + * `.TCPServer.start` now supports a ``max_restarts`` argument (same as + `.fork_processes`). + + tornado.testing + * `.AsyncHTTPTestCase` now drops all references to the `.Application` + during ``tearDown``, allowing its memory to be reclaimed sooner. + * `.AsyncTestCase` now cancels all pending coroutines in ``tearDown``, + in an effort to reduce warnings from the python runtime about + coroutines that were not awaited. Note that this may cause + ``asyncio.CancelledError`` to be logged in other places. Coroutines + that expect to be running at test shutdown may need to catch this + exception. + + tornado.web + * The ``asynchronous`` decorator has been removed. + * The ``callback`` argument to `.RequestHandler.flush` has been removed. + * `.StaticFileHandler` now supports large negative values for the + ``Range`` header and returns an appropriate error for ``end > + start``. + * It is now possible to set ``expires_days`` in ``xsrf_cookie_kwargs``. + + tornado.websocket + * Pings and other messages sent while the connection is closing are + now silently dropped instead of logging exceptions. + * Errors raised by ``open()`` are now caught correctly when this method + is a coroutine. + + tornado.wsgi + * ``WSGIApplication`` and ``WSGIAdapter`` have been removed. +- Rebase patches: + * tornado-testsuite_timeout.patch + * skip-failing-tests.patch +- Remove upstream-included openssl-cert-size.patch + + +------------------------------------------------------------------- +Mon Jul 29 16:04:26 UTC 2019 - Todd R + +- Rename to python-tornado5 to handle version incompatibilities +- Update to 5.1.1 + + Bug fixes + * Fixed an case in which the `.Future` returned by + `.RequestHandler.finish` could fail to resolve. + * The `.TwitterMixin.authenticate_redirect` method works again. + * Improved error handling in the `tornado.auth` module, fixing hanging + requests when a network or other error occurs. +- Update to 5.1.0 + + Deprecation notice + * Tornado 6.0 will drop support for Python 2.7 and 3.4. The minimum + supported Python version will be 3.5.2. + * The ``tornado.stack_context`` module is deprecated and will be removed + in Tornado 6.0. The reason for this is that it is not feasible to + provide this module's semantics in the presence of ``async def`` + native coroutines. ``ExceptionStackContext`` is mainly obsolete + thanks to coroutines. ``StackContext`` lacks a direct replacement + although the new ``contextvars`` package (in the Python standard + library beginning in Python 3.7) may be an alternative. + * Callback-oriented code often relies on ``ExceptionStackContext`` to + handle errors and prevent leaked connections. In order to avoid the + risk of silently introducing subtle leaks (and to consolidate all of + Tornado's interfaces behind the coroutine pattern), ``callback`` + arguments throughout the package are deprecated and will be removed + in version 6.0. All functions that had a ``callback`` argument + removed now return a `.Future` which should be used instead. + * Where possible, deprecation warnings are emitted when any of these + deprecated interfaces is used. However, Python does not display + deprecation warnings by default. To prepare your application for + Tornado 6.0, run Python with the ``-Wd`` argument or set the + environment variable ``PYTHONWARNINGS`` to ``d``. If your + application runs on Python 3 without deprecation warnings, it should + be able to move to Tornado 6.0 without disruption. + + tornado.auth + * `.OAuthMixin._oauth_get_user_future` may now be a native coroutine. + * All ``callback`` arguments in this package are deprecated and will + be removed in 6.0. Use the coroutine interfaces instead. + * The ``OAuthMixin._oauth_get_user`` method is deprecated and will be removed in + 6.0. Override `~.OAuthMixin._oauth_get_user_future` instead. + + tornado.autoreload + * The command-line autoreload wrapper is now preserved if an internal + autoreload fires. + * The command-line wrapper no longer starts duplicated processes on windows + when combined with internal autoreload. + + tornado.concurrent + * `.run_on_executor` now returns `.Future` objects that are compatible + with ``await``. + * The ``callback`` argument to `.run_on_executor` is deprecated and will + be removed in 6.0. + * ``return_future`` is deprecated and will be removed in 6.0. + + tornado.gen + * Some older portions of this module are deprecated and will be removed + in 6.0. This includes ``engine``, ``YieldPoint``, ``Callback``, + ``Wait``, ``WaitAll``, ``MultiYieldPoint``, and ``Task``. + * Functions decorated with ``@gen.coroutine`` will no longer accept + ``callback`` arguments in 6.0. + + tornado.httpclient + * The behavior of ``raise_error=False`` is changing in 6.0. Currently + it suppresses all errors; in 6.0 it will only suppress the errors + raised due to completed responses with non-200 status codes. + * The ``callback`` argument to `.AsyncHTTPClient.fetch` is deprecated + and will be removed in 6.0. + * `tornado.httpclient.HTTPError` has been renamed to + `.HTTPClientError` to avoid ambiguity in code that also has to deal + with `tornado.web.HTTPError`. The old name remains as an alias. + * ``tornado.curl_httpclient`` now supports non-ASCII characters in + username and password arguments. + * ``.HTTPResponse.request_time`` now behaves consistently across + ``simple_httpclient`` and ``curl_httpclient``, excluding time spent + in the ``max_clients`` queue in both cases (previously this time was + included in ``simple_httpclient`` but excluded in + ``curl_httpclient``). In both cases the time is now computed using + a monotonic clock where available. + * `.HTTPResponse` now has a ``start_time`` attribute recording a + wall-clock (`time.time`) timestamp at which the request started + (after leaving the ``max_clients`` queue if applicable). + + tornado.httputil + * `.parse_multipart_form_data` now recognizes non-ASCII filenames in + RFC 2231/5987 (``filename*=``) format. + * ``HTTPServerRequest.write`` is deprecated and will be removed in 6.0. Use + the methods of ``request.connection`` instead. + * Malformed HTTP headers are now logged less noisily. + + tornado.ioloop + * `.PeriodicCallback` now supports a ``jitter`` argument to randomly + vary the timeout. + * ``IOLoop.set_blocking_signal_threshold``, + ``IOLoop.set_blocking_log_threshold``, ``IOLoop.log_stack``, + and ``IOLoop.handle_callback_exception`` are deprecated and will + be removed in 6.0. + * Fixed a `KeyError` in `.IOLoop.close` when `.IOLoop` objects are + being opened and closed in multiple threads. + + tornado.iostream + * All ``callback`` arguments in this module are deprecated except for + `.BaseIOStream.set_close_callback`. They will be removed in 6.0. + * ``streaming_callback`` arguments to `.BaseIOStream.read_bytes` and + `.BaseIOStream.read_until_close` are deprecated and will be removed + in 6.0. + + tornado.netutil + * Improved compatibility with GNU Hurd. + + tornado.options + * `tornado.options.parse_config_file` now allows setting options to + strings (which will be parsed the same way as + `tornado.options.parse_command_line`) in addition to the specified + type for the option. + + tornado.platform.twisted + * ``TornadoReactor`` and ``TwistedIOLoop`` are deprecated and will be + removed in 6.0. Instead, Tornado will always use the asyncio event loop + and twisted can be configured to do so as well. +``tornado.stack_context`` + * The ``tornado.stack_context`` module is deprecated and will be removed + in 6.0. + + tornado.testing + * `.AsyncHTTPTestCase.fetch` now takes a ``raise_error`` argument. + This argument has the same semantics as `.AsyncHTTPClient.fetch`, + but defaults to false because tests often need to deal with non-200 + responses (and for backwards-compatibility). + * The `.AsyncTestCase.stop` and `.AsyncTestCase.wait` methods are + deprecated. + + tornado.web + * New method `.RequestHandler.detach` can be used from methods + that are not decorated with ``@asynchronous`` (the decorator + was required to use ``self.request.connection.detach()``. + * `.RequestHandler.finish` and `.RequestHandler.render` now return + ``Futures`` that can be used to wait for the last part of the + response to be sent to the client. + * `.FallbackHandler` now calls ``on_finish`` for the benefit of + subclasses that may have overridden it. + * The ``asynchronous`` decorator is deprecated and will be removed in 6.0. + * The ``callback`` argument to `.RequestHandler.flush` is deprecated + and will be removed in 6.0. + + tornado.websocket + * When compression is enabled, memory limits now apply to the + post-decompression size of the data, protecting against DoS attacks. + * `.websocket_connect` now supports subprotocols. + * `.WebSocketHandler` and `.WebSocketClientConnection` now have + ``selected_subprotocol`` attributes to see the subprotocol in use. + * The `.WebSocketHandler.select_subprotocol` method is now called with + an empty list instead of a list containing an empty string if no + subprotocols were requested by the client. + * `.WebSocketHandler.open` may now be a coroutine. + * The ``data`` argument to `.WebSocketHandler.ping` is now optional. + * Client-side websocket connections no longer buffer more than one + message in memory at a time. + * Exception logging now uses `.RequestHandler.log_exception`. + + tornado.wsgi + * ``WSGIApplication`` and ``WSGIAdapter`` are deprecated and will be removed + in Tornado 6.0. +- Update to 5.0.2 + + Bug fixes + * Fixed a memory leak when `.IOLoop` objects are created and destroyed. + * If `.AsyncTestCase.get_new_ioloop` returns a reference to a + preexisting event loop (typically when it has been overridden to + return `.IOLoop.current()`), the test's ``tearDown`` method will not + close this loop. + * Fixed a confusing error message when the synchronous `.HTTPClient` + fails to initialize because an event loop is already running. + * `.PeriodicCallback` no longer executes twice in a row due to + backwards clock adjustments. +- Update to 5.0.1 + + Bug fix + * This release restores support for versions of Python 3.4 prior to + 3.4.4. This is important for compatibility with Debian Jessie which + has 3.4.2 as its version of Python 3. + + Highlights + * The focus of this release is improving integration with `asyncio`. + On Python 3, the `.IOLoop` is always a wrapper around the `asyncio` + event loop, and `asyncio.Future` and `asyncio.Task` are used instead + of their Tornado counterparts. This means that libraries based on + `asyncio` can be mixed relatively seamlessly with those using + Tornado. While care has been taken to minimize the disruption from + this change, code changes may be required for compatibility with + Tornado 5.0, as detailed in the following section. + * Tornado 5.0 supports Python 2.7.9+ and 3.4+. Python 2.7 and 3.4 are + deprecated and support for them will be removed in Tornado 6.0, + which will require Python 3.5+. ++ Backwards-compatibility notes + * Python 3.3 is no longer supported. + * Versions of Python 2.7 that predate the `ssl` module update are no + longer supported. (The `ssl` module was updated in version 2.7.9, + although in some distributions the updates are present in builds + with a lower version number. Tornado requires `ssl.SSLContext`, + `ssl.create_default_context`, and `ssl.match_hostname`) + * Versions of Python 3.5 prior to 3.5.2 are no longer supported due to + a change in the async iterator protocol in that version. + * The ``trollius`` project (`asyncio` backported to Python 2) is no + longer supported. + * `tornado.concurrent.Future` is now an alias for `asyncio.Future` + when running on Python 3. This results in a number of minor + behavioral changes: + > `.Future` objects can only be created while there is a current + `.IOLoop` + > The timing of callbacks scheduled with + ``Future.add_done_callback`` has changed. + `tornado.concurrent.future_add_done_callback` can be used to + make the behavior more like older versions of Tornado (but not + identical). Some of these changes are also present in the Python + 2 version of `tornado.concurrent.Future` to minimize the + difference between Python 2 and 3. + > Cancellation is now partially supported, via + `asyncio.Future.cancel`. A canceled `.Future` can no longer have + its result set. Applications that handle `~asyncio.Future` + objects directly may want to use + `tornado.concurrent.future_set_result_unless_cancelled`. In + native coroutines, cancellation will cause an exception to be + raised in the coroutine. + > The ``exc_info`` and ``set_exc_info`` methods are no longer + present. Use `tornado.concurrent.future_set_exc_info` to replace + the latter, and raise the exception with + `~asyncio.Future.result` to replace the former. + * ``io_loop`` arguments to many Tornado functions have been removed. + Use `.IOLoop.current()` instead of passing `.IOLoop` objects + explicitly. + * On Python 3, `.IOLoop` is always a wrapper around the `asyncio` + event loop. ``IOLoop.configure`` is effectively removed on Python 3 + (for compatibility, it may be called to redundantly specify the + `asyncio`-backed `.IOLoop`) + * `.IOLoop.instance` is now a deprecated alias for `.IOLoop.current`. + Applications that need the cross-thread communication behavior + facilitated by `.IOLoop.instance` should use their own global variable + instead. + + Other notes + * The ``futures`` (`concurrent.futures` backport) package is now required + on Python 2.7. + * The ``certifi`` and ``backports.ssl-match-hostname`` packages are no + longer required on Python 2.7. + * Python 3.6 or higher is recommended, because it features more + efficient garbage collection of `asyncio.Future` objects. + + tornado.auth + * `.GoogleOAuth2Mixin` now uses a newer set of URLs. + + tornado.autoreload + * On Python 3, uses ``__main__.__spec`` to more reliably reconstruct + the original command line and avoid modifying ``PYTHONPATH``. + * The ``io_loop`` argument to `tornado.autoreload.start` has been removed. + + tornado.concurrent + * `tornado.concurrent.Future` is now an alias for `asyncio.Future` + when running on Python 3. See "Backwards-compatibility notes" for + more. + * Setting the result of a ``Future`` no longer blocks while callbacks + are being run. Instead, the callbacks are scheduled on the next + `.IOLoop` iteration. + * The deprecated alias ``tornado.concurrent.TracebackFuture`` has been + removed. + * `tornado.concurrent.chain_future` now works with all three kinds of + ``Futures`` (Tornado, `asyncio`, and `concurrent.futures`) + * The ``io_loop`` argument to `tornado.concurrent.run_on_executor` has + been removed. + * New functions `.future_set_result_unless_cancelled`, + `.future_set_exc_info`, and `.future_add_done_callback` help mask + the difference between `asyncio.Future` and Tornado's previous + ``Future`` implementation. + + tornado.curl_httpclient + * Improved debug logging on Python 3. + * The ``time_info`` response attribute now includes ``appconnect`` in + addition to other measurements. + * Closing a `.CurlAsyncHTTPClient` now breaks circular references that + could delay garbage collection. + * The ``io_loop`` argument to the `.CurlAsyncHTTPClient` constructor + has been removed. + + tornado.gen + * ``tornado.gen.TimeoutError`` is now an alias for + `tornado.util.TimeoutError`. + * Leak detection for ``Futures`` created by this module now attributes + them to their proper caller instead of the coroutine machinery. + * Several circular references that could delay garbage collection have + been broken up. + * On Python 3, `asyncio.Task` is used instead of the Tornado coroutine + runner. This improves compatibility with some `asyncio` libraries + and adds support for cancellation. + * The ``io_loop`` arguments to ``YieldFuture`` and `.with_timeout` have + been removed. + + tornado.httpclient + * The ``io_loop`` argument to all `.AsyncHTTPClient` constructors has + been removed. + + tornado.httpserver + * It is now possible for a client to reuse a connection after sending + a chunked request. + * If a client sends a malformed request, the server now responds with + a 400 error instead of simply closing the connection. + * ``Content-Length`` and ``Transfer-Encoding`` headers are no longer + sent with 1xx or 204 responses (this was already true of 304 + responses). + * When closing a connection to a HTTP/1.1 client, the ``Connection: + close`` header is sent with the response. + * The ``io_loop`` argument to the `.HTTPServer` constructor has been + removed. + * If more than one ``X-Scheme`` or ``X-Forwarded-Proto`` header is + present, only the last is used. + + tornado.httputil + * The string representation of `.HTTPServerRequest` objects (which are + sometimes used in log messages) no longer includes the request + headers. + * New function `.qs_to_qsl` converts the result of + `urllib.parse.parse_qs` to name-value pairs. + + tornado.ioloop + * ``tornado.ioloop.TimeoutError`` is now an alias for + `tornado.util.TimeoutError`. + * `.IOLoop.instance` is now a deprecated alias for `.IOLoop.current`. + * `.IOLoop.install` and `.IOLoop.clear_instance` are deprecated. + * The ``IOLoop.initialized`` method has been removed. + * On Python 3, the `asyncio`-backed `.IOLoop` is always used and + alternative `.IOLoop` implementations cannot be configured. + `.IOLoop.current` and related methods pass through to + `asyncio.get_event_loop`. + * `~.IOLoop.run_sync` cancels its argument on a timeout. This + results in better stack traces (and avoids log messages about leaks) + in native coroutines. + * New methods `.IOLoop.run_in_executor` and + `.IOLoop.set_default_executor` make it easier to run functions in + other threads from native coroutines (since + `concurrent.futures.Future` does not support ``await``). + * ``PollIOLoop`` (the default on Python 2) attempts to detect misuse + of `.IOLoop` instances across `os.fork`. + * The ``io_loop`` argument to `.PeriodicCallback` has been removed. + * It is now possible to create a `.PeriodicCallback` in one thread + and start it in another without passing an explicit event loop. + * The ``IOLoop.set_blocking_signal_threshold`` and + ``IOLoop.set_blocking_log_threshold`` methods are deprecated because + they are not implemented for the `asyncio` event loop`. Use the + ``PYTHONASYNCIODEBUG=1`` environment variable instead. + * `.IOLoop.clear_current` now works if it is called before any + current loop is established. + + tornado.iostream + * The ``io_loop`` argument to the `.IOStream` constructor has been removed. + * New method `.BaseIOStream.read_into` provides a minimal-copy alternative to + `.BaseIOStream.read_bytes`. + * `.BaseIOStream.write` is now much more efficient for very large amounts of data. + * Fixed some cases in which ``IOStream.error`` could be inaccurate. + * Writing a `memoryview` can no longer result in "BufferError: + Existing exports of data: object cannot be re-sized". + + tornado.locks + * As a side effect of the ``Future`` changes, waiters are always + notified asynchronously with respect to `.Condition.notify`. + + tornado.netutil + * The default `.Resolver` now uses `.IOLoop.run_in_executor`. + `.ExecutorResolver`, `.BlockingResolver`, and `.ThreadedResolver` are + deprecated. + * The ``io_loop`` arguments to `.add_accept_handler`, + `.ExecutorResolver`, and `.ThreadedResolver` have been removed. + * `.add_accept_handler` returns a callable which can be used to remove + all handlers that were added. + * `.OverrideResolver` now accepts per-family overrides. + + tornado.options + * Duplicate option names are now detected properly whether they use + hyphens or underscores. + + tornado.platform.asyncio + * `.AsyncIOLoop` and `.AsyncIOMainLoop` are now used automatically + when appropriate; referencing them explicitly is no longer + recommended. + * Starting an `.IOLoop` or making it current now also sets the + `asyncio` event loop for the current thread. Closing an `.IOLoop` + closes the corresponding `asyncio` event loop. + * `.to_tornado_future` and `.to_asyncio_future` are deprecated since + they are now no-ops. + * `~.AnyThreadEventLoopPolicy` can now be used to easily allow the creation + of event loops on any thread (similar to Tornado's prior policy). + + tornado.platform.caresresolver + * The ``io_loop`` argument to `.CaresResolver` has been removed. + + tornado.platform.twisted + * The ``io_loop`` arguments to ``TornadoReactor``, `.TwistedResolver`, + and ``tornado.platform.twisted.install`` have been removed. + + tornado.process + * The ``io_loop`` argument to the `.Subprocess` constructor and + `.Subprocess.initialize` has been removed. + + tornado.routing + * A default 404 response is now generated if no delegate is found for + a request. + + tornado.simple_httpclient + * The ``io_loop`` argument to `.SimpleAsyncHTTPClient` has been removed. + * TLS is now configured according to `ssl.create_default_context` by + default. + + tornado.tcpclient + * The ``io_loop`` argument to the `.TCPClient` constructor has been + removed. + * `.TCPClient.connect` has a new ``timeout`` argument. + + tornado.tcpserver + * The ``io_loop`` argument to the `.TCPServer` constructor has been + removed. + * `.TCPServer` no longer logs ``EBADF`` errors during shutdown. + + tornado.testing + * The deprecated ``tornado.testing.get_unused_port`` and + ``tornado.testing.LogTrapTestCase`` have been removed. + * `.AsyncHTTPTestCase.fetch` now supports absolute URLs. + * `.AsyncHTTPTestCase.fetch` now connects to ``127.0.0.1`` + instead of ``localhost`` to be more robust against faulty + ipv6 configurations. + + tornado.util + * `tornado.util.TimeoutError` replaces ``tornado.gen.TimeoutError`` + and ``tornado.ioloop.TimeoutError``. + * `.Configurable` now supports configuration at multiple levels of an + inheritance hierarchy. + + tornado.web + * `.RequestHandler.set_status` no longer requires that the given + status code appear in `http.client.responses`. + * It is no longer allowed to send a body with 1xx or 204 responses. + * Exception handling now breaks up reference cycles that could delay + garbage collection. + * `.RedirectHandler` now copies any query arguments from the request + to the redirect location. + * If both ``If-None-Match`` and ``If-Modified-Since`` headers are present + in a request to `.StaticFileHandler`, the latter is now ignored. + + tornado.websocket + * The C accelerator now operates on multiple bytes at a time to + improve performance. + * Requests with invalid websocket headers now get a response with + status code 400 instead of a closed connection. + * `.WebSocketHandler.write_message` now raises `.WebSocketClosedError` if + the connection closes while the write is in progress. + * The ``io_loop`` argument to `.websocket_connect` has been removed. +- Rebase patches: + * tornado-testsuite_timeout.patch + * skip-failing-tests.patch +- Remove upstream-included asyncio.patch + ------------------------------------------------------------------- Thu Mar 7 11:27:44 UTC 2019 - Tomáš Chvátal diff --git a/python-tornado.spec b/python-tornado.spec index aa4b56a..d63f997 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -16,22 +16,32 @@ # -%define oldpython python %{?!python_module:%define python_module() python-%{**} python3-%{**}} +%define skip_python2 1 Name: python-tornado -Version: 4.5.3 +Version: 6.0.3 Release: 0 Summary: Open source version of scalable, non-blocking web server that power FriendFeed License: Apache-2.0 Group: Development/Languages/Python URL: http://www.tornadoweb.org -Source0: README.suse +Source: https://files.pythonhosted.org/packages/source/t/tornado/tornado-%{version}.tar.gz +Patch1: tornado-testsuite_timeout.patch +Patch2: skip-failing-tests.patch +BuildRequires: %{python_module base >= 3.5} +BuildRequires: %{python_module certifi} +BuildRequires: %{python_module devel} +BuildRequires: %{python_module pycurl} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module simplejson} +BuildRequires: fdupes BuildRequires: python-rpm-macros -Requires: python-tornado-impl = %{version} -%ifpython2 -Provides: %{oldpython}-tornado = %{version} -%endif -BuildArch: noarch +Requires: python +Requires: python-simplejson +Recommends: python-Twisted +Recommends: python-pycares +Recommends: python-pycurl +Recommends: python-service_identity %python_subpackages %description @@ -51,16 +61,36 @@ FriendFeed servers. (For more information on scaling servers to support thousands of clients, see The C10K problem.) %prep -%setup -q -T -c -cp %{SOURCE0} . +%setup -q -n tornado-%{version} +# Fix non-executable script rpmlint issue: +find demos tornado -name "*.py" -exec sed -i "/#\!\/usr\/bin\/.*/d" {} \; +%patch1 -p1 +%patch2 -p1 + +%pre +# remove egg-info _file_, being replaced by an egg-info directory +if [ -f %{python_sitearch}/tornado-%{version}-py%{python_version}.egg-info ]; then + rm %{python_sitearch}/tornado-%{version}-py%{python_version}.egg-info +fi %build -# None +%python_build %install -# None +%python_install +%fdupes -s demos +%python_expand rm -r %{buildroot}%{$python_sitearch}/tornado/test +%python_expand %fdupes %{buildroot}%{$python_sitearch} + +%check +export ASYNC_TEST_TIMEOUT=30 +export PYTHONDONTWRITEBYTECODE=1 +%python_exec -m tornado.test.runtests %files %{python_files} -%doc README.suse +%license LICENSE +%doc demos +%{python_sitearch}/tornado +%{python_sitearch}/tornado-%{version}-py*.egg-info %changelog diff --git a/skip-failing-tests.patch b/skip-failing-tests.patch new file mode 100644 index 0000000..bb7a1df --- /dev/null +++ b/skip-failing-tests.patch @@ -0,0 +1,40 @@ +From: Benjamin Drung +Date: Tue, 18 Dec 2018 18:35:28 +0100 +Subject: [PATCH] Skip failing openssl 1.1.1 tests (for now) + +Four tests fail when using openssl 1.1.1 with TLS 1.3 support. Disable +these tests for now. Please fix the bug and re-enable them again. + +Bug: https://github.com/tornadoweb/tornado/issues/2536 +--- + tornado/test/iostream_test.py | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/tornado/test/iostream_test.py b/tornado/test/iostream_test.py +index 56fffe6..b1d5f5d 100644 +--- a/tornado/test/iostream_test.py ++++ b/tornado/test/iostream_test.py +@@ -166,6 +166,7 @@ class TestReadWriteMixin(object): + raise NotImplementedError + + @gen_test ++ @unittest.skip("Failing when using openssl 1.1.1 with TLS 1.3 support. See https://github.com/tornadoweb/tornado/issues/2536") + def test_write_zero_bytes(self): + # Attempting to write zero bytes should run the callback without + # going into an infinite loop. +@@ -217,6 +218,7 @@ class TestReadWriteMixin(object): + rs.close() + + @gen_test ++ @unittest.skip("Failing when using openssl 1.1.1 with TLS 1.3 support. See https://github.com/tornadoweb/tornado/issues/2536") + def test_read_until_close_after_close(self): + # Similar to test_delayed_close_callback, but read_until_close takes + # a separate code path so test it separately. +@@ -736,6 +738,7 @@ class TestIOStreamMixin(object): + @skipIfNonUnix + @skipPypy3V58 + @gen_test ++ @unittest.skip("Failing when using openssl 1.1.1 with TLS 1.3 support. See https://github.com/tornadoweb/tornado/issues/2536") + def test_inline_read_error(self): + # An error on an inline read is raised without logging (on the + # assumption that it will eventually be noticed or logged further diff --git a/tornado-6.0.3.tar.gz b/tornado-6.0.3.tar.gz new file mode 100644 index 0000000..381d2d0 --- /dev/null +++ b/tornado-6.0.3.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c845db36ba616912074c5b1ee897f8e0124df269468f25e4fe21fe72f6edd7a9 +size 482444 diff --git a/tornado-testsuite_timeout.patch b/tornado-testsuite_timeout.patch new file mode 100644 index 0000000..1b8bb1b --- /dev/null +++ b/tornado-testsuite_timeout.patch @@ -0,0 +1,20 @@ +--- tornado-6.0.3/tornado/test/testing_test.py 2018/03/16 13:18:44 1.1 ++++ tornado-6.0.3/tornado/test/testing_test.py 2018/03/16 13:18:56 +@@ -54,7 +54,7 @@ + self.io_loop.add_timeout(self.io_loop.time() + 0.00, self.stop) + self.wait(timeout=0.02) + self.io_loop.add_timeout(self.io_loop.time() + 0.03, self.stop) +- self.wait(timeout=0.15) ++ self.wait(timeout=0.25) + + + class LeakTest(AsyncTestCase): +@@ -262,7 +262,7 @@ + self.finished = True + + def test_timeout_environment_variable(self): +- @gen_test(timeout=0.5) ++ @gen_test(timeout=0.9) + def test_long_timeout(self): + yield gen.sleep(0.25) + From 474435d7a3990d2a5aea7f45dc763f0bdc2fcc1964442266256d8115c200bca8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Thu, 19 Sep 2019 07:57:37 +0000 Subject: [PATCH 5/8] - Provide and obsolete python-toro that was integrated in tornado OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=115 --- python-tornado.changes | 5 +++++ python-tornado.spec | 2 ++ 2 files changed, 7 insertions(+) diff --git a/python-tornado.changes b/python-tornado.changes index 751c198..751c099 100644 --- a/python-tornado.changes +++ b/python-tornado.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Sep 19 07:56:21 UTC 2019 - Tomáš Chvátal + +- Provide and obsolete python-toro that was integrated in tornado + ------------------------------------------------------------------- Wed Sep 18 07:58:23 UTC 2019 - Tomáš Chvátal diff --git a/python-tornado.spec b/python-tornado.spec index d63f997..1a3ee6c 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -42,6 +42,8 @@ Recommends: python-Twisted Recommends: python-pycares Recommends: python-pycurl Recommends: python-service_identity +Provides: python-toro = %{version} +Obsoletes: python-toro < %{version} %python_subpackages %description From ca62df0887da8279e89c68d6ca0a71ffddf9f195a5209f07d483371ad792baa7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 1 Oct 2019 13:32:39 +0000 Subject: [PATCH 6/8] Accepting request 734330 from devel:languages:python OBS-URL: https://build.opensuse.org/request/show/734330 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=116 --- README.suse | 6 + python-tornado.changes | 586 -------------------------------- python-tornado.spec | 58 +--- skip-failing-tests.patch | 40 --- tornado-6.0.3.tar.gz | 3 - tornado-testsuite_timeout.patch | 20 -- 6 files changed, 18 insertions(+), 695 deletions(-) create mode 100644 README.suse delete mode 100644 skip-failing-tests.patch delete mode 100644 tornado-6.0.3.tar.gz delete mode 100644 tornado-testsuite_timeout.patch diff --git a/README.suse b/README.suse new file mode 100644 index 0000000..a6e8212 --- /dev/null +++ b/README.suse @@ -0,0 +1,6 @@ +This package should always depend on the preferred numbered +version of tornado, so "python-tornadoX" where "X" is the +major version number. + +Currently that is python-tornado4 as other packages +transition to this format diff --git a/python-tornado.changes b/python-tornado.changes index 751c099..dd9ba59 100644 --- a/python-tornado.changes +++ b/python-tornado.changes @@ -1,45 +1,8 @@ -------------------------------------------------------------------- -Thu Sep 19 07:56:21 UTC 2019 - Tomáš Chvátal - -- Provide and obsolete python-toro that was integrated in tornado - -------------------------------------------------------------------- -Wed Sep 18 07:58:23 UTC 2019 - Tomáš Chvátal - -- Minimal version is 3.5 and as such remove 3.4 compat deps -- Change this package back to latest python tornado to use - same approach like we do with pytest - -------------------------------------------------------------------- -Tue Sep 17 11:03:40 UTC 2019 - Tomáš Chvátal - -- Provide %oldpython-tornado symbol too - -------------------------------------------------------------------- -Tue Sep 17 11:03:20 UTC 2019 - Tomáš Chvátal - -- Reduce the conflicts even more - -------------------------------------------------------------------- -Thu Sep 12 09:29:42 UTC 2019 - Tomáš Chvátal - -- Remove duplicate entry - -------------------------------------------------------------------- -Thu Sep 12 09:27:05 UTC 2019 - Tomáš Chvátal - -- Remove cruft dependencies that should not be needed - ------------------------------------------------------------------- Wed Aug 14 15:09:36 UTC 2019 - Todd R - Switch to tornado 4 temporarily. -------------------------------------------------------------------- -Fri Aug 9 17:26:02 UTC 2019 - Todd R - -- Conflicts fixes - ------------------------------------------------------------------- Fri Aug 9 16:49:01 UTC 2019 - Todd R @@ -56,555 +19,6 @@ Fri Aug 9 16:30:37 UTC 2019 - Todd R * skip-failing-tests.patch * tornado-testsuite_timeout.patch -------------------------------------------------------------------- -Fri Aug 9 15:59:16 UTC 2019 - Todd R - -- Use a different conflicts with other tornado versions. - -------------------------------------------------------------------- -Mon Jul 29 16:15:27 UTC 2019 - Todd R - -- Rename to python-tornado6 to handle version incompatibilities -- Update to 6.0.3 - + Bug fixes - * `.gen.with_timeout` always treats ``asyncio.CancelledError`` as a - ``quiet_exception`` (this improves compatibility with Python 3.8, - which changed ``CancelledError`` to a ``BaseException``). - * ``IOStream`` now checks for closed streams earlier, avoiding - spurious logged errors in some situations (mainly with websockets). -- Update to 6.0.2 - + Bug fixes - * `.WebSocketHandler.set_nodelay` works again. - * Accessing ``HTTPResponse.body`` now returns an empty byte string - instead of raising ``ValueError`` for error responses that don't - have a body (it returned None in this case in Tornado 5). -- Update to 6.0.1 - + Bug fixes - * Fixed issues with type annotations that caused errors while - importing Tornado on Python 3.5.2. -- Update to 6.0.0 - + Backwards-incompatible changes - * Python 2.7 and 3.4 are no longer supported; the minimum supported - Python version is 3.5.2. - * APIs deprecated in Tornado 5.1 have been removed. This includes the - ``tornado.stack_context`` module and most ``callback`` arguments - throughout the package. All removed APIs emitted - `DeprecationWarning` when used in Tornado 5.1, so running your - application with the ``-Wd`` Python command-line flag or the - environment variable ``PYTHONWARNINGS=d`` should tell you whether - your application is ready to move to Tornado 6.0. - * ``.WebSocketHandler.get`` is now a coroutine and must be called - accordingly in any subclasses that override this method (but note - that overriding ``get`` is not recommended; either ``prepare`` or - ``open`` should be used instead). - + General changes - * Tornado now includes type annotations compatible with ``mypy``. - These annotations will be used when type-checking your application - with ``mypy``, and may be usable in editors and other tools. - * Tornado now uses native coroutines internally, improving performance. - + tornado.auth - * All ``callback`` arguments in this package have been removed. Use - the coroutine interfaces instead. - * The ``OAuthMixin._oauth_get_user`` method has been removed. - Override `~.OAuthMixin._oauth_get_user_future` instead. - + tornado.concurrent - * The ``callback`` argument to `.run_on_executor` has been removed. - * ``return_future`` has been removed. - + tornado.gen - * Some older portions of this module have been removed. This includes - ``engine``, ``YieldPoint``, ``Callback``, ``Wait``, ``WaitAll``, - ``MultiYieldPoint``, and ``Task``. - * Functions decorated with ``@gen.coroutine`` no longer accept - ``callback`` arguments. - + tornado.httpclient - * The behavior of ``raise_error=False`` has changed. Now only - suppresses the errors raised due to completed responses with non-200 - status codes (previously it suppressed all errors). - * The ``callback`` argument to `.AsyncHTTPClient.fetch` has been removed. - + tornado.httputil - * ``HTTPServerRequest.write`` has been removed. Use the methods of - ``request.connection`` instead. - * Unrecognized ``Content-Encoding`` values now log warnings only for - content types that we would otherwise attempt to parse. - + tornado.ioloop - * ``IOLoop.set_blocking_signal_threshold``, - ``IOLoop.set_blocking_log_threshold``, ``IOLoop.log_stack``, - and ``IOLoop.handle_callback_exception`` have been removed. - * Improved performance of `.IOLoop.add_callback`. - + tornado.iostream - * All ``callback`` arguments in this module have been removed except - for `.BaseIOStream.set_close_callback`. - * ``streaming_callback`` arguments to `.BaseIOStream.read_bytes` and - `.BaseIOStream.read_until_close` have been removed. - * Eliminated unnecessary logging of "Errno 0". - + tornado.log - * Log files opened by this module are now explicitly set to UTF-8 encoding. - + tornado.netutil - * The results of ``getaddrinfo`` are now sorted by address family to - avoid partial failures and deadlocks. - + tornado.platform.twisted - * ``TornadoReactor`` and ``TwistedIOLoop`` have been removed. - + tornado.simple_httpclient - * The default HTTP client now supports the ``network_interface`` - request argument to specify the source IP for the connection. - * If a server returns a 3xx response code without a ``Location`` - header, the response is raised or returned directly instead of - trying and failing to follow the redirect. - * When following redirects, methods other than ``POST`` will no longer - be transformed into ``GET`` requests. 301 (permanent) redirects are - now treated the same way as 302 (temporary) and 303 (see other) - redirects in this respect. - * Following redirects now works with ``body_producer``. - + tornado.stack_context - * The ``tornado.stack_context`` module has been removed. - + tornado.tcpserver - * `.TCPServer.start` now supports a ``max_restarts`` argument (same as - `.fork_processes`). - + tornado.testing - * `.AsyncHTTPTestCase` now drops all references to the `.Application` - during ``tearDown``, allowing its memory to be reclaimed sooner. - * `.AsyncTestCase` now cancels all pending coroutines in ``tearDown``, - in an effort to reduce warnings from the python runtime about - coroutines that were not awaited. Note that this may cause - ``asyncio.CancelledError`` to be logged in other places. Coroutines - that expect to be running at test shutdown may need to catch this - exception. - + tornado.web - * The ``asynchronous`` decorator has been removed. - * The ``callback`` argument to `.RequestHandler.flush` has been removed. - * `.StaticFileHandler` now supports large negative values for the - ``Range`` header and returns an appropriate error for ``end > - start``. - * It is now possible to set ``expires_days`` in ``xsrf_cookie_kwargs``. - + tornado.websocket - * Pings and other messages sent while the connection is closing are - now silently dropped instead of logging exceptions. - * Errors raised by ``open()`` are now caught correctly when this method - is a coroutine. - + tornado.wsgi - * ``WSGIApplication`` and ``WSGIAdapter`` have been removed. -- Rebase patches: - * tornado-testsuite_timeout.patch - * skip-failing-tests.patch -- Remove upstream-included openssl-cert-size.patch - - -------------------------------------------------------------------- -Mon Jul 29 16:04:26 UTC 2019 - Todd R - -- Rename to python-tornado5 to handle version incompatibilities -- Update to 5.1.1 - + Bug fixes - * Fixed an case in which the `.Future` returned by - `.RequestHandler.finish` could fail to resolve. - * The `.TwitterMixin.authenticate_redirect` method works again. - * Improved error handling in the `tornado.auth` module, fixing hanging - requests when a network or other error occurs. -- Update to 5.1.0 - + Deprecation notice - * Tornado 6.0 will drop support for Python 2.7 and 3.4. The minimum - supported Python version will be 3.5.2. - * The ``tornado.stack_context`` module is deprecated and will be removed - in Tornado 6.0. The reason for this is that it is not feasible to - provide this module's semantics in the presence of ``async def`` - native coroutines. ``ExceptionStackContext`` is mainly obsolete - thanks to coroutines. ``StackContext`` lacks a direct replacement - although the new ``contextvars`` package (in the Python standard - library beginning in Python 3.7) may be an alternative. - * Callback-oriented code often relies on ``ExceptionStackContext`` to - handle errors and prevent leaked connections. In order to avoid the - risk of silently introducing subtle leaks (and to consolidate all of - Tornado's interfaces behind the coroutine pattern), ``callback`` - arguments throughout the package are deprecated and will be removed - in version 6.0. All functions that had a ``callback`` argument - removed now return a `.Future` which should be used instead. - * Where possible, deprecation warnings are emitted when any of these - deprecated interfaces is used. However, Python does not display - deprecation warnings by default. To prepare your application for - Tornado 6.0, run Python with the ``-Wd`` argument or set the - environment variable ``PYTHONWARNINGS`` to ``d``. If your - application runs on Python 3 without deprecation warnings, it should - be able to move to Tornado 6.0 without disruption. - + tornado.auth - * `.OAuthMixin._oauth_get_user_future` may now be a native coroutine. - * All ``callback`` arguments in this package are deprecated and will - be removed in 6.0. Use the coroutine interfaces instead. - * The ``OAuthMixin._oauth_get_user`` method is deprecated and will be removed in - 6.0. Override `~.OAuthMixin._oauth_get_user_future` instead. - + tornado.autoreload - * The command-line autoreload wrapper is now preserved if an internal - autoreload fires. - * The command-line wrapper no longer starts duplicated processes on windows - when combined with internal autoreload. - + tornado.concurrent - * `.run_on_executor` now returns `.Future` objects that are compatible - with ``await``. - * The ``callback`` argument to `.run_on_executor` is deprecated and will - be removed in 6.0. - * ``return_future`` is deprecated and will be removed in 6.0. - + tornado.gen - * Some older portions of this module are deprecated and will be removed - in 6.0. This includes ``engine``, ``YieldPoint``, ``Callback``, - ``Wait``, ``WaitAll``, ``MultiYieldPoint``, and ``Task``. - * Functions decorated with ``@gen.coroutine`` will no longer accept - ``callback`` arguments in 6.0. - + tornado.httpclient - * The behavior of ``raise_error=False`` is changing in 6.0. Currently - it suppresses all errors; in 6.0 it will only suppress the errors - raised due to completed responses with non-200 status codes. - * The ``callback`` argument to `.AsyncHTTPClient.fetch` is deprecated - and will be removed in 6.0. - * `tornado.httpclient.HTTPError` has been renamed to - `.HTTPClientError` to avoid ambiguity in code that also has to deal - with `tornado.web.HTTPError`. The old name remains as an alias. - * ``tornado.curl_httpclient`` now supports non-ASCII characters in - username and password arguments. - * ``.HTTPResponse.request_time`` now behaves consistently across - ``simple_httpclient`` and ``curl_httpclient``, excluding time spent - in the ``max_clients`` queue in both cases (previously this time was - included in ``simple_httpclient`` but excluded in - ``curl_httpclient``). In both cases the time is now computed using - a monotonic clock where available. - * `.HTTPResponse` now has a ``start_time`` attribute recording a - wall-clock (`time.time`) timestamp at which the request started - (after leaving the ``max_clients`` queue if applicable). - + tornado.httputil - * `.parse_multipart_form_data` now recognizes non-ASCII filenames in - RFC 2231/5987 (``filename*=``) format. - * ``HTTPServerRequest.write`` is deprecated and will be removed in 6.0. Use - the methods of ``request.connection`` instead. - * Malformed HTTP headers are now logged less noisily. - + tornado.ioloop - * `.PeriodicCallback` now supports a ``jitter`` argument to randomly - vary the timeout. - * ``IOLoop.set_blocking_signal_threshold``, - ``IOLoop.set_blocking_log_threshold``, ``IOLoop.log_stack``, - and ``IOLoop.handle_callback_exception`` are deprecated and will - be removed in 6.0. - * Fixed a `KeyError` in `.IOLoop.close` when `.IOLoop` objects are - being opened and closed in multiple threads. - + tornado.iostream - * All ``callback`` arguments in this module are deprecated except for - `.BaseIOStream.set_close_callback`. They will be removed in 6.0. - * ``streaming_callback`` arguments to `.BaseIOStream.read_bytes` and - `.BaseIOStream.read_until_close` are deprecated and will be removed - in 6.0. - + tornado.netutil - * Improved compatibility with GNU Hurd. - + tornado.options - * `tornado.options.parse_config_file` now allows setting options to - strings (which will be parsed the same way as - `tornado.options.parse_command_line`) in addition to the specified - type for the option. - + tornado.platform.twisted - * ``TornadoReactor`` and ``TwistedIOLoop`` are deprecated and will be - removed in 6.0. Instead, Tornado will always use the asyncio event loop - and twisted can be configured to do so as well. -``tornado.stack_context`` - * The ``tornado.stack_context`` module is deprecated and will be removed - in 6.0. - + tornado.testing - * `.AsyncHTTPTestCase.fetch` now takes a ``raise_error`` argument. - This argument has the same semantics as `.AsyncHTTPClient.fetch`, - but defaults to false because tests often need to deal with non-200 - responses (and for backwards-compatibility). - * The `.AsyncTestCase.stop` and `.AsyncTestCase.wait` methods are - deprecated. - + tornado.web - * New method `.RequestHandler.detach` can be used from methods - that are not decorated with ``@asynchronous`` (the decorator - was required to use ``self.request.connection.detach()``. - * `.RequestHandler.finish` and `.RequestHandler.render` now return - ``Futures`` that can be used to wait for the last part of the - response to be sent to the client. - * `.FallbackHandler` now calls ``on_finish`` for the benefit of - subclasses that may have overridden it. - * The ``asynchronous`` decorator is deprecated and will be removed in 6.0. - * The ``callback`` argument to `.RequestHandler.flush` is deprecated - and will be removed in 6.0. - + tornado.websocket - * When compression is enabled, memory limits now apply to the - post-decompression size of the data, protecting against DoS attacks. - * `.websocket_connect` now supports subprotocols. - * `.WebSocketHandler` and `.WebSocketClientConnection` now have - ``selected_subprotocol`` attributes to see the subprotocol in use. - * The `.WebSocketHandler.select_subprotocol` method is now called with - an empty list instead of a list containing an empty string if no - subprotocols were requested by the client. - * `.WebSocketHandler.open` may now be a coroutine. - * The ``data`` argument to `.WebSocketHandler.ping` is now optional. - * Client-side websocket connections no longer buffer more than one - message in memory at a time. - * Exception logging now uses `.RequestHandler.log_exception`. - + tornado.wsgi - * ``WSGIApplication`` and ``WSGIAdapter`` are deprecated and will be removed - in Tornado 6.0. -- Update to 5.0.2 - + Bug fixes - * Fixed a memory leak when `.IOLoop` objects are created and destroyed. - * If `.AsyncTestCase.get_new_ioloop` returns a reference to a - preexisting event loop (typically when it has been overridden to - return `.IOLoop.current()`), the test's ``tearDown`` method will not - close this loop. - * Fixed a confusing error message when the synchronous `.HTTPClient` - fails to initialize because an event loop is already running. - * `.PeriodicCallback` no longer executes twice in a row due to - backwards clock adjustments. -- Update to 5.0.1 - + Bug fix - * This release restores support for versions of Python 3.4 prior to - 3.4.4. This is important for compatibility with Debian Jessie which - has 3.4.2 as its version of Python 3. - + Highlights - * The focus of this release is improving integration with `asyncio`. - On Python 3, the `.IOLoop` is always a wrapper around the `asyncio` - event loop, and `asyncio.Future` and `asyncio.Task` are used instead - of their Tornado counterparts. This means that libraries based on - `asyncio` can be mixed relatively seamlessly with those using - Tornado. While care has been taken to minimize the disruption from - this change, code changes may be required for compatibility with - Tornado 5.0, as detailed in the following section. - * Tornado 5.0 supports Python 2.7.9+ and 3.4+. Python 2.7 and 3.4 are - deprecated and support for them will be removed in Tornado 6.0, - which will require Python 3.5+. -+ Backwards-compatibility notes - * Python 3.3 is no longer supported. - * Versions of Python 2.7 that predate the `ssl` module update are no - longer supported. (The `ssl` module was updated in version 2.7.9, - although in some distributions the updates are present in builds - with a lower version number. Tornado requires `ssl.SSLContext`, - `ssl.create_default_context`, and `ssl.match_hostname`) - * Versions of Python 3.5 prior to 3.5.2 are no longer supported due to - a change in the async iterator protocol in that version. - * The ``trollius`` project (`asyncio` backported to Python 2) is no - longer supported. - * `tornado.concurrent.Future` is now an alias for `asyncio.Future` - when running on Python 3. This results in a number of minor - behavioral changes: - > `.Future` objects can only be created while there is a current - `.IOLoop` - > The timing of callbacks scheduled with - ``Future.add_done_callback`` has changed. - `tornado.concurrent.future_add_done_callback` can be used to - make the behavior more like older versions of Tornado (but not - identical). Some of these changes are also present in the Python - 2 version of `tornado.concurrent.Future` to minimize the - difference between Python 2 and 3. - > Cancellation is now partially supported, via - `asyncio.Future.cancel`. A canceled `.Future` can no longer have - its result set. Applications that handle `~asyncio.Future` - objects directly may want to use - `tornado.concurrent.future_set_result_unless_cancelled`. In - native coroutines, cancellation will cause an exception to be - raised in the coroutine. - > The ``exc_info`` and ``set_exc_info`` methods are no longer - present. Use `tornado.concurrent.future_set_exc_info` to replace - the latter, and raise the exception with - `~asyncio.Future.result` to replace the former. - * ``io_loop`` arguments to many Tornado functions have been removed. - Use `.IOLoop.current()` instead of passing `.IOLoop` objects - explicitly. - * On Python 3, `.IOLoop` is always a wrapper around the `asyncio` - event loop. ``IOLoop.configure`` is effectively removed on Python 3 - (for compatibility, it may be called to redundantly specify the - `asyncio`-backed `.IOLoop`) - * `.IOLoop.instance` is now a deprecated alias for `.IOLoop.current`. - Applications that need the cross-thread communication behavior - facilitated by `.IOLoop.instance` should use their own global variable - instead. - + Other notes - * The ``futures`` (`concurrent.futures` backport) package is now required - on Python 2.7. - * The ``certifi`` and ``backports.ssl-match-hostname`` packages are no - longer required on Python 2.7. - * Python 3.6 or higher is recommended, because it features more - efficient garbage collection of `asyncio.Future` objects. - + tornado.auth - * `.GoogleOAuth2Mixin` now uses a newer set of URLs. - + tornado.autoreload - * On Python 3, uses ``__main__.__spec`` to more reliably reconstruct - the original command line and avoid modifying ``PYTHONPATH``. - * The ``io_loop`` argument to `tornado.autoreload.start` has been removed. - + tornado.concurrent - * `tornado.concurrent.Future` is now an alias for `asyncio.Future` - when running on Python 3. See "Backwards-compatibility notes" for - more. - * Setting the result of a ``Future`` no longer blocks while callbacks - are being run. Instead, the callbacks are scheduled on the next - `.IOLoop` iteration. - * The deprecated alias ``tornado.concurrent.TracebackFuture`` has been - removed. - * `tornado.concurrent.chain_future` now works with all three kinds of - ``Futures`` (Tornado, `asyncio`, and `concurrent.futures`) - * The ``io_loop`` argument to `tornado.concurrent.run_on_executor` has - been removed. - * New functions `.future_set_result_unless_cancelled`, - `.future_set_exc_info`, and `.future_add_done_callback` help mask - the difference between `asyncio.Future` and Tornado's previous - ``Future`` implementation. - + tornado.curl_httpclient - * Improved debug logging on Python 3. - * The ``time_info`` response attribute now includes ``appconnect`` in - addition to other measurements. - * Closing a `.CurlAsyncHTTPClient` now breaks circular references that - could delay garbage collection. - * The ``io_loop`` argument to the `.CurlAsyncHTTPClient` constructor - has been removed. - + tornado.gen - * ``tornado.gen.TimeoutError`` is now an alias for - `tornado.util.TimeoutError`. - * Leak detection for ``Futures`` created by this module now attributes - them to their proper caller instead of the coroutine machinery. - * Several circular references that could delay garbage collection have - been broken up. - * On Python 3, `asyncio.Task` is used instead of the Tornado coroutine - runner. This improves compatibility with some `asyncio` libraries - and adds support for cancellation. - * The ``io_loop`` arguments to ``YieldFuture`` and `.with_timeout` have - been removed. - + tornado.httpclient - * The ``io_loop`` argument to all `.AsyncHTTPClient` constructors has - been removed. - + tornado.httpserver - * It is now possible for a client to reuse a connection after sending - a chunked request. - * If a client sends a malformed request, the server now responds with - a 400 error instead of simply closing the connection. - * ``Content-Length`` and ``Transfer-Encoding`` headers are no longer - sent with 1xx or 204 responses (this was already true of 304 - responses). - * When closing a connection to a HTTP/1.1 client, the ``Connection: - close`` header is sent with the response. - * The ``io_loop`` argument to the `.HTTPServer` constructor has been - removed. - * If more than one ``X-Scheme`` or ``X-Forwarded-Proto`` header is - present, only the last is used. - + tornado.httputil - * The string representation of `.HTTPServerRequest` objects (which are - sometimes used in log messages) no longer includes the request - headers. - * New function `.qs_to_qsl` converts the result of - `urllib.parse.parse_qs` to name-value pairs. - + tornado.ioloop - * ``tornado.ioloop.TimeoutError`` is now an alias for - `tornado.util.TimeoutError`. - * `.IOLoop.instance` is now a deprecated alias for `.IOLoop.current`. - * `.IOLoop.install` and `.IOLoop.clear_instance` are deprecated. - * The ``IOLoop.initialized`` method has been removed. - * On Python 3, the `asyncio`-backed `.IOLoop` is always used and - alternative `.IOLoop` implementations cannot be configured. - `.IOLoop.current` and related methods pass through to - `asyncio.get_event_loop`. - * `~.IOLoop.run_sync` cancels its argument on a timeout. This - results in better stack traces (and avoids log messages about leaks) - in native coroutines. - * New methods `.IOLoop.run_in_executor` and - `.IOLoop.set_default_executor` make it easier to run functions in - other threads from native coroutines (since - `concurrent.futures.Future` does not support ``await``). - * ``PollIOLoop`` (the default on Python 2) attempts to detect misuse - of `.IOLoop` instances across `os.fork`. - * The ``io_loop`` argument to `.PeriodicCallback` has been removed. - * It is now possible to create a `.PeriodicCallback` in one thread - and start it in another without passing an explicit event loop. - * The ``IOLoop.set_blocking_signal_threshold`` and - ``IOLoop.set_blocking_log_threshold`` methods are deprecated because - they are not implemented for the `asyncio` event loop`. Use the - ``PYTHONASYNCIODEBUG=1`` environment variable instead. - * `.IOLoop.clear_current` now works if it is called before any - current loop is established. - + tornado.iostream - * The ``io_loop`` argument to the `.IOStream` constructor has been removed. - * New method `.BaseIOStream.read_into` provides a minimal-copy alternative to - `.BaseIOStream.read_bytes`. - * `.BaseIOStream.write` is now much more efficient for very large amounts of data. - * Fixed some cases in which ``IOStream.error`` could be inaccurate. - * Writing a `memoryview` can no longer result in "BufferError: - Existing exports of data: object cannot be re-sized". - + tornado.locks - * As a side effect of the ``Future`` changes, waiters are always - notified asynchronously with respect to `.Condition.notify`. - + tornado.netutil - * The default `.Resolver` now uses `.IOLoop.run_in_executor`. - `.ExecutorResolver`, `.BlockingResolver`, and `.ThreadedResolver` are - deprecated. - * The ``io_loop`` arguments to `.add_accept_handler`, - `.ExecutorResolver`, and `.ThreadedResolver` have been removed. - * `.add_accept_handler` returns a callable which can be used to remove - all handlers that were added. - * `.OverrideResolver` now accepts per-family overrides. - + tornado.options - * Duplicate option names are now detected properly whether they use - hyphens or underscores. - + tornado.platform.asyncio - * `.AsyncIOLoop` and `.AsyncIOMainLoop` are now used automatically - when appropriate; referencing them explicitly is no longer - recommended. - * Starting an `.IOLoop` or making it current now also sets the - `asyncio` event loop for the current thread. Closing an `.IOLoop` - closes the corresponding `asyncio` event loop. - * `.to_tornado_future` and `.to_asyncio_future` are deprecated since - they are now no-ops. - * `~.AnyThreadEventLoopPolicy` can now be used to easily allow the creation - of event loops on any thread (similar to Tornado's prior policy). - + tornado.platform.caresresolver - * The ``io_loop`` argument to `.CaresResolver` has been removed. - + tornado.platform.twisted - * The ``io_loop`` arguments to ``TornadoReactor``, `.TwistedResolver`, - and ``tornado.platform.twisted.install`` have been removed. - + tornado.process - * The ``io_loop`` argument to the `.Subprocess` constructor and - `.Subprocess.initialize` has been removed. - + tornado.routing - * A default 404 response is now generated if no delegate is found for - a request. - + tornado.simple_httpclient - * The ``io_loop`` argument to `.SimpleAsyncHTTPClient` has been removed. - * TLS is now configured according to `ssl.create_default_context` by - default. - + tornado.tcpclient - * The ``io_loop`` argument to the `.TCPClient` constructor has been - removed. - * `.TCPClient.connect` has a new ``timeout`` argument. - + tornado.tcpserver - * The ``io_loop`` argument to the `.TCPServer` constructor has been - removed. - * `.TCPServer` no longer logs ``EBADF`` errors during shutdown. - + tornado.testing - * The deprecated ``tornado.testing.get_unused_port`` and - ``tornado.testing.LogTrapTestCase`` have been removed. - * `.AsyncHTTPTestCase.fetch` now supports absolute URLs. - * `.AsyncHTTPTestCase.fetch` now connects to ``127.0.0.1`` - instead of ``localhost`` to be more robust against faulty - ipv6 configurations. - + tornado.util - * `tornado.util.TimeoutError` replaces ``tornado.gen.TimeoutError`` - and ``tornado.ioloop.TimeoutError``. - * `.Configurable` now supports configuration at multiple levels of an - inheritance hierarchy. - + tornado.web - * `.RequestHandler.set_status` no longer requires that the given - status code appear in `http.client.responses`. - * It is no longer allowed to send a body with 1xx or 204 responses. - * Exception handling now breaks up reference cycles that could delay - garbage collection. - * `.RedirectHandler` now copies any query arguments from the request - to the redirect location. - * If both ``If-None-Match`` and ``If-Modified-Since`` headers are present - in a request to `.StaticFileHandler`, the latter is now ignored. - + tornado.websocket - * The C accelerator now operates on multiple bytes at a time to - improve performance. - * Requests with invalid websocket headers now get a response with - status code 400 instead of a closed connection. - * `.WebSocketHandler.write_message` now raises `.WebSocketClosedError` if - the connection closes while the write is in progress. - * The ``io_loop`` argument to `.websocket_connect` has been removed. -- Rebase patches: - * tornado-testsuite_timeout.patch - * skip-failing-tests.patch -- Remove upstream-included asyncio.patch - ------------------------------------------------------------------- Thu Mar 7 11:27:44 UTC 2019 - Tomáš Chvátal diff --git a/python-tornado.spec b/python-tornado.spec index 1a3ee6c..9d9e285 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -17,33 +17,19 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} -%define skip_python2 1 Name: python-tornado -Version: 6.0.3 +Version: 4.5.3 Release: 0 Summary: Open source version of scalable, non-blocking web server that power FriendFeed License: Apache-2.0 +Source0: README.suse Group: Development/Languages/Python -URL: http://www.tornadoweb.org -Source: https://files.pythonhosted.org/packages/source/t/tornado/tornado-%{version}.tar.gz -Patch1: tornado-testsuite_timeout.patch -Patch2: skip-failing-tests.patch -BuildRequires: %{python_module base >= 3.5} -BuildRequires: %{python_module certifi} -BuildRequires: %{python_module devel} -BuildRequires: %{python_module pycurl} -BuildRequires: %{python_module setuptools} -BuildRequires: %{python_module simplejson} -BuildRequires: fdupes +Url: http://www.tornadoweb.org +BuildRequires: %{pythons} BuildRequires: python-rpm-macros -Requires: python -Requires: python-simplejson -Recommends: python-Twisted -Recommends: python-pycares -Recommends: python-pycurl -Recommends: python-service_identity -Provides: python-toro = %{version} -Obsoletes: python-toro < %{version} +Requires: python-tornado-impl = %{version} +Requires: python-tornado-impl = %{version} +BuildArch: noarch %python_subpackages %description @@ -63,36 +49,16 @@ FriendFeed servers. (For more information on scaling servers to support thousands of clients, see The C10K problem.) %prep -%setup -q -n tornado-%{version} -# Fix non-executable script rpmlint issue: -find demos tornado -name "*.py" -exec sed -i "/#\!\/usr\/bin\/.*/d" {} \; -%patch1 -p1 -%patch2 -p1 - -%pre -# remove egg-info _file_, being replaced by an egg-info directory -if [ -f %{python_sitearch}/tornado-%{version}-py%{python_version}.egg-info ]; then - rm %{python_sitearch}/tornado-%{version}-py%{python_version}.egg-info -fi +%setup -q -T -c +cp %{SOURCE0} . %build -%python_build +# None %install -%python_install -%fdupes -s demos -%python_expand rm -r %{buildroot}%{$python_sitearch}/tornado/test -%python_expand %fdupes %{buildroot}%{$python_sitearch} - -%check -export ASYNC_TEST_TIMEOUT=30 -export PYTHONDONTWRITEBYTECODE=1 -%python_exec -m tornado.test.runtests +# None %files %{python_files} -%license LICENSE -%doc demos -%{python_sitearch}/tornado -%{python_sitearch}/tornado-%{version}-py*.egg-info +%doc README.suse %changelog diff --git a/skip-failing-tests.patch b/skip-failing-tests.patch deleted file mode 100644 index bb7a1df..0000000 --- a/skip-failing-tests.patch +++ /dev/null @@ -1,40 +0,0 @@ -From: Benjamin Drung -Date: Tue, 18 Dec 2018 18:35:28 +0100 -Subject: [PATCH] Skip failing openssl 1.1.1 tests (for now) - -Four tests fail when using openssl 1.1.1 with TLS 1.3 support. Disable -these tests for now. Please fix the bug and re-enable them again. - -Bug: https://github.com/tornadoweb/tornado/issues/2536 ---- - tornado/test/iostream_test.py | 3 +++ - 1 file changed, 3 insertions(+) - -diff --git a/tornado/test/iostream_test.py b/tornado/test/iostream_test.py -index 56fffe6..b1d5f5d 100644 ---- a/tornado/test/iostream_test.py -+++ b/tornado/test/iostream_test.py -@@ -166,6 +166,7 @@ class TestReadWriteMixin(object): - raise NotImplementedError - - @gen_test -+ @unittest.skip("Failing when using openssl 1.1.1 with TLS 1.3 support. See https://github.com/tornadoweb/tornado/issues/2536") - def test_write_zero_bytes(self): - # Attempting to write zero bytes should run the callback without - # going into an infinite loop. -@@ -217,6 +218,7 @@ class TestReadWriteMixin(object): - rs.close() - - @gen_test -+ @unittest.skip("Failing when using openssl 1.1.1 with TLS 1.3 support. See https://github.com/tornadoweb/tornado/issues/2536") - def test_read_until_close_after_close(self): - # Similar to test_delayed_close_callback, but read_until_close takes - # a separate code path so test it separately. -@@ -736,6 +738,7 @@ class TestIOStreamMixin(object): - @skipIfNonUnix - @skipPypy3V58 - @gen_test -+ @unittest.skip("Failing when using openssl 1.1.1 with TLS 1.3 support. See https://github.com/tornadoweb/tornado/issues/2536") - def test_inline_read_error(self): - # An error on an inline read is raised without logging (on the - # assumption that it will eventually be noticed or logged further diff --git a/tornado-6.0.3.tar.gz b/tornado-6.0.3.tar.gz deleted file mode 100644 index 381d2d0..0000000 --- a/tornado-6.0.3.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:c845db36ba616912074c5b1ee897f8e0124df269468f25e4fe21fe72f6edd7a9 -size 482444 diff --git a/tornado-testsuite_timeout.patch b/tornado-testsuite_timeout.patch deleted file mode 100644 index 1b8bb1b..0000000 --- a/tornado-testsuite_timeout.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- tornado-6.0.3/tornado/test/testing_test.py 2018/03/16 13:18:44 1.1 -+++ tornado-6.0.3/tornado/test/testing_test.py 2018/03/16 13:18:56 -@@ -54,7 +54,7 @@ - self.io_loop.add_timeout(self.io_loop.time() + 0.00, self.stop) - self.wait(timeout=0.02) - self.io_loop.add_timeout(self.io_loop.time() + 0.03, self.stop) -- self.wait(timeout=0.15) -+ self.wait(timeout=0.25) - - - class LeakTest(AsyncTestCase): -@@ -262,7 +262,7 @@ - self.finished = True - - def test_timeout_environment_variable(self): -- @gen_test(timeout=0.5) -+ @gen_test(timeout=0.9) - def test_long_timeout(self): - yield gen.sleep(0.25) - From 0bd8bf125ee5b4bf70ca83b48620efb840affd29bcd30b5140094115e571e774 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Tue, 1 Oct 2019 13:44:39 +0000 Subject: [PATCH 7/8] - Require tornado5 for py2 and tornado6 for py3 as they are in different versions - Also switch from singlespec to explicit writeup for the obvious distinction between different versions of 2 and 3 variant OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=117 --- README.suse => README.SUSE | 3 -- python-tornado.changes | 8 +++++ python-tornado.spec | 69 +++++++++++++++++++++++++++++++------- 3 files changed, 64 insertions(+), 16 deletions(-) rename README.suse => README.SUSE (63%) diff --git a/README.suse b/README.SUSE similarity index 63% rename from README.suse rename to README.SUSE index a6e8212..81ab996 100644 --- a/README.suse +++ b/README.SUSE @@ -1,6 +1,3 @@ This package should always depend on the preferred numbered version of tornado, so "python-tornadoX" where "X" is the major version number. - -Currently that is python-tornado4 as other packages -transition to this format diff --git a/python-tornado.changes b/python-tornado.changes index dd9ba59..f46d554 100644 --- a/python-tornado.changes +++ b/python-tornado.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Tue Oct 1 13:36:35 UTC 2019 - Tomáš Chvátal + +- Require tornado5 for py2 and tornado6 for py3 as they + are in different versions +- Also switch from singlespec to explicit writeup for the obvious + distinction between different versions of 2 and 3 variant + ------------------------------------------------------------------- Wed Aug 14 15:09:36 UTC 2019 - Todd R diff --git a/python-tornado.spec b/python-tornado.spec index 9d9e285..e188dd9 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -18,19 +18,13 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-tornado -Version: 4.5.3 +Version: 5 Release: 0 Summary: Open source version of scalable, non-blocking web server that power FriendFeed License: Apache-2.0 -Source0: README.suse -Group: Development/Languages/Python -Url: http://www.tornadoweb.org -BuildRequires: %{pythons} -BuildRequires: python-rpm-macros -Requires: python-tornado-impl = %{version} -Requires: python-tornado-impl = %{version} +URL: http://www.tornadoweb.org +Source0: README.SUSE BuildArch: noarch -%python_subpackages %description Tornado is an open source version of the scalable, non-blocking web server and @@ -48,17 +42,66 @@ features — every active user of FriendFeed maintains an open connection to the FriendFeed servers. (For more information on scaling servers to support thousands of clients, see The C10K problem.) +%package -n python2-tornado +Version: 5.1 +Release: 0 +Summary: Open source version of scalable, non-blocking web server that power FriendFeed +Requires: python-tornado5 +Provides: python-tornado = %{version} +Obsoletes: python-tornado < %{version} + +%description -n python2-tornado +Tornado is an open source version of the scalable, non-blocking web server and +tools that power FriendFeed. The FriendFeed application is written using a web +framework that looks a bit like web.py or Google's webapp, but with additional +tools and optimizations to take advantage of the underlying non-blocking +infrastructure. + +The framework is distinct from most mainstream web server frameworks (and +certainly most Python frameworks) because it is non-blocking and reasonably +fast. Because it is non-blocking and uses epoll, it can handle thousands of +simultaneous standing connections, which means it is ideal for real-time web +services. We built the web server specifically to handle FriendFeed's real-time +features — every active user of FriendFeed maintains an open connection to the +FriendFeed servers. (For more information on scaling servers to support +thousands of clients, see The C10K problem.) + +%package -n python3-tornado +Version: 6.0 +Release: 0 +Summary: Open source version of scalable, non-blocking web server that power FriendFeed +Requires: python-tornado6 + +%description -n python3-tornado +Tornado is an open source version of the scalable, non-blocking web server and +tools that power FriendFeed. The FriendFeed application is written using a web +framework that looks a bit like web.py or Google's webapp, but with additional +tools and optimizations to take advantage of the underlying non-blocking +infrastructure. + +The framework is distinct from most mainstream web server frameworks (and +certainly most Python frameworks) because it is non-blocking and reasonably +fast. Because it is non-blocking and uses epoll, it can handle thousands of +simultaneous standing connections, which means it is ideal for real-time web +services. We built the web server specifically to handle FriendFeed's real-time +features — every active user of FriendFeed maintains an open connection to the +FriendFeed servers. (For more information on scaling servers to support +thousands of clients, see The C10K problem.) + %prep %setup -q -T -c cp %{SOURCE0} . %build -# None +: %install -# None +: -%files %{python_files} -%doc README.suse +%files -n python2-tornado +%doc README.SUSE + +%files -n python3-tornado +%doc README.SUSE %changelog From 879338e00916f0c907bbb05182dd65174c72d6e9518124e9325fd8ff2a6c39b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1=C5=A1=20Chv=C3=A1tal?= Date: Wed, 2 Oct 2019 13:37:26 +0000 Subject: [PATCH 8/8] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-tornado?expand=0&rev=118 --- python-tornado.spec | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python-tornado.spec b/python-tornado.spec index e188dd9..a1170e2 100644 --- a/python-tornado.spec +++ b/python-tornado.spec @@ -46,7 +46,7 @@ thousands of clients, see The C10K problem.) Version: 5.1 Release: 0 Summary: Open source version of scalable, non-blocking web server that power FriendFeed -Requires: python-tornado5 +Requires: python2-tornado5 Provides: python-tornado = %{version} Obsoletes: python-tornado < %{version} @@ -70,7 +70,7 @@ thousands of clients, see The C10K problem.) Version: 6.0 Release: 0 Summary: Open source version of scalable, non-blocking web server that power FriendFeed -Requires: python-tornado6 +Requires: python3-tornado6 %description -n python3-tornado Tornado is an open source version of the scalable, non-blocking web server and