Drop support for Python 3.2.

Remove python 3.2 support from all test configurations and docs,
but do not actively remove code that exists for 3.2 compatibility.
This commit is contained in:
Ben Darnell 2015-10-24 18:56:07 -04:00
parent 02e67efa6b
commit 4d6fef7897
16 changed files with 29 additions and 50 deletions

View File

@ -4,7 +4,6 @@ python:
- 2.7.8
- 2.7
- pypy
- 3.2
- 3.3
- 3.4
- 3.5
@ -21,17 +20,13 @@ install:
# TODO(bdarnell): pycares tests are currently disabled on travis due to ipv6 issues.
#- if [[ $TRAVIS_PYTHON_VERSION != 'pypy'* && $DEPS == true ]]; then travis_retry pip install pycares; fi
- if [[ $TRAVIS_PYTHON_VERSION != 'pypy'* && $DEPS == true ]]; then travis_retry pip install pycurl; fi
- if [[ $TRAVIS_PYTHON_VERSION == '3.2' && $DEPS == true ]]; then travis_retry pip install mock; fi
# Twisted runs on 2.x and 3.3+, but is flaky on pypy.
- if [[ $TRAVIS_PYTHON_VERSION != '3.2' && $TRAVIS_PYTHON_VERSION != 'pypy'* && $DEPS == true ]]; then travis_retry pip install Twisted; fi
- if [[ $TRAVIS_PYTHON_VERSION != 'pypy'* && $DEPS == true ]]; then travis_retry pip install Twisted; fi
- if [[ $TRAVIS_PYTHON_VERSION == '2.7' && $DEPS == true ]]; then travis_retry pip install sphinx sphinx_rtd_theme; fi
- if [[ $TRAVIS_PYTHON_VERSION == '3.5' && $DEPS == true ]]; then travis_retry pip install sphinx sphinx_rtd_theme; fi
# On travis the extension should always be built
- if [[ $TRAVIS_PYTHON_VERSION != 'pypy'* ]]; then export TORNADO_EXTENSION=1; fi
- travis_retry python setup.py install
# Coverage 4.0 no longer supports py32. Install an older version before
# codecov tries to install the latest.
- if [[ $TRAVIS_PYTHON_VERSION == '3.2' ]]; then travis_retry pip install 'coverage<4.0'; fi
- travis_retry pip install codecov
- curl-config --version; pip freeze
@ -61,12 +56,12 @@ script:
- if [[ $TRAVIS_PYTHON_VERSION != pypy* && $DEPS == true ]]; then python $TARGET --resolver=tornado.netutil.ThreadedResolver; fi
- if [[ $TRAVIS_PYTHON_VERSION == 2* && $DEPS == true ]]; then python $TARGET --httpclient=tornado.curl_httpclient.CurlAsyncHTTPClient; fi
- if [[ $TRAVIS_PYTHON_VERSION == 2* && $DEPS == true ]]; then python $TARGET --ioloop_time_monotonic; fi
- if [[ $TRAVIS_PYTHON_VERSION != '3.2' && $TRAVIS_PYTHON_VERSION != 'pypy'* && $DEPS == true ]]; then python $TARGET --ioloop=tornado.platform.twisted.TwistedIOLoop; fi
- if [[ $TRAVIS_PYTHON_VERSION != 'pypy'* && $DEPS == true ]]; then python $TARGET --ioloop=tornado.platform.twisted.TwistedIOLoop; fi
- if [[ $TRAVIS_PYTHON_VERSION == 3.4 || $TRAVIS_PYTHON_VERSION == 3.5 ]]; then python $TARGET --ioloop=tornado.platform.asyncio.AsyncIOLoop; fi
- if [[ $TRAVIS_PYTHON_VERSION == 2* && $DEPS == true ]]; then python $TARGET --ioloop=tornado.platform.asyncio.AsyncIOLoop; fi
- if [[ $TRAVIS_PYTHON_VERSION == 2* && $DEPS == true ]]; then python $TARGET --resolver=tornado.platform.twisted.TwistedResolver; fi
#- if [[ $TRAVIS_PYTHON_VERSION != pypy* && $DEPS == true ]]; then python $TARGET --resolver=tornado.platform.caresresolver.CaresResolver; fi
- if [[ $TRAVIS_PYTHON_VERSION == 3* && $TRAVIS_PYTHON_VERSION != '3.2' ]]; then python $TARGET --ioloop_time_monotonic; fi
- if [[ $TRAVIS_PYTHON_VERSION == 3* ]]; then python $TARGET --ioloop_time_monotonic; fi
# make coverage reports for Codecov to find
- if [[ $TRAVIS_PYTHON_VERSION != nightly ]]; then coverage xml; fi
- export TORNADO_EXTENSION=0

