clusev/app
boban 05c34b81ed fix(update): make the update-progress screen survive a browser refresh
The self-update progress screen reset its elapsed timer to 0 and dropped the
phase checklist back to step one on every browser refresh — and the long image
build made it look like the update had restarted. Root causes: the timer and
phase state lived only in page JS (Date.now() at page load), and a
30s-before-page-load staleness guard rejected the real phase feed whenever a
stage had run longer than 30s (which the image build always does).

- DeploymentService: requestUpdate() now also writes a best-effort
  run/update-started.json {at,from}. New updateStartedAt()/updatePhase() expose
  the server-side start + current macro-stage; updatePhase() requires a positive
  timestamp so a corrupt or stale 'done' can never drive a premature finish.
  clearUpdateRequest() also removes the start marker.
- routes: /update-status.json delegates to updatePhase(); /update-progress
  passes startedAt/initialPhase/hasFeed. A stage is trusted only when tied to
  THIS update's start (startedAt) and written at/after it — a leftover stage from
  a previous run can no longer resume or trigger a premature completion.
- update-progress.blade.php: the elapsed timer is anchored to the server-side
  start (counts the real elapsed across a refresh); the checklist resumes at the
  live stage; the live feed is authoritative (corrects any time-heuristic
  overshoot) and the heuristic stays off once a real stage is known.

Verified: 28 UpdateProgressTest cases + full suite (426) green, pint clean, and a
headless browser load+reload mid-update keeps the timer counting and the phase in
place with zero console errors. Codex review: two premature-completion edge cases
found and fixed (timestamp validation + start-anchored freshness).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-24 23:05:54 +02:00
..
Console/Commands fix(versions): show what's-new (v-prefixed ref) + sidebar update badge (v0.9.51) 2026-06-22 00:19:27 +02:00
Events fix(blade): garbled header on every signed-in page + private metrics channel (v0.4.1) 2026-06-14 08:34:07 +02:00
Http feat(auth): guests-only BlockBannedIp middleware + 403 page 2026-06-20 17:45:16 +02:00
Jobs feat: scaffold — Dockerized Laravel 13 + Livewire 3 + Tailwind 4 + Reverb 2026-06-12 00:31:50 +02:00
Livewire feat(release): deploy-to-public, promote-to-stable, yank actions (R5 + audit) 2026-06-23 03:26:14 +02:00
Models feat(release): publish + yank UI, strings, audit labels 2026-06-23 03:28:49 +02:00
Notifications fix(security): constant-time password-reset (flatten account-enumeration timing) 2026-06-15 19:16:30 +02:00
Providers fix(assets): drop Vite preload hints (silence 'preloaded but not used') 2026-06-19 21:50:54 +02:00
Rules feat(auth): ValidIpOrCidr validation rule 2026-06-20 17:42:06 +02:00
Services fix(update): make the update-progress screen survive a browser refresh 2026-06-24 23:05:54 +02:00
Support feat(release): deploy-to-public, promote-to-stable, yank actions (R5 + audit) 2026-06-23 03:26:14 +02:00