Require tornado >= 4.4

This commit is contained in:
Stein Magnus Jodal 2018-03-29 18:57:42 +02:00
parent 0b2fdce882
commit 95577206a0
5 changed files with 9 additions and 19 deletions

View File

@ -8,12 +8,10 @@ python:
env: env:
- TOX_ENV=py27 - TOX_ENV=py27
- TOX_ENV=py27-tornado32
- TOX_ENV=docs - TOX_ENV=docs
- TOX_ENV=flake8 - TOX_ENV=flake8
before_install: before_install:
- "sudo sed -i '/127.0.1.1/d' /etc/hosts" # Workaround tornadoweb/tornado#1573
- "sudo apt-get update -qq" - "sudo apt-get update -qq"
- "sudo apt-get install -y gir1.2-gst-plugins-base-1.0 gir1.2-gstreamer-1.0 graphviz-dev gstreamer1.0-plugins-good gstreamer1.0-plugins-bad python-gst-1.0" - "sudo apt-get install -y gir1.2-gst-plugins-base-1.0 gir1.2-gstreamer-1.0 graphviz-dev gstreamer1.0-plugins-good gstreamer1.0-plugins-bad python-gst-1.0"

View File

@ -5,10 +5,14 @@ Changelog
This changelog is used to track all major changes to Mopidy. This changelog is used to track all major changes to Mopidy.
v2.1.1 (UNRELEASED) v2.2.0 (UNRELEASED)
=================== ===================
Bug fix release. Feature release.
- Dependencies: Drop support for Tornado < 4.4. Though strictly a breaking
change, this shouldn't affect any supported systems as even Debian stable
includes Tornado >= 4.4.
- MPD: Added ``idle`` to the list of available commands. - MPD: Added ``idle`` to the list of available commands.
(Fixes: :issue:`1593`, PR: :issue:`1597`) (Fixes: :issue:`1593`, PR: :issue:`1597`)

View File

@ -3,7 +3,6 @@ from __future__ import absolute_import, unicode_literals
import functools import functools
import logging import logging
import os import os
import socket
import tornado.escape import tornado.escape
import tornado.ioloop import tornado.ioloop
@ -101,12 +100,7 @@ class WebSocketHandler(tornado.websocket.WebSocketHandler):
self.jsonrpc = make_jsonrpc_wrapper(core) self.jsonrpc = make_jsonrpc_wrapper(core)
def open(self): def open(self):
if hasattr(self, 'set_nodelay'):
# New in Tornado 3.1
self.set_nodelay(True) self.set_nodelay(True)
else:
self.stream.socket.setsockopt(
socket.IPPROTO_TCP, socket.TCP_NODELAY, 1)
self.clients.add(self) self.clients.add(self)
logger.debug( logger.debug(
'New WebSocket connection from %s', self.request.remote_ip) 'New WebSocket connection from %s', self.request.remote_ip)

View File

@ -28,7 +28,7 @@ setup(
'Pykka >= 1.1', 'Pykka >= 1.1',
'requests >= 2.0', 'requests >= 2.0',
'setuptools', 'setuptools',
'tornado >= 3.2, < 5', # Tornado 5 requires Python >= 2.7.9 'tornado >= 4.4, < 5', # Tornado 5 requires Python >= 2.7.9
], ],
extras_require={'http': []}, extras_require={'http': []},
entry_points={ entry_points={

View File

@ -1,5 +1,5 @@
[tox] [tox]
envlist = py27, py27-tornado32, docs, flake8 envlist = py27, docs, flake8
[testenv] [testenv]
sitepackages = true sitepackages = true
@ -17,12 +17,6 @@ deps =
pytest-xdist pytest-xdist
responses responses
[testenv:py27-tornado32]
commands = pytest tests/http
deps =
{[testenv]deps}
tornado==3.2.2
[testenv:docs] [testenv:docs]
deps = -r{toxinidir}/docs/requirements.txt deps = -r{toxinidir}/docs/requirements.txt
changedir = docs changedir = docs