feature: use constant metadata from file metadata3b.json
This commit is contained in:
@@ -11,9 +11,14 @@ bd = build.Build(conf)
|
||||
|
||||
# Download the text files:
|
||||
dl.download_edition("N")
|
||||
dl.download_edition("E")
|
||||
dl.download_edition("A")
|
||||
dl.download_edition("NE")
|
||||
dl.download_edition("EA")
|
||||
dl.download_edition("NEA")
|
||||
|
||||
# Download additional files:
|
||||
dl.download_question_metadata()
|
||||
# dl.download_question_metadata() # (now constant file metadata3b.json)
|
||||
dl.download_photos()
|
||||
dl.download_pictures()
|
||||
dl.download_includes()
|
||||
@@ -23,4 +28,9 @@ dl.download_content()
|
||||
# Build Everything:
|
||||
bd.build_website()
|
||||
bd.build_edition("N")
|
||||
bd.build_edition("E")
|
||||
bd.build_edition("A")
|
||||
bd.build_edition("NE")
|
||||
bd.build_edition("EA")
|
||||
bd.build_edition("NEA")
|
||||
bd.build_assets()
|
||||
|
||||
+15752
File diff suppressed because it is too large
Load Diff
+1
-1
@@ -53,7 +53,7 @@ class Build:
|
||||
|
||||
question_template = self.env.get_template(template_file)
|
||||
|
||||
with (self.config.p_data / "metadata.json").open() as file:
|
||||
with (self.config.p_data / "metadata3b.json").open() as file:
|
||||
metadata = json.load(file)
|
||||
|
||||
question = None
|
||||
|
||||
+1
-1
@@ -33,7 +33,7 @@ questions = parse_katalog()
|
||||
|
||||
def question_stub(input):
|
||||
"""Combines the original question dataset from BNetzA with our internal metadata"""
|
||||
with open("data/metadata.json") as metadata_file:
|
||||
with open("data/metadata3b.json") as metadata_file:
|
||||
metadata = json.load(metadata_file)
|
||||
number = metadata[f"{input}"]["number"] # Fragennummer z.B. AB123
|
||||
|
||||
|
||||
@@ -45,7 +45,7 @@ def filter_shuffle_answers(seq):
|
||||
|
||||
def question_stub(input):
|
||||
"""Combines the original question dataset from BNetzA with our internal metadata"""
|
||||
with open("data/metadata.json") as metadata_file:
|
||||
with open("data/metadata3b.json") as metadata_file:
|
||||
metadata = json.load(metadata_file)
|
||||
number = metadata[f"{input}"]["number"] # Fragennummer z.B. AB123
|
||||
|
||||
|
||||
@@ -36,7 +36,7 @@ def test_question_translation_html():
|
||||
}
|
||||
|
||||
def test_function(input):
|
||||
with open("data/metadata.json") as file:
|
||||
with open("data/metadata3b.json") as file:
|
||||
metadata = json.load(file)
|
||||
return metadata[f"{input}"].get("number")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user