Мой файл https://drive.google.com/file/d/1Z4_Xso ... sp=sharing
Мой код:
Код: Выделить всё
import jinja2 # create html files
templateLoader = jinja2.FileSystemLoader(
searchpath="./"
)
data_to_render = {
"document_number": "123",
"building_object_address": "Moscow"
}
templateEnv = jinja2.Environment(loader=templateLoader)
template = templateEnv.get_template("income_contract_web.html")
sourceHtml = template.render(json_data=data_to_render)
with open("xyz_result.html", "w") as f:
f.write(sourceHtml)
Код: Выделить всё
File "/home/alex/root_folder/projects/61_documents/1_documents_template/jinja_html/src.py", line 14, in
template = templateEnv.get_template("income_contract_web.html")
.......
raise rewrite_traceback_stack(source=source)
File "", line 13, in template
jinja2.exceptions.TemplateSyntaxError: Missing end of comment tag
Код: Выделить всё
*/#sidebar{position:absolute;top
Мобильная версия