diff --git a/ifex/output_filters/JinjaSetup.py b/ifex/output_filters/JinjaSetup.py index fdbfabdf..5e973277 100644 --- a/ifex/output_filters/JinjaSetup.py +++ b/ifex/output_filters/JinjaSetup.py @@ -45,7 +45,7 @@ def find_matching_template_files(self, directory : str, root_ast_class, recurse templates = {} # Dict maps node name to the template file name if recurse: - for _,_,filenames in os.walk(directory): + for root, _, filenames in os.walk(directory): for ff in filenames: for n in classes: if ff.startswith(n + '.'): diff --git a/ifex/output_filters/templates/TemplateDir.py b/ifex/output_filters/templates/TemplateDir.py index 866ed88d..d398aec6 100644 --- a/ifex/output_filters/templates/TemplateDir.py +++ b/ifex/output_filters/templates/TemplateDir.py @@ -18,7 +18,7 @@ def find_matching_template_files(directory : str, recurse = False, absolute = Fa templates = {} # Dict maps node name to the template file name if recurse: - for _, _, filenames in os.walk(directory): + for root, _, filenames in os.walk(directory): for fn in filenames: for n in classes: if fn.startswith(n):