View File

@ -131,7 +131,7 @@ the original synchronous version:
:hide:
The statement ``raise gen.Return(response.body)`` is an artifact of
Python 2 (and 3.2), in which generators aren't allowed to return
Python 2, in which generators aren't allowed to return
values. To overcome this, Tornado coroutines raise a special kind of
exception called a `.Return`. The coroutine catches this exception and
treats it like a returned value. In Python 3.3 and later, a ``return

View File

@ -79,9 +79,8 @@ copy of the source tarball as well.
The Tornado source code is `hosted on GitHub
<https://github.com/tornadoweb/tornado>`_.
**Prerequisites**: Tornado 4.3 runs on Python 2.7, and 3.2+
(support for Python 3.2 is deprecated and will be removed in
the next release). For Python 2, version 2.7.9 or newer is *strongly*
**Prerequisites**: Tornado 4.3 runs on Python 2.7, and 3.3+
For Python 2, version 2.7.9 or newer is *strongly*
recommended for the improved SSL support. In addition to the requirements
which will be installed automatically by ``pip`` or ``setup.py install``,
the following optional packages may be useful:

View File

@ -1,6 +1,6 @@
[tox]
# This currently segfaults on pypy.
envlist = py27,py32,py33,py34,py35
envlist = py27,py33,py34,py35
[testenv]
deps =
@ -13,7 +13,6 @@ commands = python -m unittest cythonapp_test
# defaults for the others.
basepython =
py27: python2.7
py32: python3.2
py33: python3.3
py34: python3.4
py35: python3.5

View File

