diff options
author | Armin Ronacher <armin.ronacher@active-4.com> | 2016-12-29 16:01:35 +0100 |
---|---|---|
committer | Armin Ronacher <armin.ronacher@active-4.com> | 2016-12-29 16:01:35 +0100 |
commit | 74bd64e56387f5b2931040dc7235a3509cde1611 (patch) | |
tree | 898ecf57fc38098942d41120966b24204271d090 | |
parent | d3b456fea3d997d84130e30e84325e57b42406b1 (diff) | |
download | jinja2-2.8-maintenance.tar.gz |
Fixed a name error for an uncommon attribute access in the sandbox2.8-maintenance
-rw-r--r-- | CHANGES | 8 | ||||
-rw-r--r-- | jinja2/sandbox.py | 2 |
2 files changed, 9 insertions, 1 deletions
@@ -1,6 +1,14 @@ Jinja2 Changelog ================ +Version 2.8.2 +------------- + +(bugfix release, unreleased) + +- Fixed a runtime error in the sandbox when attributes of async generators + were accessed. + Version 2.8.1 ------------- diff --git a/jinja2/sandbox.py b/jinja2/sandbox.py index c035dde..549c427 100644 --- a/jinja2/sandbox.py +++ b/jinja2/sandbox.py @@ -206,7 +206,7 @@ def is_internal_attribute(obj, attr): if attr in UNSAFE_COROUTINE_ATTRIBUTES: return True elif hasattr(types, 'AsyncGeneratorType') and isinstance(obj, types.AsyncGeneratorType): - if attri in UNSAFE_ASYNC_GENERATOR_ATTRIBUTES: + if attr in UNSAFE_ASYNC_GENERATOR_ATTRIBUTES: return True return attr.startswith('__') |