3 Commits

Author SHA1 Message Date
forust 93f2b94dd2 chore: update entry points for multi-account
- main.py calls migrate_legacy_state() before starting server
- health.py accepts account_ids parameter for per-account health checks
- _continuous_check returns per-account status instead of single snapshot
2026-06-27 15:21:02 +02:00
forust 1dfe41950e Add graceful shutdown, logging, streaming with Range Requests, and state.json cache
- Graceful shutdown: SIGTERM/SIGINT handlers stop continuous scraper,
  disconnect Telegram client, drain running jobs with timeout
- Logging: replace print() with logging module throughout web server,
  basicConfig in main.py with structured log format
- Streaming: chunked file reads (64KB) instead of loading entire files
  into memory; full HTTP Range Request support (206 Partial Content)
  for video seeking in the browser
- Cache: TTL-based in-memory cache (1s) for state.json reads in
  StateStore, thread-safe with existing RLock
- Bugfix: send_error_json now converts HTTPStatus to int for JSON
2026-05-27 00:14:26 +02:00
forust f57e1d63eb Add lightweight web control panel 2026-04-25 02:19:52 +02:00