Skip to content

Server-side heatmap rendering, dark theme redesign, uv-based Docker build - #1

Merged
NanoMil merged 5 commits into
munichmakerlab:mainfrom
Friedjof:feat/status-page-uv-docker
Sep 3, 2026
Merged

Server-side heatmap rendering, dark theme redesign, uv-based Docker build#1
NanoMil merged 5 commits into
munichmakerlab:mainfrom
Friedjof:feat/status-page-uv-docker

Conversation

@Friedjof

@Friedjof Friedjof commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Replace the slow embedded Grafana <iframe> on the status page with a server-side rendered "Opening Times" heatmap table. The data is fetched from Grafana's public dashboard query API, cached, and refreshed in a background thread so page loads never wait on the external call.
  • Redesign the status page with a dark theme, a bigger/squared "Open/Closed" status card, and a smaller navbar.
  • Migrate dependency management from requirements.txt to pyproject.toml + uv (with uv.lock for reproducible installs).
  • Switch the Docker image build to install dependencies via uv instead of pip, and add a compose.yml for local development.
  • Add CI workflows: lint.yml (ruff + hadolint on every push/PR) and build-test.yml (verifies the image still builds on main); docker-build-push.yml now only publishes to GHCR on version-tag pushes (v*) instead of every push to main.

Why

The Grafana iframe made the page noticeably slow to load just to show a small 7x24 probability table. Fetching and caching that data server-side removes the dependency on Grafana's frontend entirely for end users, while the background refresh keeps the data reasonably fresh without ever blocking a request.

Test plan

  • docker compose up --build builds and starts the container; / returns 200 and renders the heatmap table.
  • /simple.php, /api/v2/status.json etc. still respond correctly.
  • Verified the heatmap falls back to a plain message if the Grafana request fails, instead of a 500 error.
  • Verified pip/uv install works from a clean environment.
  • Manual visual check of the new dark theme in a browser (recommended before merge).

@NanoMil
NanoMil merged commit a39495e into munichmakerlab:main Sep 3, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants