]> git.ipfire.org Git - thirdparty/jinja.git/commitdiff
Fixed a name error for an uncommon attribute access in the sandbox
authorArmin Ronacher <armin.ronacher@active-4.com>
Thu, 29 Dec 2016 15:01:35 +0000 (16:01 +0100)
committerArmin Ronacher <armin.ronacher@active-4.com>
Thu, 29 Dec 2016 15:01:35 +0000 (16:01 +0100)
CHANGES
jinja2/sandbox.py

diff --git a/CHANGES b/CHANGES
index 29a773b9d92ac1d6502c4f2695ca103b568a737b..0113054949a549c091d01314af8a4b41d46df9af 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -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
 -------------
 
index c035ddea00722810823ccb68c5aba1d175f54e2c..549c4276652eb71c4b198437c5afcbcf74e68a69 100644 (file)
@@ -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('__')