Browse Source

adding flask logger

technodisobedience
mb 1 year ago
parent
commit
ab79c2c909
  1. 8
      octomode.py

8
octomode.py

@ -83,12 +83,12 @@ def md_to_html(md_pad_content, name):
app_root = get_app_root()
template_url = f"{ app_hostname }{ app_root }/{ name }/template.html"
md_url = f"{ app_hostname }{ app_root }/{ name }/pad.md"
print(template_url)
print(md_url)
APP.logger.info("template_url", template_url)
APP.logger.info("md_url", md_url)
result = subprocess.run(["pandoc", "--from", "markdown", "--to", "html", "--template", f"{ template_url }", md_url], capture_output=True, text=True)
html = result.stdout
print(result.stderr)
print(html)
APP.logger.info("html", html)
APP.logger.info("result.stderr", result.stderr)
# Convert Markdown to HTML, using the default pandoc template
# ----------------------------------------------------------------------------------

Loading…
Cancel
Save