From 857afc094db82cf54c12092b0e68735e5ac37318 Mon Sep 17 00:00:00 2001 From: "Prof. Dr. Matthias Jung DL9MJ" Date: Mon, 2 Jun 2025 22:27:42 +0200 Subject: [PATCH] fix: fixed a wrong merge --- src/build.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/build.py b/src/build.py index b98187d..ea9364a 100644 --- a/src/build.py +++ b/src/build.py @@ -283,7 +283,11 @@ class Build: with open("data/snippets.json") as f: snippets = json.load(f) - with FiftyOhmHtmlRenderer(self.__build_question, self.__picture_handler, self.__photo_handler) as renderer: + with FiftyOhmHtmlRenderer( + question_renderer=self.__build_question, + picture_handler=self.__picture_handler, + photo_handler=self.__photo_handler + ) as renderer: for key, value in snippets.items(): snippets[key] = renderer.render_inner(Document(value)) # Remove leading

and trailing

: @@ -296,7 +300,7 @@ class Build: return contents def __build_index(self, snippets): - template = self.env.get_template("index.html") + template = self.env.get_template("html/index.html") result = template.render({"snippets": snippets}) with open("build/index.html", "w") as file: @@ -305,7 +309,7 @@ class Build: file.write(result) def __build_course_page(self, snippets, template, page): - template = self.env.get_template(f"{template}.html") + template = self.env.get_template(f"html/{template}.html") result=template.render({"snippets": snippets}) with open(f"build/{page}.html", "w") as file: