Files
ai-agent/backend/deploy_status.py
Gabriel Vidal 3ae477f3db feat(ai-agent): sticky in-app deploy-progress banner with phase timeline
While the blue-green deploy runs, show a sticky notification pinned
top-left below the header: the deploy's worktree label + a horizontal
dot-per-phase timeline (grey pending, pulsing active, green done, red
failed). Clicking it expands a panel with the triggering conversation's
title, a deep link to the thread, and the same timeline with phase labels.

- deploy.sh writes a JSON snapshot (label, per-phase steps, status, the
  triggering session's conv url/title) into the live container's data dir
  as each phase begins, and clears it a few seconds after a terminal state.
- backend deploy_status.py: read_status derives per-step states; a
  DeployWatcher polls the file and pings a `deploy` SSE event on any change.
  Surfaced at GET /api/deploy-status.
- frontend: DeployBanner subscribes via the SSE bus + React Query, so the
  dots advance and the banner appears/clears live with no reload. Excluded
  from the persisted query cache so a past session's deploy can't flash a
  stale banner on cold load.
- mock backend seeded with an in-flight deploy so the banner is demoable
  and testable under ?mock=1.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-17 03:08:10 +02:00

5.0 KiB