R. David Murray added the comment:
The statement in question causes the compiler to make 'tags' a local variable
in the function, and thus you get the error on the assignment. See
https://docs.python.org/3/faq/programming.html#id8.
--
nosy: +r.david.murray
resolution: -> not a bug
st
New submission from Brian Smith:
While using decorators in python 3.5.2, I ran into a surprising bug where the
decorator sometimes lost context of the outer scope. The attached file
demonstrates this problem.
In this file, we have 2 decorators. They are identical, except that the first
has