#!/usr/bin/env python3 import json from pathlib import Path def load_json(data_dir: Path, filename: str) -> dict: filepath = data_dir / filename if not filepath.exists(): print(f"Warning: {filename} not found") return {} with open(filepath, "r") as f: return json.load(f) def render_html( variables: dict, statistics: dict, sections: dict, graph: dict, charts: dict ) -> str: html_template = ( """