Set autoescape to True in Jinja2 environment 23/13223/1
authorgarciadeblas <gerardo.garciadeblas@telefonica.com>
Tue, 18 Apr 2023 16:25:13 +0000 (18:25 +0200)
committergarciadeblas <gerardo.garciadeblas@telefonica.com>
Tue, 18 Apr 2023 16:25:13 +0000 (18:25 +0200)
Change-Id: I2af8d9e30f610bb18928b4c85b16ecd6754129b8
Signed-off-by: garciadeblas <gerardo.garciadeblas@telefonica.com>
osm_pla/placement/mznplacement.py

index d507bbd..ac25448 100755 (executable)
@@ -131,7 +131,7 @@ class MznModelGenerator(object):
         """loads the jinja template used for model generation"""
         loader1 = FileSystemLoader(MznModelGenerator.template_search_path)
         loader2 = PackageLoader("osm_pla", ".")
-        env = Environment(loader=ChoiceLoader([loader1, loader2]))
+        env = Environment(loader=ChoiceLoader([loader1, loader2]), autoescape=True)
         return env.get_template(template_name)