@ -5,7 +5,7 @@
"servers": [
{"agent": "Tornado/py27", "url": "ws://localhost:9001",
"options": {"version": 18}},
{"agent": "Tornado/py34", "url": "ws://localhost:9002",
{"agent": "Tornado/py35", "url": "ws://localhost:9002",
"options": {"version": 18}},
{"agent": "Tornado/pypy", "url": "ws://localhost:9003",
"options": {"version": 18}}

View File

@ -10,7 +10,7 @@ FUZZING_SERVER_PID=$!
sleep 1
.tox/py27/bin/python client.py --name='Tornado/py27'
.tox/py34/bin/python client.py --name='Tornado/py32'
.tox/py35/bin/python client.py --name='Tornado/py35'
.tox/pypy/bin/python client.py --name='Tornado/pypy'
kill $FUZZING_SERVER_PID

View File

@ -15,8 +15,8 @@ tox
.tox/py27/bin/python server.py --port=9001 &
PY27_SERVER_PID=$!
.tox/py34/bin/python server.py --port=9002 &
PY32_SERVER_PID=$!
.tox/py35/bin/python server.py --port=9002 &
PY35_SERVER_PID=$!
.tox/pypy/bin/python server.py --port=9003 &
PYPY_SERVER_PID=$!
@ -26,7 +26,7 @@ sleep 1
.tox/py27/bin/wstest -m fuzzingclient
kill $PY27_SERVER_PID
kill $PY32_SERVER_PID
kill $PY35_SERVER_PID
kill $PYPY_SERVER_PID
wait

View File

@ -2,7 +2,7 @@
# to install autobahn and build the speedups module.
# See run.sh for the real test runner.
[tox]
envlist = py27, py32, pypy
envlist = py27, py35, pypy
setupdir=../../..
[testenv]

View File

@ -26,8 +26,6 @@ apt-get update
DEADSNAKES_PACKAGES="
python2.7
python2.7-dev
python3.2
python3.2-dev
"
apt-get -y install $DEADSNAKES_PACKAGES

View File

@ -1,5 +1,5 @@
[tox]
envlist = py27-full, py32, py27
envlist = py27-full, py27
setupdir=/tornado
toxworkdir=/home/vagrant/tox-tornado

View File

@ -24,8 +24,8 @@ add-apt-repository ppa:fkrull/deadsnakes
apt-get update
DEADSNAKES_PACKAGES="
python3.2
python3.2-dev
python3.5
python3.5-dev
"
apt-get -y install $DEADSNAKES_PACKAGES

View File

@ -1,5 +1,5 @@
[tox]
envlist = py27-full, py32, py27, py27-select, py27-twisted
envlist = py27-full, py27, py27-select, py27-twisted
setupdir=/tornado
toxworkdir=/home/vagrant/tox-tornado
@ -28,7 +28,3 @@ deps =
pycurl
twisted==12.2.0
commands = python -m tornado.test.runtests --ioloop=tornado.platform.twisted.TwistedIOLoop {posargs:}
[testenv:py32]
basepython = python3.2
commands = python -bb -m tornado.test.runtests {posargs:}

View File

@ -29,7 +29,6 @@ TMPDIR = r'c:\tornado_bootstrap'
PYTHON_VERSIONS = [
(r'c:\python27\python.exe', 'http://www.python.org/ftp/python/2.7.3/python-2.7.3.msi'),
(r'c:\python32\python.exe', 'http://www.python.org/ftp/python/3.2.3/python-3.2.3.msi'),
(r'c:\python33\python.exe', 'http://www.python.org/ftp/python/3.3.0/python-3.3.0.msi'),
]

View File

@ -1,5 +1,5 @@
[tox]
envlist = py27-full, py32-full, py27, py32, py33, py27-opt, py33-monotonic
envlist = py27-full, py27, py33, py27-opt, py33-monotonic
setupdir = e:\
toxworkdir = c:\tox-tornado
@ -12,11 +12,6 @@ deps =
futures
mock
[testenv:py32-full]
basepython = python3.2
deps =
mock
[testenv:py33]
# tox's path mappings haven't been updated for py33 yet.
basepython = c:\python33\python.exe

View File

@ -172,7 +172,6 @@ setup(
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: Implementation :: CPython',

23
tox.ini
View File

@ -15,8 +15,8 @@ envlist =
# Basic configurations: Run the tests in both minimal installations
# and with all optional dependencies.
# (pypy3 doesn't have any optional deps yet)
{py27,pypy,py32,py33,py34,py35,pypy3},
{py27,pypy,py32,py33,py34,py35}-full,
{py27,pypy,py33,py34,py35,pypy3},
{py27,pypy,py33,py34,py35}-full,
# Also run the tests with each possible replacement of a default
# component. Run each test on both python 2 and 3 where possible.
@ -35,7 +35,7 @@ envlist =
# Alternate Resolvers.
{py2,py3}-full-{threadedresolver},
{py2,py32}-full-caresresolver,
{py2,py3}-full-caresresolver,
# Other configurations; see comments below.
{py2,py3}-{monotonic,opt},
@ -54,7 +54,6 @@ envlist =
# defaults for the others.
basepython =
py27: python2.7
py32: python3.2
py33: python3.3
py34: python3.4
py35: python3.5
@ -70,20 +69,20 @@ deps =
py3-unittest2: unittest2py3k
# cpython-only deps: pycurl installs but curl_httpclient doesn't work;
# twisted mostly works but is a bit flaky under pypy.
{py27,py32,py33,py34,py35}-full: pycurl
{py27,py33,py34,py35}-full: pycurl
{py2,py3}: pycurl>=7.19.3.1
# twisted is cpython only and doesn't support py32.
# twisted is cpython only.
{py27,py33,py34,py35}-full: twisted
{py2,py3}: twisted
# pycares installation currently fails on py33
# (https://github.com/pypa/pip/pull/816)
{py2,py27,py32,py33,py34,py35}-full: pycares
{py2,py3,py27,py33,py34,py35}-full: pycares
# futures became standard in py32
{py2,py27,pypy}-full: futures
# mock became standard in py33
{py2,py27,pypy,py3,py32,pypy3}-full: mock
{py2,py27,pypy,py3,pypy3}-full: mock
# singledispatch became standard in py34.
{py2,py27,pypy,py3,py32,py33}-full: singledispatch
{py2,py27,pypy,py3,py33}-full: singledispatch
py33-asyncio: asyncio
trollius: trollius
py2-monotonic: Monotime
@ -92,7 +91,7 @@ deps =
setenv =
# The extension is mandatory on cpython.
{py2,py27,py3,py32,py33,py34,py35}: TORNADO_EXTENSION=1
{py2,py27,py3,py33,py34,py35}: TORNADO_EXTENSION=1
# In python 3, opening files in text mode uses a
# system-dependent encoding by default. Run the tests with "C"
# (ascii) and "utf-8" locales to ensure we don't have hidden
@ -101,7 +100,7 @@ setenv =
lang_utf8: LANG=en_US.utf-8
# tox's parser chokes if all the setenv entries are conditional.
DUMMY=dummy
{py2,py27,py3,py32,py33,py34,py35}-no-ext: TORNADO_EXTENSION=0
{py2,py27,py3,py33,py34,py35}-no-ext: TORNADO_EXTENSION=0
# All non-comment lines but the last must end in a backslash.
# Tox filters line-by-line based on the environment name.
@ -109,7 +108,7 @@ commands =
python \
# py3*: -b turns on an extra warning when calling
# str(bytes), and -bb makes it an error.
{py3,py32,py33,py34,py35,pypy3}: -bb \
{py3,py33,py34,py35,pypy3}: -bb \
# Python's optimized mode disables the assert statement, so
# run the tests in this mode to ensure we haven't fallen into
# the trap of relying on an assertion's side effects or using