Skip to content

feat(harbor): add a read-only browser dashboard for the backlog - #60

Merged
Bre77 merged 2 commits into
mainfrom
fm/fm-e113-harbor-dashboard
Aug 13, 2026
Merged

Bre77 merged 2 commits into
mainfrom
fm/fm-e113-harbor-dashboard

Conversation

@Bre77

@Bre77 Bre77 commented Aug 13, 2026

Copy link
Copy Markdown
Owner

Intent

  • Give the captain a browser view of the live tasks-axi backlog, grouped the way he thinks about it: waiting on him, in flight, queued/blocked, and a short recent-done tail - no new record-keeping surface, since a related "logbook" ledger idea was explicitly scrapped for adding maintenance workload.
  • Read-only, on demand: every page load shells out fresh to tasks-axi list (never a second hand-rolled backlog parser) and renders directly, so there is no cache, no database, and nothing that can drift stale between reads.
  • Auto-refresh without a scheduler: the page carries a <meta http-equiv="refresh"> tag, so the captain's browser reloads on its own and each reload re-runs the read. Rejected a static file regenerated on a timer - that needs a background regeneration loop for no benefit, since the backlog is small (tens of tasks) and a per-request read is already cheap.
  • Loopback-only, hardcoded (127.0.0.1, no bind flag, no env override) - the captain reaches it through his own SSH tunnel. The only configurable knob is --port.
  • bin/fm-harbor.sh owns start/stop/status/render (a home-scoped singleton lock, mirroring the existing ClickStack receiver's lock pattern); bin/fm-harbor.py owns the render (parsing tasks-axi's brace-headed pseudo-CSV list output, which needs csv.reader(doublequote=False, escapechar="\\") since its quoting is backslash-escaped rather than RFC4180) and the loopback HTTP server, so the render is defined exactly once and reused by both render and serve.
  • AGENTS.md gets one pointer line in the backlog-contract section; the script's own header and --help own the rest.

What Changed

  • bin/fm-harbor.py (new): render + serve, stdlib-only.
  • bin/fm-harbor.sh (new): start/stop/status/render/serve CLI wrapper, shellcheck-clean.
  • tests/fm-harbor.test.sh (new): render-path grouping (captain-hold prominence, non-captain-hold exclusion from that group, blocked-by id resolved to the blocker's title, full bare PR URL, HTML-escaping), read-only guarantee, an absent-backlog render, the loopback/no-extra-knobs constraint, a live-server test proving a tasks-axi done mid-session moves the task to "Recently done" on the next request with no restart, and the start/status/stop/singleton lifecycle.
  • AGENTS.md: one-line pointer in the backlog contract section.

Risk Assessment

Low. New, isolated files with no callers wired up elsewhere; nothing else reads or depends on them. Strictly read-only over the backlog and fleet state (no writes, confirmed by a checksum-based test). No watcher/supervision integration - it is a passive page the captain starts and stops himself.

Testing

  • bin/fm-lint.sh (shellcheck) - clean.
  • tests/fm-harbor.test.sh - 6/6 pass, including a live loopback server exercised with real curl/tasks-axi.
  • bin/fm-test-run.sh --check-coverage - the new test lands in the portable-serial remainder automatically; partition still complete.
  • bin/fm-doc-audience-check.sh - clean.
  • Manually started the server, opened it in a real browser (chrome-devtools-axi), and screenshotted the "Waiting on you" section's visual prominence; completed a task via tasks-axi done mid-session and confirmed the page reflected it on the next load with no restart; confirmed double-start reports "already running" rather than opening a second port; confirmed stop leaves no process behind and start works again afterward.
Full narrative / original brief

Epic E11.3: build the Harbor dashboard, a persistent, auto-refreshing front door the captain opens in a browser to see his tasks - the live tasks-axi backlog of this firstmate home. Captain's explicit scope ruling: he wants to see the tasks from tasks-axi; no new record-keeping surface. Harbor reads existing state only. One page on 127.0.0.1, grouped into in-flight, waiting-on-him, queued/blocked, and a short recent-done tail. Data source is tasks-axi's own read commands, never a second parser. Auto-refresh via the simplest honest mechanism, justified. No database, no build pipeline, no background daemon beyond one small long-running process with a clear start command. A tracked helper owns start/stop/status/render with its header/help owning the mechanics; AGENTS.md gets at most a one-line pointer. Captain-facing rendering rules: plain-English language, full bare PR URLs, no internal jargon in headings, hold reasons shown as recorded. Colocated tests covering the render path. Delivered fork-only, never upstreamed.

Bre77 added 2 commits August 13, 2026 15:23
The captain wants to see tasks-axi's live backlog in a browser without any
new record-keeping surface to maintain. bin/fm-harbor.sh (start/stop/status)
and bin/fm-harbor.py (render/serve) read the backlog fresh through
tasks-axi's own list command on every request and group it the way the
captain thinks about it: waiting on him, in flight, queued/blocked, and a
short done tail. Loopback-only, no auth, no cache, no scheduler - the page's
own meta-refresh tag drives auto-refresh.
The gate runs each tests/*.test.sh directly rather than via bash, so the
file needs its own execute bit like every other test script.
@Bre77 Bre77 added the fm Opened by a Firstmate crewmate label Aug 13, 2026
@Bre77
Bre77 merged commit 0c1e021 into main Aug 13, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fm Opened by a Firstmate crewmate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant