diff --git a/CHANGELOG.md b/CHANGELOG.md index 39ff808..499a216 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). ## [Unreleased] +### Fixed +- Python 3 compatibility ## [1.0.2] - 2018-06-05 ### Added diff --git a/templates/config/_macros.j2 b/templates/config/_macros.j2 index b8bb61d..d9af4ec 100644 --- a/templates/config/_macros.j2 +++ b/templates/config/_macros.j2 @@ -4,7 +4,7 @@ {%- if parameter is string or parameter is number -%} {{ parameter }}{{ '\n' }} {%- elif parameter is mapping -%} - {%- for parameter_key, parameter_value in parameter.iteritems() -%} + {%- for parameter_key, parameter_value in parameter.items() -%} {%- if parameter_key not in exclusions -%} {{ _config_parameter(parameter_key, parameter_value, indent) }}{% if not outer_loop.last %} {% endif %} {%- endif -%} @@ -17,7 +17,7 @@ {%- set vars = {'values': []} -%} {%- for parameter in parameters -%} {%- if parameter is mapping -%} - {%- for parameter_key, parameter_value in parameter.iteritems() -%} + {%- for parameter_key, parameter_value in parameter.items() -%} {%- if parameter_key == key -%} {%- if vars.update({'values': vars['values'] + [parameter_value]}) -%}{%- endif -%} {%- endif -%}