Commit Graph
6 Commits
Author SHA1 Message Date
mattandClaude Opus 5.5 247c94a79c Plan for ActivityPub phase 0 (groundwork)
CI / test (push) Successful in 44s
CI / images (push) Skipped
CI / assets (push) Skipped
CI / python-package (push) Skipped
CI / validate-monitoring (push) Successful in 7s
CI / lint (push) Successful in 10s
CI / notify (push) Successful in 5s
Step-by-step plan: domain events, a generic worker with imports moved
onto it, the empty federation module and config, separate Alembic
branches, and boundary tests enforcing the module rules.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MK52BGoJbPhZ1vSFuKcGUW
2026-09-25 19:52:39 +01:00
mattandClaude Opus 5.5 5d71116613 ActivityPub design: build in-house as one replaceable module
CI / notify (push) Successful in 5s
CI / validate-monitoring (push) Successful in 9s
CI / lint (push) Successful in 14s
CI / test (push) Successful in 49s
CI / images (push) Skipped
CI / assets (push) Skipped
CI / python-package (push) Skipped
- Settles build vs buy: write it ourselves (Scrobbler is BSD-3-Clause;
  the Python library option is AGPL)
- New "Module structure" section: everything in scrobbler.federation,
  a pure protocol/ subpackage for spec-dependent code, pluggable
  signature schemes/inbox handlers/post kinds, core → federation only
  via blinker domain events, own federation_* tables in a separate
  Alembic branch, generic task worker, and boundary tests enforcing it
- Adds a groundwork phase 0 and updates the open decisions

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MK52BGoJbPhZ1vSFuKcGUW
2026-09-25 19:48:04 +01:00
mattandClaude Opus 5.5 d2c71d50f1 Design proposal: ActivityPub federation
CI / validate-monitoring (push) Successful in 8s
CI / lint (push) Successful in 11s
CI / test (push) Successful in 44s
CI / images (push) Skipped
CI / assets (push) Skipped
CI / python-package (push) Skipped
CI / notify (push) Successful in 7s
Research write-up for making Scrobbler users followable from the
fediverse: protocol pieces (WebFinger, actor, inbox, signatures in both
draft-cavage and RFC 9421, delivery), what gets posted (weekly summary,
milestones, now playing), build-vs-library, data model, security,
testing against GoToSocial, phased plan and open decisions.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MK52BGoJbPhZ1vSFuKcGUW
2026-09-25 19:36:45 +01:00
mattandClaude Opus 5.5 eebd7b8730 Imports API: upload exports, pull from Last.fm, follow progress
CI / assets (push) Successful in 8s
CI / images (push) Successful in 31s
CI / notify (push) Successful in 6s
CI / validate-monitoring (push) Successful in 9s
CI / lint (push) Successful in 13s
CI / test (push) Successful in 47s
CI / python-package (push) Skipped
- /api/v1/imports/options lists the available sources; `lastfm` only
  appears when the server has a Last.fm API key
- POST /imports/file (multipart; format detected or forced with
  ?format=), POST /imports/lastfm, GET /imports, GET /imports/{id},
  POST /imports/{id}/cancel
- Upload size limit (IMPORT_MAX_BYTES, default 200 MB) with a 413
- Documented in OpenAPI under the Imports tag

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MK52BGoJbPhZ1vSFuKcGUW
2026-09-25 15:04:15 +01:00
mattandClaude Opus 5.5 ea705589f1 Monitoring stack, containers and dashboards
CI / lint (push) Successful in 9s
CI / test (push) Successful in 36s
CI / notify (push) Successful in 5s
- API image (uv multi-stage, non-root, gunicorn, migrations on start,
  health check) and UI image (nginx, CSP, config.js rendered from
  API_BASE_URL); /healthz documented in OpenAPI
- docker compose runs db, api and ui; the "monitoring" profile adds
  Prometheus, postgres-exporter and Grafana, all provisioned from files
- Grafana dashboards: API overview (RED), Last.fm API, Usage, Database
- Prometheus alert rules: API down, error rate, latency, auth failure
  spike, ignored scrobbles, DB pool saturation, Postgres down
- Pool checkout gauge counts events (the pool's own counters lag the
  checkin event); error ratios show 0 instead of "No data"
- Tests check dashboards and alerts only use metrics that exist
- scripts/generate_traffic.py drives realistic traffic for demos

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MK52BGoJbPhZ1vSFuKcGUW
2026-09-25 14:26:19 +01:00
mattandClaude Opus 5.5 89f8589424 OpenAPI: document the Last.fm API and commit the exported spec
CI / lint (push) Successful in 10s
CI / test (push) Successful in 30s
CI / notify (push) Successful in 5s
- /2.0/ and /api/auth/ are described from the Last.fm method registry:
  method enum, per-method parameter tables, auth requirements, notes,
  request schemas and XML example responses
- Readable tags (Auth, Apps, Sessions, Tokens, Stats, Last.fm)
- docs/openapi.json is exported with `flask openapi write`; tests fail
  if it drifts from the code, if any route is undocumented, or if a UI
  route is missing its bearer-auth security declaration

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MK52BGoJbPhZ1vSFuKcGUW
2026-09-25 14:13:47 +01:00