File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 4
4
5
5
from sentry_sdk .hub import Hub , _should_send_default_pii
6
6
from sentry_sdk .utils import (
7
+ HAS_REAL_CONTEXTVARS ,
7
8
event_from_exception ,
8
9
capture_internal_exceptions ,
9
10
transaction_from_function ,
@@ -39,11 +40,11 @@ def setup_once():
39
40
if tornado_version is None or tornado_version < (5 , 0 ):
40
41
raise RuntimeError ("Tornado 5+ required" )
41
42
42
- if sys . version_info < ( 3 , 7 ) :
43
+ if not HAS_REAL_CONTEXTVARS :
43
44
# Tornado is async. We better have contextvars or we're going to leak
44
45
# state between requests.
45
46
raise RuntimeError (
46
- "The tornado integration for Sentry requires Python 3.7+ "
47
+ "The tornado integration for Sentry requires Python 3.6+ or the aiocontextvars package "
47
48
)
48
49
49
50
ignore_logger ("tornado.application" )
You can’t perform that action at this time.
0 commit comments