INNER CODE UNIT · Python
_serve_markdown
yohey-w/multi-agent-shogun · scripts/dashboard-viewer.py:247
def _serve_markdown(self):
try:
text = self.dashboard_path.read_text(encoding="utf-8")
except FileNotFoundError:
self.send_error(404, "dashboard.md not found")
return
body = text.encode("utf-8")
self.send_response(200)
self.send_header("Content-Type", "text/plain; charset=utf-8")
self.send_header("Cache-Control", "no-cache")
self.send_header("Content-Length", str(len(body)))
self.end_headers()
self.wfile.write(body)
def _serve_mtime(self):
try:
mtime = self.dashboard_path.stat().st_mtime
except FileNotFoundError: