Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert local access #31

Merged
merged 1 commit into from
Jul 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions scripts/generate_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
from pathlib import Path
from tempfile import NamedTemporaryFile as NTF
from typing import Optional
import pdfkit

from jinja2 import Environment, FileSystemLoader

Expand Down Expand Up @@ -57,8 +56,6 @@ def __init__(self, summaryd: dict,

"header-spacing": "5",
"footer-spacing": "4",
"enable-local-file-access": True,
"load-error-handling": "ignore",
}
if header_line:
pdfkit_opts["header-line"] = ""
Expand Down Expand Up @@ -190,6 +187,7 @@ def write(self, html, pdf) -> None:
fout.write(cov_txt)
fout.write(con_txt)
if pdf:
import pdfkit
pdfkit.from_string(con_txt, pdf,
options=self.pdfkit_opts, css=self.css_fname,
toc=toc, cover=cov_fh.name, cover_first=True)
Expand Down
Loading