From: Ben Darnell Date: Sat, 14 May 2011 23:15:39 +0000 (-0700) Subject: types.NoneType no longer exists in python 3 X-Git-Tag: v2.0.0~85^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4eb36de74d0da9e904a9eb835756f04f58325018;p=thirdparty%2Ftornado.git types.NoneType no longer exists in python 3 --- diff --git a/tornado/stack_context.py b/tornado/stack_context.py index fd3ac50e1..c5570b499 100644 --- a/tornado/stack_context.py +++ b/tornado/stack_context.py @@ -48,8 +48,6 @@ Example usage: from __future__ import with_statement -from types import NoneType - import contextlib import functools import itertools @@ -57,6 +55,8 @@ import logging import sys import threading +NoneType = type(None) + class _State(threading.local): def __init__(self): self.contexts = ()