diff --git a/REPORT.md b/REPORT.md index 5fa524e..9f46c0a 100644 --- a/REPORT.md +++ b/REPORT.md @@ -1,6 +1,40 @@ -# REPORT — felhom-controller v0.45.0: storage UX polish (order, init filter, register shortcut, clarity) +# REPORT — felhom-controller v0.46.0: fix /backups 500 (stale disk-tier template fields) -**Repo:** `felhom-controller` · **Version:** 0.45.0 · **Date:** 2026-06-12 · pairs with **felhom-agent v0.24.0** +**Repo:** `felhom-controller` · **Version:** 0.46.0 · **Date:** 2026-06-12 + +## v0.46.0 — /backups 500 fix (most recent) + +**Symptom:** `GET /backups` → HTTP 500 ("Internal error"). + +**Diagnosis (from the live controller log, not source-guessing):** +`backups.html:64: executing "backups" at <.Backup.RepoStats>: can't evaluate field RepoStats in type +interface {}`. Not a panic / not a funcmap nil-deref. The 8C de-privileging slimmed `FullBackupStatus` +to app-data-only (DB dumps + Docker-volume tars); the disk-tier restic/cross-drive backup moved to the +host agent. But `backups.html` still carried the pre-8C restic UI, referencing `.Backup.X` **struct +fields that no longer exist**: `RepoStats, LastBackup, ResticSchedule, NextBackup, PruneSchedule, +Retention, SnapshotHistory, LastCheckTime, LastCheckOK`. While those fields existed-but-nil, the +`{{if .Backup.X}}` guards short-circuited; once removed from the struct, the field access itself errors. +(Root-level keys like `.PerDriveRepoStats`/`.Tier2DriveGroups`/`.ResticPassword` are map lookups → nil +on miss → safe; the `Tier1*/Tier2*` fields are on `AppBackupRows`, which the handler still supplies — so +the user's "Tier2/cross-drive fields are consistent" was correct; the break was the `.Backup.*` restic +stats only.) + +**Fix (template-only, no Go change — the struct was already correct):** removed the dead disk-tier UI +from `backups.html`, keeping the app-data backup view — storage overview (DB dumps), DB-dump status card ++ schedule + table, per-app backup rows (Tier1/Tier2 via `AppBackupRows`), restore. Removed: the restic +"Mentési tároló"/"Tároló méret"/snapshot-history/per-drive-repo-stats/integrity/retention blocks, and +the restic schedule rows. The status card + schedule summary now key on `.Backup.LastDBDump`. + +**Validation (guest 9201):** built + deployed `felhom-controller:0.46.0`; `GET /backups` → **HTTP 200**, +renders all sections (Tárhely áttekintés / Adatbázisok / Ütemezés), no template error in logs. +`TestTemplatesParse` + `TestSortDisksForView` green; golden rebaked to 0.46.0. + +`settings.html`'s `.ResticSchedule`/`.LastCheckTime` are unaffected (root-map lookups, nil-safe; the +latter is the self-update checker, not backup). + +--- + +## v0.45.0 — storage UX polish (order, init filter, register shortcut, clarity) · pairs with **felhom-agent v0.24.0** Part B of the storage-fixes spec — controller-side ordering/filter/clarity polish on top of v0.44.0's role-aware drive management. (Part A, the eject role-gate, lives at the agent — see felhom-agent