4 Commits

Author SHA1 Message Date
b76ffbf656 fixed percentage and mb/s view 2025-11-01 16:49:12 +01:00
3be175522f download re implemented 2025-10-30 22:06:41 +01:00
17e5a551e1 feat: migrate to Pydantic V2 and implement rate limiting middleware
- Migrate settings.py to Pydantic V2 (SettingsConfigDict, validation_alias)
- Update config models to use @field_validator with @classmethod
- Replace deprecated datetime.utcnow() with datetime.now(timezone.utc)
- Migrate FastAPI app from @app.on_event to lifespan context manager
- Implement comprehensive rate limiting middleware with:
  * Endpoint-specific rate limits (login: 5/min, register: 3/min)
  * IP-based and user-based tracking
  * Authenticated user multiplier (2x limits)
  * Bypass paths for health, docs, static, websocket endpoints
  * Rate limit headers in responses
- Add 13 comprehensive tests for rate limiting (all passing)
- Update instructions.md to mark completed tasks
- Fix asyncio.create_task usage in anime_service.py

All 714 tests passing. No deprecation warnings.
2025-10-23 22:03:15 +02:00
028d91283e feat: implement download queue service with persistence, priority, and retry logic
- Added comprehensive download queue service (download_service.py)
  - Priority-based queue management (HIGH, NORMAL, LOW)
  - Concurrent download processing with configurable limits
  - Automatic queue persistence to JSON file
  - Retry logic for failed downloads with max retry limits
  - Real-time progress tracking and WebSocket broadcasting
  - Queue operations: add, remove, reorder, pause, resume
  - Statistics tracking: download speeds, sizes, ETA calculations

- Created comprehensive unit tests (test_download_service.py)
  - 23 tests covering all service functionality
  - Tests for queue management, persistence, retry logic
  - Broadcast callbacks, error handling, and lifecycle

- Added structlog dependency for structured logging
- Updated infrastructure.md with download service documentation
- Removed completed task from instructions.md

All tests passing (23/23)
2025-10-17 10:07:16 +02:00