Files
manage/backend/tests
Developer a43d6a6206 Backend: drop users router, backups service attribution, named dashboards (Slice 3)
Users router removed:
- Delete routers/users.py + users_impl.py (Jellyfin-backed user directory,
  Jellyfin-email message compose, Jellyseerr enrichment).
- Drop orphaned get_jellyseerr_client dep from dependencies.py
  (get_user_id stays; used by dashboard/media/media_index_worker).
- clients/jellyseerr.py stays (still imported by widgets/sources.py).
- test_api.py TestUsers block + mock_jellyseerr fixture removed.

Backups service attribution:
- backup_jobs gains a nullable service_id column (PRAGMA migration).
- _resolve_backup_service_id helper: explicit service_id wins, else
  first-wins an enabled backups instance, else empty (backward-compat).
- Both report endpoints accept ?service_id= and persist it on the job.
- Dashboard summary + poller aggregate across all jobs unchanged.

Named dashboards backend:
- named_dashboards table (id, label, slug UNIQUE, sort_order, payload_json,
  timestamps) with full CRUD methods + _slugify/_unique_slug helpers.
- models/dashboards.py (NamedDashboardInput/NamedDashboard).
- routers/dashboards.py: GET/POST/PUT/DELETE /api/dashboards.
- Router registered in main.py.

Tests: test_dashboards.py (CRUD, slug collision, explicit slug, 404);
test_api.py trimmed. 271 backend tests pass (was 268; +6 dashboards -3
users); ruff clean.

Refs openspec/changes/services-as-hub-ia/ (spec R5/R6.1, tasks slice 3).
2026-06-26 18:33:24 +00:00
..
2026-05-04 17:24:41 +02:00