account for py3 dict.values

This commit is contained in:
Benjamin Peterson 2011-05-24 18:28:20 -05:00
parent fa412675fc
commit b061e71da9
1 changed files with 1 additions and 1 deletions

View File

@ -180,7 +180,7 @@ class AssertionRewriter(ast.NodeVisitor):
if self.stack:
self.explanation_specifiers = self.stack[-1]
keys = [ast.Str(key) for key in current.keys()]
format_dict = ast.Dict(keys, current.values())
format_dict = ast.Dict(keys, list(current.values()))
form = ast.BinOp(expl_expr, ast.Mod(), format_dict)
name = "@py_format" + str(next(self.variable_counter))
self.on_failure.append(ast.Assign([ast.Name(name, ast.Store())], form))