Backstage, reviewedlive feeds · proper lifecycles · honest UI
The original /backstage is a descriptive document — what the dashboard is supposed to do. This page is what the doc would look like if the doc were a live thing, reporting the state of each named endpoint with a real lifecycle.
Lifecycle vocabulary borrowed from React/SWR/RTK
Live feeds same-origin via hub2 Caddy proxy
Architecture preserved from original /backstage
What "reviewed" means here
The original /backstage describes endpoints; this page
shows their behaviour. The difference matters because
endpoints lie about themselves. /api/questions on the
live dashboard returns 500 most of the day because its upstream
(metaculus.com API) frequently 403s — the original doc does not
acknowledge this. The reviewed page surfaces the failure state in the
UI with a specific error code and timestamp.
Each feed has four lifecycle states. The page favours showing stale over showing nothing, because the previous successful response is usually more useful than a spinner.
Defences in this page
- AbortController + setTimeout for fetch cancellation (no
AbortSignal.timeoutdependency). - Same-origin proxy via hub2 Caddy so we can read response bodies (not opaque). Path:
/upstream/*→metaculus.raindesk.dev/*. - Freshness window 60s — beyond that the feed flips to stale, never silently. Re-fetch is explicit.
- Auto-refresh every 90s on a single shared timer (no per-feed storms).
- Pause when tab hidden via
visibilitychange; resume on return. - Error preserves last-good — fetch failure does not wipe the previously shown body.
- JSON pretty-printed when content-type allows; text-stream feeds (
/text) shown verbatim.