Compare commits
3
Commits
a3649c3ead
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b32b4d09f1 | ||
|
|
b7aeee9fe8 | ||
|
|
e0d6cd7959 |
No files matched your search
@@ -15,7 +15,11 @@ The working tree represents the user's active work.
|
||||
2. **Check for Existing Files:** Before creating any new file, verify whether the file (or a user equivalent) already exists on disk. Never overwrite or re-scaffold user work.
|
||||
3. **Never Overwrite Blindly:** Use available file-reading tools. Preserve user comments, links, and conventions. Prefer surgical edits over wholesale overwrites.
|
||||
4. **No Destructive Git Commands:** Never run `reset --hard`, `clean -fd`, `restore`, `checkout`, `stash`, `rebase`, or `amend` without explicit permission.
|
||||
5. **Live Task Tracking (`todo.txt`):** Keep `todo.txt` synchronized with code reality. When a task or milestone is implemented and verified, mark it as completed (`x YYYY-MM-DD ...`) immediately. Never leave completed work marked as pending.
|
||||
5. **Live Planning & Task Synchronization:** Keep planning artifacts synchronized with code reality whenever a task completes or scope shifts across all four places:
|
||||
- **Repository roadmap** (`docs/roadmap.md`) — authoritative milestone sequencing and exit criteria.
|
||||
- **Immediate checklist** (`todo.txt`) — focused strictly on a granular breakdown of the **next immediate deliverable** milestone; mark completed items (`x YYYY-MM-DD ...`) immediately upon verification.
|
||||
- **Gitea issues & milestones** (`kiskaadee/MagNetFlix`) — open/update/close issues and milestones so Gitea remains the authoritative backlog.
|
||||
- **Gitea Kanban board** (`MagNetFlix Pipeline`, Project `#2`) — attach active deliverable issues and milestone epics to keep board status aligned.
|
||||
6. **Final Diff Verification:** Before completing work, run `git status` and `git diff` to verify that no unrelated user changes were modified or discarded. Distinguish user changes from agent changes in completion reports.
|
||||
|
||||
---
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
- Read `docs/deployment.md` before changing Dockerfiles, Compose services, or Traefik/Authelia configs.
|
||||
|
||||
## Build & Tool Execution Commands
|
||||
- **Workspace Sync:** `uv sync` (Never use raw `pip`)
|
||||
- **Workspace Sync:** `uv sync --all-packages` (Never use raw `pip`)
|
||||
- **Workspace Lock:** `uv lock`
|
||||
- **Protobuf Generation:** `uv run buf generate` (or `make generate`)
|
||||
- **BFF Dev Server:** `uv run --package magnetflix-bff uvicorn bff.main:app --reload --port 8000`
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
.PHONY: generate test lint format check
|
||||
|
||||
generate:
|
||||
nix develop --command buf generate
|
||||
@if command -v buf >/dev/null 2>&1; then \
|
||||
buf generate; \
|
||||
else \
|
||||
nix develop --command buf generate; \
|
||||
fi
|
||||
|
||||
test:
|
||||
uv run pytest
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
# 1. Enter hermetic dev shell (Nix)
|
||||
nix develop
|
||||
|
||||
# 2. Or install dependencies with uv workspace
|
||||
uv sync
|
||||
# 2. Or install dependencies for all workspace packages with uv
|
||||
uv sync --all-packages
|
||||
|
||||
# 3. Generate protobuf stubs & documentation
|
||||
make generate
|
||||
@@ -49,7 +49,6 @@ make check
|
||||
├── README.md # Project landing page
|
||||
├── buf.gen.yaml # Buf code generation configuration
|
||||
├── buf.yaml # Buf module configuration
|
||||
├── docker-compose.yml # Multi-container Compose stack specification
|
||||
├── docs/ # Authoritative architecture and operations documentation
|
||||
│ ├── adr/ # Architecture Decision Records (ADRs)
|
||||
│ ├── history/ # Audit logs and review ledgers
|
||||
|
||||
+2
-2
@@ -158,7 +158,7 @@ Request to submit a new movie download.
|
||||
| ----- | ---- | ----- | ----------- |
|
||||
| magnet_uri | [string](#string) | | Magnet URI of the torrent to fetch. |
|
||||
| imdb_id | [string](#string) | | IMDb ID of the movie (e.g., "tt1375666"). |
|
||||
| requested_by | [string](#string) | | Username of the user requesting the download (from Authelia Remote-User). |
|
||||
| requested_by | [string](#string) | | Username of the user requesting the download (from upstream SSO identity header). |
|
||||
|
||||
|
||||
|
||||
@@ -212,7 +212,7 @@ PipelineService coordinates movie download jobs, safety scans, and library reloc
|
||||
|
||||
| Method Name | Request Type | Response Type | Description |
|
||||
| ----------- | ------------ | ------------- | ------------|
|
||||
| SubmitDownload | [SubmitDownloadRequest](#magnetflix-v1-SubmitDownloadRequest) | [SubmitDownloadResponse](#magnetflix-v1-SubmitDownloadResponse) | SubmitDownload enqueues a new movie download job. Rejects duplicate submissions if an active job for the same IMDb ID exists or if already in library. |
|
||||
| SubmitDownload | [SubmitDownloadRequest](#magnetflix-v1-SubmitDownloadRequest) | [SubmitDownloadResponse](#magnetflix-v1-SubmitDownloadResponse) | SubmitDownload enqueues a new movie download job. Rejects duplicate submissions if an active job for the same IMDb ID or info_hash exists, or if already in library. |
|
||||
| GetJob | [GetJobRequest](#magnetflix-v1-GetJobRequest) | [GetJobResponse](#magnetflix-v1-GetJobResponse) | GetJob retrieves the current status and metadata of a specific job. |
|
||||
| StreamJobStatus | [StreamJobStatusRequest](#magnetflix-v1-StreamJobStatusRequest) | [StreamJobStatusResponse](#magnetflix-v1-StreamJobStatusResponse) stream | StreamJobStatus streams real-time status updates. Semantics: Emits an immediate snapshot of matching active jobs upon connection, followed by subsequent state and progress change events. |
|
||||
| ListJobs | [ListJobsRequest](#magnetflix-v1-ListJobsRequest) | [ListJobsResponse](#magnetflix-v1-ListJobsResponse) | ListJobs returns a paginated list of download jobs. |
|
||||
|
||||
+12
-11
@@ -11,10 +11,10 @@ When self-hosting a media server (Jellyfin/Plex):
|
||||
2. In multi-user setups, tracking who requested what and keeping track of download failures is difficult without a dedicated audit log.
|
||||
|
||||
**MagNetFlix** solves this with an end-to-end automated workflow:
|
||||
- **Input**: A simple web form protected by **Authelia SSO** accepting an **IMDb ID** and a **Magnet URI**.
|
||||
- **Input**: A simple web form protected by **pluggable reverse-proxy / OIDC SSO** accepting an **IMDb ID** and a **Magnet URI**.
|
||||
- **Processing**: A background **gRPC worker** handles downloading via Transmission into a sandboxed staging directory.
|
||||
- **Safety**: Recursively scans and purges all non-media/dangerous executable files.
|
||||
- **Organization**: Fetches official metadata for the IMDb ID, verifies movie details, and places renamed media files into your library structure.
|
||||
- **Safety**: Recursively scans staging payloads, ignoring benign clutter while hard-failing jobs containing dangerous executables, archives, symlinks, or path traversal.
|
||||
- **Organization**: Resolves official TMDB metadata for the IMDb ID at ingestion, verifies movie tokens post-download, and atomically places renamed media files into your library structure.
|
||||
- **Observability**: Live status tracking and persistent audit logs.
|
||||
|
||||
---
|
||||
@@ -25,24 +25,25 @@ When self-hosting a media server (Jellyfin/Plex):
|
||||
sequenceDiagram
|
||||
autonumber
|
||||
actor User as Authenticated User
|
||||
participant Traefik as Traefik (SSO Protected)
|
||||
participant Proxy as Reverse Proxy (SSO Protected)
|
||||
participant BFF as FastAPI (BFF Gateway)
|
||||
participant Worker as gRPC Pipeline Worker
|
||||
participant Engine as Transmission Daemon
|
||||
participant Media as Jellyfin / Plex Library
|
||||
|
||||
User->>Traefik: GET addmovie.roadtotech.me
|
||||
Traefik->>User: Renders MagNetFlix Web Form
|
||||
User->>Traefik: Submit form (magnet URI + IMDb ID: tt1375666)
|
||||
Traefik->>BFF: POST /api/v1/downloads (includes Remote-User header)
|
||||
User->>Proxy: GET https://<MAGNETFLIX_HOST>
|
||||
Proxy->>User: Renders MagNetFlix Web Form
|
||||
User->>Proxy: Submit form (magnet URI + IMDb ID: tt1375666)
|
||||
Proxy->>BFF: POST /api/v1/downloads (includes AUTH_HEADER_USER header)
|
||||
BFF->>Worker: gRPC SubmitDownload(magnet, imdb_id, user)
|
||||
Worker->>Worker: Resolve TMDB title/year (Stage 1)
|
||||
Worker-->>BFF: Acknowledged (Job ID: job-42)
|
||||
BFF-->>User: Enqueued! Showing live progress
|
||||
Worker->>Engine: Start torrent download in /data/staging/job-42
|
||||
Engine-->>Worker: Download Completed
|
||||
Worker->>Worker: Run Security Whitelist Scan (Purge .exe/.bat)
|
||||
Worker->>Worker: Verify IMDb metadata & rename files
|
||||
Worker->>Media: Move to /media/movies/Inception (2010) [imdbid-tt1375666]/
|
||||
Worker->>Worker: Run Two-Tier Security Scan (Hard-fail .exe/.bat)
|
||||
Worker->>Worker: Verify cached TMDB title/year tokens & rename files
|
||||
Worker->>Media: Atomic swap to /media/movies/Inception (2010) [imdbid-tt1375666]/
|
||||
Worker-->>BFF: Status: COMPLETED
|
||||
BFF-->>User: Notification: Movie ready in library!
|
||||
```
|
||||
+59
-78
@@ -1,6 +1,6 @@
|
||||
# 🗺️ MagNetFlix — Reconciled Implementation Roadmap
|
||||
# 🗺️ MagNetFlix — MVP-First Implementation Roadmap
|
||||
|
||||
This roadmap breaks down the completion of **MagNetFlix** into clear, dependency-ordered milestones. Each milestone includes explicit prerequisites, work items, and verifiable exit criteria.
|
||||
This roadmap organizes **MagNetFlix** using an **MVP-first vertical slice strategy**: deliver a safe, usable local movie downloader as early as Milestone 2 (**Safe Walking Skeleton MVP**), then layer reliability hardening, SSO/SSE/autocomplete polish, and production reverse-proxy deployment in Milestones 3–5 without losing any architectural requirements (`DEC-1`–`DEC-8`).
|
||||
|
||||
---
|
||||
|
||||
@@ -8,11 +8,11 @@ This roadmap breaks down the completion of **MagNetFlix** into clear, dependency
|
||||
|
||||
```mermaid
|
||||
flowchart TD
|
||||
M1["Milestone 1: Contracts, Toolchain & DB Hardening\n(GAP-1, GAP-2, TD-1, TD-2, TD-3)"]
|
||||
M2["Milestone 2: Pipeline Domain Engine & Filesystem Safety\n(GAP-3, GAP-4, GAP-5)"]
|
||||
M3["Milestone 3: Transmission Integration & Worker Coordinator\n(GAP-6, GAP-7)"]
|
||||
M4["Milestone 4: FastAPI BFF Gateway, SSE & Web UI\n(GAP-8)"]
|
||||
M5["Milestone 5: Multi-Container Stack & Deployment Verification\n(Traefik, SSO, Compose)"]
|
||||
M1["Milestone 1: Contracts, Toolchain & DB Foundation (Done)"]
|
||||
M2["Milestone 2: Safe Walking Skeleton MVP\n(Sanitizer + Stage 1 TMDB + Core Relocator + Worker + Minimal BFF + Dev Compose)"]
|
||||
M3["Milestone 3: Reliability, Metadata Hardening & Crash Recovery\n(M1.8 Base32/Index + Stage 2 Verify + Multi-Track Subs + Recovery + Pools)"]
|
||||
M4["Milestone 4: SSO Security, Real-Time SSE & TMDB Autocomplete UX\n(Fail-Closed Auth + Legacy Alias + Search Proxy + SSE Pub/Sub)"]
|
||||
M5["Milestone 5: Production Reverse-Proxy Deployment & Hardened Verification\n(Traefik Labels + Healthchecks + Locked-Down E2E)"]
|
||||
|
||||
M1 --> M2
|
||||
M2 --> M3
|
||||
@@ -22,10 +22,11 @@ flowchart TD
|
||||
|
||||
---
|
||||
|
||||
## 📌 Milestone 1: Contracts, Toolchain & Database Hardening
|
||||
- **Objective:** Fix broken gRPC stub imports, ensure 100% reproducible offline container builds, eliminate the active-job deduplication race, and establish database schema invariants.
|
||||
## 📌 Milestone 1: Contracts, Toolchain & Database Hardening (`Complete`)
|
||||
- **Objective:** Fix broken gRPC stub imports, ensure 100% reproducible offline container builds, eliminate the active `imdb_id` deduplication race, and establish database schema invariants.
|
||||
- **Dependencies:** None.
|
||||
- **Requirements Satisfied:** `REQ-1`, `REQ-2`.
|
||||
- **Status:** Complete (`6/6` Gitea issues closed in Milestone `#13`). Former `M1.8` (`Base32 btih info_hash` normalization + Alembic migration `003` + `uq_download_jobs_active_info_hash`) is resequenced to `M3.1` so Milestone 1 closes cleanly and M2 enforces `urn:btih:<40-hex>` validation in `SubmitDownload` until `M3.1` lands.
|
||||
- **Work Items:**
|
||||
- [x] `M1.1`: Create `services/contracts` workspace package (`pyproject.toml`, `module-name = "magnetflix"`).
|
||||
- [x] `M1.2`: Reconfigure `buf.gen.yaml` to output stubs into `services/contracts/src`; generate and track stubs + `docs/api_spec.md` in Git (`DEC-1`).
|
||||
@@ -34,99 +35,79 @@ flowchart TD
|
||||
- [x] `M1.5`: Update `services/worker/Dockerfile` and `services/bff/Dockerfile` to copy `services/contracts`, and include `alembic.ini` and `alembic/` in the Worker image.
|
||||
- [x] `M1.6`: Create Alembic migration `002_add_info_hash_and_partial_unique_index.py` adding `info_hash` column and `uq_download_jobs_active_imdb_id` index (`DEC-2`).
|
||||
- [x] `M1.7`: Update `DownloadJob` model and add unit tests in `tests/test_db.py` verifying duplicate active insertion rejection.
|
||||
- [ ] `M1.8` *(Architecture Review Follow-up)*: Normalize Base32 `btih` `info_hash` to 40-char lowercase hex in `DownloadJob` and add partial unique index `uq_download_jobs_active_info_hash` via Alembic migration `003`.
|
||||
- **Verifiable Exit Criteria:**
|
||||
- `uv run python -c "from magnetflix.v1 import pipeline_pb2, pipeline_pb2_grpc"` succeeds with 0 errors.
|
||||
- `uv run ruff check .` and `uv run pyright` pass cleanly across the entire workspace including contracts and tests.
|
||||
- `uv run pytest tests/test_db.py` passes all tests including partial unique index verification.
|
||||
- `uv run pytest` passes all contract and database tests.
|
||||
|
||||
---
|
||||
|
||||
## 📌 Milestone 2: Pipeline Domain Engine & Filesystem Safety
|
||||
- **Objective:** Implement core business logic and security boundary modules: untrusted payload sanitization, metadata verification, and cross-volume publication.
|
||||
## 📌 Milestone 2: Safe Walking Skeleton MVP (Local End-to-End Pipeline)
|
||||
- **Objective:** Deliver a working, torrent-safe local vertical slice: submit a magnet URI + IMDb ID in a browser UI, download via Transmission, enforce Two-Tier Sanitizer security checks, resolve TMDB movie metadata, atomically publish into `/media/movies/<Title> (<Year>) [imdbid-<IMDbID>]/`, and poll live job progress.
|
||||
- **Dependencies:** Milestone 1.
|
||||
- **Requirements Satisfied:** `REQ-3`, `REQ-4`, `REQ-5`.
|
||||
- **Requirements Satisfied:** `REQ-3`, `REQ-4` (Stage 1), `REQ-5` (Core), `REQ-6`, `REQ-7` (Core), `REQ-8`, `REQ-9` (Core API/UI), `REQ-11` (Local Dev Slice).
|
||||
- **Explicit Deferrals to Post-MVP:** Stage 2 filename token-overlap verification (`M3.2`), Base32 `btih` normalization + `uq_download_jobs_active_info_hash` (`M3.1`), multi-track subtitle language/forced tag parsing (`M3.3`), 15-min stall timeout + startup active reconciliation + dedicated relocation pool (`M3.4`), standard gRPC health check (`M3.5`), SSO middleware enforcement + legacy `POST /download` + TMDB search autocomplete + SSE pub/sub (`M4`), and Traefik production Compose (`M5`).
|
||||
- **Work Items:**
|
||||
- [ ] `M2.1`: Implement Media Sanitizer (`services/worker/src/worker/sanitizer.py`) adhering to `DEC-3`:
|
||||
- Hard-fail on symlinks, hard links, `..` traversal, special files, and dangerous extensions (case-insensitive: `.exe`, `.bat`, `.cmd`, `.sh`, `.scr`, `.vbs`, `.ps1`, `.lnk`, `.iso`, `.zip`, `.rar`, `.7z`).
|
||||
- Safely ignore unlisted non-dangerous files (such as `.nfo`, `.txt`, `.jpg`, `.sfv`).
|
||||
- Discard samples (`< 100 MB` or case-insensitive word-boundary `"sample"` token / `Sample` directory); select largest primary video and allowlisted subtitles (`.srt`, `.vtt`, `.sub`, `.ass`).
|
||||
- [ ] `M2.2`: Write unit tests in `tests/test_sanitizer.py` verifying all security, allowlist, and sample discard rules.
|
||||
- [ ] `M2.3`: Implement TMDB Client & Token Verifier (`services/worker/src/worker/metadata.py`) adhering to `DEC-4`:
|
||||
- Early resolution via `GET /find/{imdb_id}?external_source=imdb_id` using `httpx.AsyncClient` with bounded timeouts/retries.
|
||||
- Validates IMDb ID format, validates movie entity type, extracts `(title, year)`.
|
||||
- Post-download normalized token comparison between cached `(title, year)` and primary video filename.
|
||||
- [ ] `M2.4`: Write unit tests in `tests/test_metadata.py` with mocked TMDB HTTP responses (match, 404, non-movie, mismatch).
|
||||
- [ ] `M2.5`: Implement Library Relocator (`services/worker/src/worker/relocator.py`) adhering to `DEC-5`:
|
||||
- Deterministic `<Title>` path sanitization (stripping/replacing `/`, `\`, `:`, `*`, `?`, `"`, `<`, `>`, `|`, `..`).
|
||||
- Multi-track subtitle format preservation (`.srt`, `.vtt`, `.sub`, `.ass`) with language/forced tags, untagged fallback (`<SanitizedTitle> (<Year>).<ext>`), and disambiguation indices.
|
||||
- Free-space pre-check + two-stage copy-and-swap: copy to `/media/movies/.staging_<job_id>/`, pre-check destination directory existence, and atomically swap via `os.replace`.
|
||||
- [ ] `M2.6`: Write unit tests in `tests/test_relocator.py` asserting destination file layout and atomic swap error handling.
|
||||
- [ ] `M2.1`: **Two-Tier Media Sanitizer** (`services/worker/src/worker/sanitizer.py` & `tests/test_sanitizer.py`) adhering to `DEC-3`:
|
||||
- Export `scan_staging_dir(staging_dir: Path, min_video_bytes: int | None = None) -> SanitizedPayload` (default threshold from `MIN_VIDEO_BYTES`, fallback `100_000_000` bytes).
|
||||
- Traverse with `os.walk(staging_dir, followlinks=False)` and run security checks across the **entire tree before** sample discard (including inside `Sample/` folders): reject path escape (`..`), reject *all* symlinks and special nodes (FIFO/socket/device), reject hard links (`st_nlink > 1` on regular files `S_ISREG` only), and hard-fail on dangerous extensions case-insensitively (`.exe`, `.bat`, `.cmd`, `.sh`, `.scr`, `.vbs`, `.ps1`, `.lnk`, `.iso`, `.zip`, `.rar`, `.7z`).
|
||||
- Safely ignore unlisted clutter (`.nfo`, `.txt`, `.jpg`, `.sfv`).
|
||||
- Discard sample files (`sample`/`samples` directory components or case-insensitive `\bsample\b` filename stem) and video files `< min_video_bytes`; **never** size-filter subtitles.
|
||||
- Select largest qualifying video (`.mkv`, `.mp4`, `.avi`, `.webm`) and deterministically sorted allowlisted subtitles (`.srt`, `.vtt`, `.sub`, `.ass`), or raise an explicit domain error if no qualifying video remains.
|
||||
- [ ] `M2.2`: **Stage 1 TMDB Metadata Client & Core Atomic Relocator** (`services/worker/src/worker/metadata.py`, `services/worker/src/worker/relocator.py`, `tests/test_metadata.py`, `tests/test_relocator.py`) adhering to `DEC-4` (Stage 1) & `DEC-5` (Core):
|
||||
- `TmdbClient`: validate `TMDB_API_KEY` lazily at call time (raising explicit config error if missing, keeping module imports test-safe), validate `^tt\d{7,10}$`, call TMDB v3 `GET /find/{imdb_id}?external_source=imdb_id&api_key=...` via `httpx.AsyncClient` (`TMDB_BASE_URL` default `https://api.themoviedb.org/3`, `10s` timeout, max 2 retries on `5xx`/network errors), require non-empty `movie_results` (rejecting TV/missing), and extract `MovieMetadata(title, year, imdb_id, tmdb_id)` requiring a valid 4-digit `release_date` year.
|
||||
- `relocator.py`: `sanitize_title(title)` replacing forbidden/control chars (`/ \ : * ? " < > | \x00-\x1f \x7f`) and `..` with spaces, collapsing whitespace, and stripping leading/trailing dots/spaces (failing if empty); ensure `MEDIA_DIR` exists, scan `MEDIA_DIR` for existing `*[imdbid-<IMDbID>]*` or exact canonical target `<SanitizedTitle> (<Year>) [imdbid-<IMDbID>]` (`DEC-2`), verify `shutil.disk_usage(MEDIA_DIR).free >= total_bytes * 1.05`, stage into `<MEDIA_DIR>/.staging_<job_id>/` (cleanup in `finally:`), name `<SanitizedTitle> (<Year>).<ext>` (deterministic `.1`, `.2` suffixes on same-extension subtitle collisions), and atomically commit via `os.replace`.
|
||||
- [ ] `M2.3`: **Transmission Client, Minimal Pipeline Coordinator & Worker gRPC Server** (`transmission.py`, `pipeline.py`, `service.py`, `main.py`, `tests/test_transmission.py`, `tests/test_pipeline.py`, `tests/test_grpc_service.py`):
|
||||
- `TransmissionClient`: instantiate `transmission_rpc.Client` lazily per operation inside `asyncio.to_thread` (`TRANSMISSION_HOST`, `TRANSMISSION_PORT`, optional `TRANSMISSION_USER`/`TRANSMISSION_PASS`); provide `add_torrent(magnet_uri, download_dir) -> str`, `get_progress(info_hash) -> TorrentProgress(progress_pct, download_rate_bytes, is_finished, status, error_message)`, and `remove_torrent(info_hash, delete_data=True)` (failing fast if `torrent.error != 0` or missing).
|
||||
- `PipelineCoordinator`: `SubmitDownload` validates `urn:btih:<40-hex>` (rejecting Base32/non-btih magnets with `INVALID_ARGUMENT` until `M3.1`), checks active `imdb_id`/`info_hash` duplicates and existing library `[imdbid-...]` directory (`ALREADY_EXISTS`), resolves Stage 1 TMDB metadata (`NOT_FOUND`/`INVALID_ARGUMENT`/`UNAVAILABLE`), persists `QUEUED` job, and spawns a tracked `asyncio.Task` to run `QUEUED -> DOWNLOADING -> SCANNING -> VERIFYING_METADATA` (MVP pass-through) `-> ORGANIZING -> COMPLETED` (or `FAILED`), polling every `POLL_INTERVAL_SECONDS` (default `2.0`), offloading scan/relocate via `asyncio.to_thread`, updating SQLite via short-lived sessions, and cleaning up Transmission torrent + `<STAGING_DIR>/<job_id>` in `finally:`.
|
||||
- `PipelineServiceServicer` & `worker/main.py`: implement `SubmitDownload`, `GetJob` (omitting empty `completed_at` timestamps for unfinished jobs), `ListJobs` (integer offset `page_token` default `"0"`, `page_size` default `20` clamped `1..100`, ordered by `created_at DESC, id DESC`, optional `state_filter`), and return `UNIMPLEMENTED` for `StreamJobStatus`; serve on `WORKER_GRPC_PORT` (default `50051`) with graceful `SIGTERM`/`SIGINT` shutdown.
|
||||
- [ ] `M2.4`: **Minimal FastAPI BFF, Polling Web UI, Local `docker-compose.yml` & Live Torrent E2E** (`services/bff/src/bff/grpc_client.py`, `main.py`, `services/bff/src/bff/templates/index.html`, `docker-compose.yml`, `tests/test_bff_routes.py`):
|
||||
- BFF app keeps `AUTH_ENABLED` defaulting to `true` (`DEC-8`, returning `401` on `/api/*` when enabled without `AUTH_HEADER_USER`), using `local_user` only when `AUTH_ENABLED=false` is explicitly configured in local Compose; resolves templates via `Path(__file__).resolve().parent / "templates"` to match `services/bff/Dockerfile`.
|
||||
- Routes: `GET /healthz` (`{"status": "ok"}`), `POST /api/v1/downloads` (`201 Created`, `{imdb_id, magnet_uri}` $\rightarrow$ `{job_id, message}`), `GET /api/v1/downloads` (`{"jobs": [...], "next_page_token": "..."}`), `GET /api/v1/downloads/{job_id}`, and `GET /` polling HTML form every `3s`; explicit gRPC $\rightarrow$ HTTP error mapping (`ALREADY_EXISTS` $\rightarrow$ `409`, `NOT_FOUND` $\rightarrow$ `404`, `INVALID_ARGUMENT` $\rightarrow$ `422`, `UNAVAILABLE` $\rightarrow$ `503`).
|
||||
- Local `docker-compose.yml`: `transmission` (`healthcheck`, `PUID`/`PGID`, `./data/staging:/data/staging`, `./config/transmission:/config`, `incomplete-dir-enabled` verified `false`), `worker` (`user: "${PUID:-1000}:${PGID:-1000}"`, `depends_on: transmission: condition: service_healthy`, runs `alembic upgrade head && exec python -m worker.main`, canonical env vars `DATABASE_URL=sqlite+aiosqlite:////data/magnetflix.sqlite3`, `STAGING_DIR=/data/staging`, `MEDIA_DIR=/media/movies`, `TMDB_API_KEY`), and `bff` (`8000:8000`, `GRPC_WORKER_HOST=worker:50051`, `AUTH_ENABLED=false`).
|
||||
- Document/prepare pre-created `./data/staging`, `./media/movies`, `./config/transmission` owned by `PUID:PGID`, and verify a live `>= 100 MB` legal public-domain torrent completes end-to-end.
|
||||
- **Verifiable Exit Criteria:**
|
||||
- `uv run pytest tests/test_sanitizer.py tests/test_metadata.py tests/test_relocator.py` passes 100%.
|
||||
- Zero filesystem breakout vulnerabilities possible under synthetic traversal fixtures.
|
||||
- `uv run ruff check .`, `uv run pyright`, and `uv run pytest` pass 100% across `tests/test_contracts.py`, `tests/test_db.py`, `tests/test_sanitizer.py`, `tests/test_metadata.py`, `tests/test_relocator.py`, `tests/test_transmission.py`, `tests/test_pipeline.py`, `tests/test_grpc_service.py`, and `tests/test_bff_routes.py`.
|
||||
- `docker compose build && docker compose up -d` starts cleanly and delivers a real public-domain movie into `./media/movies/<Title> (<Year>) [imdbid-<IMDbID>]/`.
|
||||
|
||||
---
|
||||
|
||||
## 📌 Milestone 3: Transmission Integration & Worker Coordinator
|
||||
- **Objective:** Wrap Transmission RPC, coordinate the pipeline finite state machine, implement startup crash recovery, and expose the gRPC service.
|
||||
## 📌 Milestone 3: Reliability, Metadata Hardening & Crash Recovery
|
||||
- **Objective:** Close remaining `DEC-2`–`DEC-7` safety and operational resilience gaps deferred from the MVP slice.
|
||||
- **Dependencies:** Milestone 2.
|
||||
- **Requirements Satisfied:** `REQ-6`, `REQ-7`, `REQ-8`.
|
||||
- **Requirements Satisfied:** `REQ-2` (`M1.8`), `REQ-4` (Stage 2), `REQ-5` (Multi-track subtitles), `REQ-7` (Stall timeout, Crash recovery, Executor isolation).
|
||||
- **Work Items:**
|
||||
- [ ] `M3.1`: Implement Transmission RPC Client Wrapper (`services/worker/src/worker/transmission.py`) adhering to `DEC-6`:
|
||||
- `add_torrent(magnet_uri, download_dir=/data/staging/<job_id>)`.
|
||||
- `get_progress(info_hash)` returning progress percentage and download speed.
|
||||
- `remove_torrent(info_hash, delete_data=True)` for terminal cleanup.
|
||||
- [ ] `M3.2`: Write unit tests in `tests/test_transmission.py` with mocked RPC client.
|
||||
- [ ] `M3.3`: Implement Pipeline Coordinator & State Machine (`services/worker/src/worker/pipeline.py`) adhering to `DEC-6` & `DEC-7`:
|
||||
- State progression: `QUEUED` $\rightarrow$ `DOWNLOADING` $\rightarrow$ `SCANNING` $\rightarrow$ `VERIFYING_METADATA` $\rightarrow$ `ORGANIZING` $\rightarrow$ `COMPLETED` (with `FAILED` reachable from any active state).
|
||||
- 15-minute zero-progress-delta stalled torrent timeout.
|
||||
- Startup crash recovery: query non-terminal jobs, fail DB rows, purge staging directories, remove torrents from Transmission (with bounded startup retry/backoff).
|
||||
- Dedicated bounded relocation executor isolated from lightweight `transmission-rpc` and scan offloading.
|
||||
- In-memory `asyncio.Queue` broadcaster (subscribe-before-snapshot + bounded per-subscriber coalescing) for real-time status streaming.
|
||||
- [ ] `M3.4`: Implement gRPC Server Servicer (`services/worker/src/worker/service.py` & `main.py`) adhering to `pipeline.proto`:
|
||||
- Implements `SubmitDownload`, `GetJob`, `ListJobs`, and `StreamJobStatus` plus gRPC health check.
|
||||
- Maps application errors to proper gRPC status codes (`ALREADY_EXISTS`, `NOT_FOUND`, `INVALID_ARGUMENT`).
|
||||
- [ ] `M3.5`: Write integration tests in `tests/test_pipeline.py` and `tests/test_grpc_service.py`.
|
||||
- [ ] `M3.1`: *(Relocated `M1.8`)* Normalize Base32 `btih` `info_hash` to 40-char lowercase hex (accepting both 32-char Base32 and 40-char hex magnets in `SubmitDownload`) and add partial unique index `uq_download_jobs_active_info_hash` via Alembic migration `003` (`DEC-2`).
|
||||
- [ ] `M3.2`: Implement **Stage 2 Offline Token-Overlap Verifier** in `metadata.py` and wire `VERIFYING_METADATA` in `pipeline.py` to fail jobs whose sanitized primary video filename mismatches cached `(title, year)` (`DEC-4`).
|
||||
- [ ] `M3.3`: Implement **Multi-Track Subtitle Format & Tag Parser** in `relocator.py` preserving `.srt`, `.vtt`, `.sub`, `.ass` with normalized ISO-639 language + `.forced` tags and deterministic disambiguation indices (`DEC-5`).
|
||||
- [ ] `M3.4`: Harden `pipeline.py` with a 15-minute zero-progress-delta stall timeout, startup active reconciliation sweep (failing orphaned non-terminal jobs, removing Transmission torrents with bounded startup retry, purging staging dirs), and a dedicated bounded `ThreadPoolExecutor` isolating heavy relocation copies from RPC/scan offloading (`DEC-6`, `DEC-7`).
|
||||
- [ ] `M3.5`: Enable standard gRPC health checking (`grpcio-health-checking`) on the Worker server and add failure-injection tests for stall timeouts, crash recovery, and metadata mismatch rejection.
|
||||
- **Verifiable Exit Criteria:**
|
||||
- `uv run pytest tests/test_pipeline.py tests/test_grpc_service.py` passes 100%.
|
||||
- Worker process cleanly starts, handles startup reconciliation, and shuts down gracefully with `SIGTERM`.
|
||||
- Crash recovery + failure-injection suites pass; orphaned staging directories and stalled torrents are deterministically cleaned up.
|
||||
|
||||
---
|
||||
|
||||
## 📌 Milestone 4: FastAPI BFF Gateway, SSE & Web UI
|
||||
- **Objective:** Implement the user-facing web gateway, pluggable SSO identity adapter, server-side TMDB search proxy, real-time SSE stream, and single-origin UI.
|
||||
## 📌 Milestone 4: SSO Security, Real-Time SSE & TMDB Autocomplete UX
|
||||
- **Objective:** Replace MVP polling and dev-only submission with fail-closed SSO enforcement, legacy extension compatibility, TMDB autocomplete search, and live Server-Sent Events streaming.
|
||||
- **Dependencies:** Milestone 3.
|
||||
- **Requirements Satisfied:** `REQ-9`, `REQ-10`.
|
||||
- **Requirements Satisfied:** `REQ-8` (`StreamJobStatus`), `REQ-9`, `REQ-10`.
|
||||
- **Work Items:**
|
||||
- [ ] `M4.1`: Implement Pluggable Identity Adapter Middleware in FastAPI (`DEC-8`):
|
||||
- Configurable via `AUTH_ENABLED`, `AUTH_HEADER_USER`, and `CORS_ALLOWED_ORIGINS`; fails closed with `401` when `AUTH_ENABLED=true` and falls back to `local_user` only when `AUTH_ENABLED=false`.
|
||||
- [ ] `M4.2`: Implement BFF gRPC Client Wrapper (`services/bff/src/bff/grpc_client.py`):
|
||||
- Channels calls to Worker (`SubmitDownload`, `GetJob`, `ListJobs`, `StreamJobStatus`).
|
||||
- [ ] `M4.3`: Implement REST Endpoints & Schemas (`services/bff/src/bff/main.py`):
|
||||
- Dual route bindings: `POST /api/v1/downloads` and `POST /download` with Pydantic aliases (`magnet`/`magnet_uri`, `imdbid`/`imdb_id`).
|
||||
- Server-side TMDB movie search proxy: `GET /api/v1/movies/search?q=...`.
|
||||
- Server-Sent Events stream: `GET /api/v1/movies/events`.
|
||||
- [ ] `M4.4`: Embed Hosted Web UI (`services/bff/src/bff/templates/` & `static/`):
|
||||
- Clean, responsive dashboard (adapted from extension prototype `app.html`/`app.css`).
|
||||
- Movie search autocomplete with poster previews, magnet input, and live progress bars.
|
||||
- [ ] `M4.5`: Write API tests in `tests/test_bff_routes.py` covering auth extraction, dual routes, search proxy, and SSE streams.
|
||||
- [ ] `M4.1`: Harden **Pluggable Identity Adapter & CORS** in FastAPI BFF (`DEC-8`): enforce fail-closed `401` when `AUTH_ENABLED=true` and `AUTH_HEADER_USER` header is missing/empty (`/healthz` exempt), enforce `CORS_ALLOWED_ORIGINS` allowlist.
|
||||
- [ ] `M4.2`: Add legacy extension route compatibility (`POST /download` alongside `POST /api/v1/downloads` with Pydantic `AliasChoices` for `magnet`/`magnet_uri` and `imdbid`/`imdb_id`).
|
||||
- [ ] `M4.3`: Implement server-side **TMDB Search Proxy** (`GET /api/v1/movies/search?q=...` with IMDb ID enrichment) and upgrade `services/bff/src/bff/templates/` + `static/` to autocomplete search with poster previews and live progress cards.
|
||||
- [ ] `M4.4`: Implement Worker in-memory `asyncio.Queue` **subscribe-before-snapshot coalescing broadcaster** (`StreamJobStatus` RPC, `DEC-7`) and BFF **SSE endpoint** (`GET /api/v1/movies/events`) replacing frontend polling, with full SSE/auth route tests.
|
||||
- **Verifiable Exit Criteria:**
|
||||
- `uv run pytest tests/test_bff_routes.py` passes 100%.
|
||||
- BFF connects to gRPC worker, serves Web UI, and streams live download progress without browser CORS errors.
|
||||
- `uv run pytest tests/test_bff_routes.py` validates fail-closed `401`, legacy dual routes, search proxy, and live SSE streaming without CORS errors.
|
||||
|
||||
---
|
||||
|
||||
## 📌 Milestone 5: Multi-Container Stack & Deployment Verification
|
||||
- **Objective:** Deliver production-ready containerization, Docker Compose stack, Traefik integration, and end-to-end slice verification.
|
||||
## 📌 Milestone 5: Production Reverse-Proxy Deployment & Hardened Verification
|
||||
- **Objective:** Finalize production Traefik reverse-proxy configuration, container health probes, and hardened end-to-end verification (`docs/deployment.md`).
|
||||
- **Dependencies:** Milestone 4.
|
||||
- **Requirements Satisfied:** `REQ-11`.
|
||||
- **Requirements Satisfied:** `REQ-11` (Production Deployment).
|
||||
- **Work Items:**
|
||||
- [ ] `M5.1`: Finalize `services/worker/Dockerfile` and `services/bff/Dockerfile`.
|
||||
- [ ] `M5.2`: Author canonical `docker-compose.yml` defining `bff`, `worker`, and `transmission` services, volume mounts (`./data`, `/media/movies`), and internal/external networks.
|
||||
- [ ] `M5.3`: Configure health probes: BFF `GET /healthz`, Worker gRPC standard health check.
|
||||
- [ ] `M5.4`: Execute end-to-end integration test with a small public domain/legal torrent:
|
||||
- Verify full lifecycle: Form submission $\rightarrow$ Transmission download $\rightarrow$ Sanitizer scan $\rightarrow$ Metadata token check $\rightarrow$ Two-stage atomic relocation into Jellyfin/Plex format $\rightarrow$ Live SSE completion update.
|
||||
- [ ] `M5.1`: Reconcile production `docker-compose.yml` (or production overlay) matching `docs/deployment.md`: Traefik labels, `proxy_network` external bridge + internal `backend` network isolating Worker, `AUTH_ENABLED=true`, and verified non-root `PUID`/`PGID` bind-mount permissions.
|
||||
- [ ] `M5.2`: Add Docker `HEALTHCHECK` directives (`/healthz` on BFF, gRPC health probe on Worker) and audit multi-stage image builds.
|
||||
- [ ] `M5.3`: Execute full production E2E verification: SSO header auth $\rightarrow$ TMDB autocomplete $\rightarrow$ Transmission download $\rightarrow$ Two-Tier Sanitizer $\rightarrow$ Stage 2 token check $\rightarrow$ Multi-track atomic relocation $\rightarrow$ Live SSE completion + restart crash-recovery drill.
|
||||
- **Verifiable Exit Criteria:**
|
||||
- `docker compose build` succeeds with zero errors from a fresh checkout.
|
||||
- Full end-to-end vertical slice runs to completion with media appearing in `/media/movies/<Title> (<Year>) [imdbid-<IMDbID>]/`.
|
||||
- Fresh `docker compose build` succeeds with zero errors, container health checks stay `healthy`, and full hardened E2E lifecycle passes under `AUTH_ENABLED=true`.
|
||||
@@ -51,7 +51,7 @@
|
||||
# Automatically sync uv workspace if .venv is missing
|
||||
if [ ! -d ".venv" ]; then
|
||||
echo "Creating virtual environment and syncing workspace..."
|
||||
uv sync
|
||||
uv sync --all-packages
|
||||
fi
|
||||
'';
|
||||
};
|
||||
|
||||
@@ -7,7 +7,7 @@ import "google/protobuf/timestamp.proto";
|
||||
// PipelineService coordinates movie download jobs, safety scans, and library relocation.
|
||||
service PipelineService {
|
||||
// SubmitDownload enqueues a new movie download job.
|
||||
// Rejects duplicate submissions if an active job for the same IMDb ID exists or if already in library.
|
||||
// Rejects duplicate submissions if an active job for the same IMDb ID or info_hash exists, or if already in library.
|
||||
rpc SubmitDownload (SubmitDownloadRequest) returns (SubmitDownloadResponse);
|
||||
|
||||
// GetJob retrieves the current status and metadata of a specific job.
|
||||
@@ -40,7 +40,7 @@ message SubmitDownloadRequest {
|
||||
string magnet_uri = 1;
|
||||
// IMDb ID of the movie (e.g., "tt1375666").
|
||||
string imdb_id = 2;
|
||||
// Username of the user requesting the download (from Authelia Remote-User).
|
||||
// Username of the user requesting the download (from upstream SSO identity header).
|
||||
string requested_by = 3;
|
||||
}
|
||||
|
||||
|
||||
@@ -4,8 +4,9 @@ WORKDIR /app
|
||||
|
||||
ENV UV_COMPILE_BYTECODE=1
|
||||
|
||||
# Copy workspace files
|
||||
# Copy workspace manifests and required packages so frozen lockfile resolution succeeds
|
||||
COPY pyproject.toml uv.lock ./
|
||||
COPY services/worker/pyproject.toml services/worker/README.md ./services/worker/
|
||||
COPY services/contracts ./services/contracts
|
||||
COPY services/bff ./services/bff
|
||||
|
||||
|
||||
@@ -7,6 +7,7 @@ requires-python = ">=3.12"
|
||||
dependencies = [
|
||||
"fastapi>=0.115.0",
|
||||
"grpcio>=1.83.1",
|
||||
"httpx>=0.28.0",
|
||||
"jinja2>=3.1.4",
|
||||
"protobuf>=7.36.1",
|
||||
"pydantic>=2.10.0",
|
||||
|
||||
@@ -62,7 +62,7 @@ class SubmitDownloadRequest(_message.Message):
|
||||
imdb_id: _builtins.str
|
||||
"""IMDb ID of the movie (e.g., "tt1375666")."""
|
||||
requested_by: _builtins.str
|
||||
"""Username of the user requesting the download (from Authelia Remote-User)."""
|
||||
"""Username of the user requesting the download (from upstream SSO identity header)."""
|
||||
def __init__(
|
||||
self,
|
||||
*,
|
||||
|
||||
@@ -43,7 +43,7 @@ class PipelineServiceServicer:
|
||||
|
||||
def SubmitDownload(self, request, context):
|
||||
"""SubmitDownload enqueues a new movie download job.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID exists or if already in library.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID or info_hash exists, or if already in library.
|
||||
"""
|
||||
context.set_code(grpc.StatusCode.UNIMPLEMENTED)
|
||||
context.set_details('Method not implemented!')
|
||||
|
||||
@@ -35,7 +35,7 @@ class PipelineServiceStub:
|
||||
def __new__(cls, channel: _aio.Channel) -> PipelineServiceAsyncStub: ...
|
||||
SubmitDownload: _grpc.UnaryUnaryMultiCallable[_pipeline_pb2.SubmitDownloadRequest, _pipeline_pb2.SubmitDownloadResponse]
|
||||
"""SubmitDownload enqueues a new movie download job.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID exists or if already in library.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID or info_hash exists, or if already in library.
|
||||
"""
|
||||
GetJob: _grpc.UnaryUnaryMultiCallable[_pipeline_pb2.GetJobRequest, _pipeline_pb2.GetJobResponse]
|
||||
"""GetJob retrieves the current status and metadata of a specific job."""
|
||||
@@ -54,7 +54,7 @@ class PipelineServiceAsyncStub(PipelineServiceStub):
|
||||
def __init__(self, channel: _aio.Channel) -> None: ...
|
||||
SubmitDownload: _aio.UnaryUnaryMultiCallable[_pipeline_pb2.SubmitDownloadRequest, _pipeline_pb2.SubmitDownloadResponse] # type: ignore[assignment]
|
||||
"""SubmitDownload enqueues a new movie download job.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID exists or if already in library.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID or info_hash exists, or if already in library.
|
||||
"""
|
||||
GetJob: _aio.UnaryUnaryMultiCallable[_pipeline_pb2.GetJobRequest, _pipeline_pb2.GetJobResponse] # type: ignore[assignment]
|
||||
"""GetJob retrieves the current status and metadata of a specific job."""
|
||||
@@ -76,7 +76,7 @@ class PipelineServiceServicer(metaclass=_abc_1.ABCMeta):
|
||||
context: _ServicerContext,
|
||||
) -> _typing.Union[_pipeline_pb2.SubmitDownloadResponse, _abc.Awaitable[_pipeline_pb2.SubmitDownloadResponse]]:
|
||||
"""SubmitDownload enqueues a new movie download job.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID exists or if already in library.
|
||||
Rejects duplicate submissions if an active job for the same IMDb ID or info_hash exists, or if already in library.
|
||||
"""
|
||||
|
||||
@_abc_1.abstractmethod
|
||||
|
||||
@@ -4,8 +4,9 @@ WORKDIR /app
|
||||
|
||||
ENV UV_COMPILE_BYTECODE=1
|
||||
|
||||
# Copy workspace files
|
||||
# Copy workspace manifests and required packages so frozen lockfile resolution succeeds
|
||||
COPY pyproject.toml uv.lock ./
|
||||
COPY services/bff/pyproject.toml services/bff/README.md ./services/bff/
|
||||
COPY services/contracts ./services/contracts
|
||||
COPY services/worker ./services/worker
|
||||
|
||||
@@ -25,6 +26,7 @@ COPY services/worker/alembic ./alembic
|
||||
|
||||
ENV PATH="/app/.venv/bin:$PATH"
|
||||
ENV PYTHONPATH="/app/services/worker/src:/app/services/contracts/src"
|
||||
ENV DATABASE_URL="sqlite+aiosqlite:////data/magnetflix.sqlite3"
|
||||
|
||||
EXPOSE 50051
|
||||
CMD ["python", "-m", "worker.main"]
|
||||
@@ -9,6 +9,7 @@ dependencies = [
|
||||
"alembic>=1.14.0",
|
||||
"httpx>=0.28.0",
|
||||
"grpcio>=1.83.1",
|
||||
"grpcio-health-checking>=1.83.1",
|
||||
"protobuf>=7.36.1",
|
||||
"pydantic>=2.10.0",
|
||||
"sqlalchemy>=2.0.36",
|
||||
|
||||
@@ -140,7 +140,7 @@ class DownloadJob(Base):
|
||||
String(128),
|
||||
nullable=False,
|
||||
index=True,
|
||||
doc="Authenticated user from Remote-User SSO header",
|
||||
doc="Authenticated user from upstream SSO identity header",
|
||||
)
|
||||
state: Mapped[str] = mapped_column(
|
||||
String(32),
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Milestone 1: Contracts, Toolchain & Database Hardening (Prerequisites & Blockers)
|
||||
# Milestone 1: Contracts, Toolchain & Database Hardening (Complete — M1.8 moved to M3.1)
|
||||
x 2026-10-31 (A) Create services/contracts workspace package with pyproject.toml (module-name = 'magnetflix') +contracts @workspace
|
||||
x 2026-10-31 (A) Reconfigure buf.gen.yaml to output stubs into services/contracts/src, generate stubs + docs/api_spec.md, and track in Git +proto @contracts
|
||||
x 2026-10-31 (A) Update services/worker and services/bff to depend on magnetflix-contracts via workspace dependency +deps @workspace
|
||||
@@ -6,34 +6,17 @@ x 2026-10-31 (A) Update pyproject.toml to include tests/ in pyright, remove excl
|
||||
x 2026-10-31 (A) Update services/worker/Dockerfile and services/bff/Dockerfile to copy services/contracts, and copy alembic/ into worker image +docker @deploy
|
||||
x 2026-10-31 (A) Create Alembic migration 002_add_info_hash_and_partial_unique_index.py adding info_hash column and uq_download_jobs_active_imdb_id index +db @worker
|
||||
x 2026-10-31 (A) Update DownloadJob ORM model and write unit tests in tests/test_db.py verifying duplicate active insertion rejection +test @worker
|
||||
(A) Normalize Base32 btih info_hash to 40-char lowercase hex in DownloadJob and add partial unique index uq_download_jobs_active_info_hash via Alembic migration 003 +db @worker
|
||||
|
||||
# Milestone 2: Pipeline Domain Engine & Filesystem Safety
|
||||
(B) Implement Two-Tier Media Sanitizer in services/worker/src/worker/sanitizer.py (hard-fail on symlinks/traversal/executables, ignore .txt/.nfo, sample discard, largest video selector) +sanitizer @worker
|
||||
(B) Write comprehensive unit tests in tests/test_sanitizer.py covering allowlist, traversal, sample filtering, and largest video selection +test @worker
|
||||
(B) Implement TMDB Client & Token Verifier in services/worker/src/worker/metadata.py (early ingestion resolution via /find/{imdb_id} and post-download token overlap check) +metadata @worker
|
||||
(B) Write unit tests with mocked TMDB responses in tests/test_metadata.py verifying match, 404, non-movie rejection, and token overlap +test @worker
|
||||
(B) Implement Multi-Track Library Relocator in services/worker/src/worker/relocator.py (title path sanitization, format preservation for .srt/.vtt/.sub/.ass, language/disambiguation tagging, two-stage atomic directory swap) +relocator @worker
|
||||
(B) Write unit tests in tests/test_relocator.py testing destination directory formatting, subtitle moving, and atomic swap cleanup +test @worker
|
||||
|
||||
# Milestone 3: Transmission Integration & Worker Coordinator
|
||||
(C) Implement Transmission client wrapper in services/worker/src/worker/transmission.py (add_torrent to /data/staging/<job_id>, poll progress, remove_torrent with delete_data) +transmission @worker
|
||||
(C) Write unit tests with mocked transmission-rpc client in tests/test_transmission.py +test @worker
|
||||
(C) Implement pipeline state machine coordinator in services/worker/src/worker/pipeline.py (linear transitions + QUEUED->FAILED, 15-min zero-delta stall timeout, separate relocation pool, in-memory pub/sub queues) +pipeline @worker
|
||||
(C) Implement startup active reconciliation sweep in pipeline.py (auto-fail non-terminal jobs, remove Transmission torrents with bounded startup retry, purge staging disks) +pipeline @worker
|
||||
(C) Implement gRPC PipelineServiceServicer in services/worker/src/worker/service.py and entrypoint worker/main.py (SubmitDownload, GetJob, StreamJobStatus, ListJobs) +grpc @worker
|
||||
(C) Write integration tests in tests/test_grpc_service.py verifying duplicate rejection, job submission, status querying, and pagination +test @worker
|
||||
|
||||
# Milestone 4: FastAPI BFF Gateway, SSE & Web UI
|
||||
(D) Implement Pluggable Identity Adapter Middleware in FastAPI BFF (fail-closed 401 when AUTH_ENABLED=true, configurable AUTH_HEADER_USER/CORS, local_user only when AUTH_ENABLED=false) +auth @bff
|
||||
(D) Implement BFF gRPC client wrapper in services/bff/src/bff/grpc_client.py connecting to Worker service +grpc @bff
|
||||
(D) Implement REST endpoints in services/bff/src/bff/main.py (dual routes POST /api/v1/downloads and POST /download with Pydantic aliases, GET /api/v1/movies/search TMDB proxy) +api @bff
|
||||
(D) Implement Server-Sent Events stream GET /api/v1/movies/events connected to gRPC StreamJobStatus +sse @bff
|
||||
(D) Embed single-origin HTML Web UI dashboard in services/bff/src/bff/templates/ and static/ with movie search autocomplete, poster previews, and live progress bars +ui @bff
|
||||
(D) Write API tests in tests/test_bff_routes.py covering auth extraction, dual routes, search proxy, and SSE streams +test @bff
|
||||
|
||||
# Milestone 5: Multi-Container Stack & Deployment Verification
|
||||
(E) Finalize services/worker/Dockerfile and services/bff/Dockerfile multi-stage production builds +docker @deploy
|
||||
(E) Author canonical production-ready docker-compose.yml including bff, worker, transmission, volume mounts, and network bridges +compose @deploy
|
||||
(E) Configure Traefik routing labels, health probes (/healthz and gRPC health), and verify container communication +traefik @deploy
|
||||
(E) Execute end-to-end integration test with public domain torrent verifying full acquisition, organization, and SSE reporting lifecycle +e2e @test
|
||||
# Next Immediate Deliverable — Milestone 2: Safe Walking Skeleton MVP (See docs/roadmap.md for M3-M5)
|
||||
(A) [M2.1] Implement Two-Tier Media Sanitizer in services/worker/src/worker/sanitizer.py (os.walk followlinks=False, reject symlinks/special/S_ISREG hardlinks/traversal/dangerous exts even inside Sample/, ignore clutter, discard samples & < MIN_VIDEO_BYTES video only, select largest video + subtitles) +sanitizer @worker
|
||||
(A) [M2.1] Write unit tests in tests/test_sanitizer.py covering traversal, symlinks, hardlinks, dangerous ext inside Sample/, clutter ignore, subtitle size preservation, and largest video selection +test @worker
|
||||
(B) [M2.2] Implement Stage 1 TmdbClient in services/worker/src/worker/metadata.py (lazy TMDB_API_KEY, ^tt\d{7,10}$ validation, /find/{imdb_id} v3 query, movie_results & release_date checks) +metadata @worker
|
||||
(B) [M2.2] Implement core atomic relocator in services/worker/src/worker/relocator.py (sanitize_title, [imdbid-...] dup scan in MEDIA_DIR, disk_usage 1.05x check, .staging_<job_id> copy + os.replace swap, deterministic subtitle collision suffix) +relocator @worker
|
||||
(B) [M2.2] Write unit tests in tests/test_metadata.py and tests/test_relocator.py +test @worker
|
||||
(B) [M2.3] Implement lazy TransmissionClient wrapper in services/worker/src/worker/transmission.py via asyncio.to_thread +transmission @worker
|
||||
(B) [M2.3] Implement minimal PipelineCoordinator in services/worker/src/worker/pipeline.py (urn:btih:<40-hex> + active dup/library checks, tracked asyncio.Task, 2s polling, short-lived sessions, finally cleanup) +pipeline @worker
|
||||
(B) [M2.3] Implement gRPC PipelineServiceServicer in services/worker/src/worker/service.py & worker/main.py (SubmitDownload, GetJob omitting null completed_at, ListJobs offset/created_at DESC, UNIMPLEMENTED StreamJobStatus, SIGTERM shutdown) +grpc @worker
|
||||
(B) [M2.3] Write tests in tests/test_transmission.py, tests/test_pipeline.py, and tests/test_grpc_service.py +test @worker
|
||||
(B) [M2.4] Implement minimal FastAPI BFF in services/bff/src/bff/grpc_client.py, main.py, and services/bff/src/bff/templates/index.html (AUTH_ENABLED app default true, /healthz, POST/GET /api/v1/downloads, 3s polling form, gRPC->HTTP mapping) +api @bff
|
||||
(B) [M2.4] Write API tests in tests/test_bff_routes.py +test @bff
|
||||
(B) [M2.4] Author local docker-compose.yml (transmission healthcheck + incomplete-dir disabled, worker PUID:PGID + alembic upgrade head, bff AUTH_ENABLED=false, pre-created dirs) and run >= 100 MB public-domain torrent E2E verification +compose @deploy
|
||||
@@ -307,43 +307,66 @@ wheels = [
|
||||
|
||||
[[package]]
|
||||
name = "grpcio"
|
||||
version = "1.83.1"
|
||||
version = "1.85.1"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
dependencies = [
|
||||
{ name = "typing-extensions" },
|
||||
]
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/e2/b1/46539f5050d7c316a13396d185451f95084a74ddc68b12d818595bef0377/grpcio-1.83.1.tar.gz", hash = "sha256:9cee6fcbf2eb57c4b49451787bfa87be8efc1ca02a0b327dd4b54d44502e362b", size = 13445033, upload-time = "2026-08-28T07:09:11.464Z" }
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/f0/03/f9e805772d4d01da2a1754a5f63c58601eacaf8f1e878729217188de7d16/grpcio-1.85.1.tar.gz", hash = "sha256:5f530287d5de5f7f66089ead81de44f6787162944dab3922efa65dfdff108a1d", size = 14091456, upload-time = "2026-10-30T16:01:16.909Z" }
|
||||
wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/85/9e/a3ba13e08bbee5bf6e57597dfe4823961fd7e94c0b8afe3a4bb7dca639f3/grpcio-1.83.1-cp312-cp312-linux_armv7l.whl", hash = "sha256:5acd14c6ddf047de62cbf8745b11103ea91abbf57d1b8edd5395ccd9fcd13abb", size = 6303170, upload-time = "2026-08-28T07:08:08.188Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/1c/ae/65ce56a2527faa17d02cba4c2231c74047ad898be339486ba87f093bfb66/grpcio-1.83.1-cp312-cp312-macosx_11_0_universal2.whl", hash = "sha256:16138031a47b771860a16a975b53087f4fd5bbdbb2c03a188c5d90ad65d2bdae", size = 12165806, upload-time = "2026-08-28T07:08:10.309Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/4e/91/40432480088a2243d360864de072ed5b78c4ebbaabd29c28918f1e1b1454/grpcio-1.83.1-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:5ccc26715fd4defca5e129e280dd883b1737b65045ec50ffe22ce42104089519", size = 6872490, upload-time = "2026-08-28T07:08:12.355Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c8/62/3da2300c8c79fd20a78a8a4bb6251e5068d9af33bc8fd389b98fec35e8a3/grpcio-1.83.1-cp312-cp312-manylinux2014_i686.manylinux_2_17_i686.whl", hash = "sha256:b74f2a1d9ab1dfa3e263ef33d581613679b78d0884babf11671af26e45570ead", size = 7618367, upload-time = "2026-08-28T07:08:14.025Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/bc/19/9fc702e31a631262d7a752fa699f6022821e707fefc8bff49b1550a57729/grpcio-1.83.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:72578aa07a4008f17521ef52debcc3acfd1e2c5426243bc3ffb56a38bfe610b7", size = 7040936, upload-time = "2026-08-28T07:08:15.963Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/ec/56/95933cc44cba2429765fa065c951dd529e5771b119d9d2481b4646f1d6a5/grpcio-1.83.1-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:c12e1fc59c6dc26d10d9144453ddc6cbfe4cd4c31e874ed2d0132f88e685eb8b", size = 7573096, upload-time = "2026-08-28T07:08:17.729Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/ac/80/af63359da06b016de48cb111f144703a10043850dafa43ae0a038907b9e8/grpcio-1.83.1-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:4910b62f7d12197160bfb7de06d876d64dd12d43483e8292f98f49ca09b628d9", size = 8609442, upload-time = "2026-08-28T07:08:19.777Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/3d/fa/f0586c56bdfb8a7a2adda01e0ac2413447cde3141ab09411a5d5afdcffd3/grpcio-1.83.1-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:9e703effe3ae779925c82ac24fdb82cf4105e1096810151ed9501c5f34546b9c", size = 7984321, upload-time = "2026-08-28T07:08:22.114Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/25/8a/14ec05669f9eb295801e26c2ea8c561a1b786b0e3557c2c22131165ab010/grpcio-1.83.1-cp312-cp312-win32.whl", hash = "sha256:a2aea8bd6e0a34f12cbaddb7bb70bec836818789fa5c7ab7572c6b745396a2d4", size = 4395604, upload-time = "2026-08-28T07:08:24.08Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/e9/37/8c2f7cc16089e36a3fbacaacc7a3d043912aa0d2dfae5556f6450414ea6e/grpcio-1.83.1-cp312-cp312-win_amd64.whl", hash = "sha256:583bf2e8255040a4a312f9572dfe62a05271437b149550e1a536d5c47d2d1e8a", size = 5161512, upload-time = "2026-08-28T07:08:25.81Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/7c/fd/d1fc58933bf88c9209f89dc570c810f1aa57cb04b3459cf2b26f61e32112/grpcio-1.83.1-cp313-cp313-linux_armv7l.whl", hash = "sha256:8d228e253b77865efcbdd7b5894ca882c9e0ea98c02b7d20582e61ded8dfd4b5", size = 6305628, upload-time = "2026-08-28T07:08:27.872Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c4/49/0b40bae059c619505c9b751cee6caa208e4904e290aaefa1728c4c2c67a5/grpcio-1.83.1-cp313-cp313-macosx_11_0_universal2.whl", hash = "sha256:0468b627f2987c9a77f7580030207cbd85457ffe52998beff4f0b5c38c58a72c", size = 12156839, upload-time = "2026-08-28T07:08:30.191Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/61/4b/e8c0d635da0ee5ddd9950c8d540f5dcdd0ef1854a382cc55496a487a8d31/grpcio-1.83.1-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:a6a282e81530cead60bbd752cc04950a57f224379e9821495d6a35bd5ce9b1f4", size = 6877036, upload-time = "2026-08-28T07:08:32.285Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c5/d4/760a33f339a7dd3d5f4b3e0e9bec5472d95592a80f887b2e9dab4e41cfbc/grpcio-1.83.1-cp313-cp313-manylinux2014_i686.manylinux_2_17_i686.whl", hash = "sha256:947d945f52e8ecf3cafd2bb7113502a16ccfda3e12c854443094de32d83ad432", size = 7624404, upload-time = "2026-08-28T07:08:34.194Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/54/ec/bd798654b06fb42a92b57d1dc1b530084fa89ed442806fcd0a833a36f9b3/grpcio-1.83.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:55656318d5dd387077396dffb929171ca3966e24bfead9a6c5dba9f889062cb4", size = 7042942, upload-time = "2026-08-28T07:08:36.208Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/08/b0/c00f86614566dd0961825cf0f43d4f96a74371d9d95f952bcbc4b86d9a27/grpcio-1.83.1-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:9daf5acf4fc9d5f5627229969c2580a91e511779d76e4ccdeb9f4770f05d8bc2", size = 7576937, upload-time = "2026-08-28T07:08:38.041Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/b1/38/85eff43a5c89dc666a252b5c9f8e9ab03f89e11c95b6263d2933f08fdbe7/grpcio-1.83.1-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:7b94174cbca93316888f805efbeb08f1c020f7b7493d2d50cc4f6b64ebb7e8bd", size = 8608391, upload-time = "2026-08-28T07:08:40.092Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/35/4e/82835483e2f812494be865e7965c0d626cb9e71ab0d83a420d75aea4ad67/grpcio-1.83.1-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:65c5a7210911ffe0f67b1cdc5308f9854b6d1f1b345e3e49ab7cac1ba50fa346", size = 7980060, upload-time = "2026-08-28T07:08:42.434Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/b2/b7/68a98bef733fef704fbcfb3957c8dba67e3e38ca7a7fea851195bc97c648/grpcio-1.83.1-cp313-cp313-win32.whl", hash = "sha256:179368d9361854616ce6f397d4716e07480129652752fcbcfc5a7260455ad6f2", size = 4395226, upload-time = "2026-08-28T07:08:44.463Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/85/a0/df4de3b51d37ac8fb0320bb9668381ce2bd3b7aa990880bfc56a8a26f665/grpcio-1.83.1-cp313-cp313-win_amd64.whl", hash = "sha256:2e57af456385491a76e13c4aada8c8f43a8e47051e06ea97a9dbe2a49654e6db", size = 5160273, upload-time = "2026-08-28T07:08:46.216Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/42/9c/484d981d8b90c4e6abf3030bd2ed747e84d1eb192b3ec9cbb41e0b73e4bf/grpcio-1.83.1-cp314-cp314-linux_armv7l.whl", hash = "sha256:8b3c87ca908296bf125f841d3e1a2225a2b39aaa8ed7a57e7ccde465ee519bab", size = 6306089, upload-time = "2026-08-28T07:08:48.379Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/84/01/0afec1c92e4f292f74a44ecf75eabbf40903125b8c4df103c9868d6338da/grpcio-1.83.1-cp314-cp314-macosx_11_0_universal2.whl", hash = "sha256:c0f3f20c90e72a171917ae65706500b096a1c3eb5f162c3ce702a2e25635f132", size = 12170381, upload-time = "2026-08-28T07:08:50.653Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c7/5a/e9a2383804433a0a61d6d93777ad321c7f36ac1cfdaa4c6d1a7c9ac846b7/grpcio-1.83.1-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:81bbf35a46bf8cad2dfbb2eccc19c711befb58b288acb534bbcd0d74283202a6", size = 6883286, upload-time = "2026-08-28T07:08:53.654Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/63/e7/f8ca8f76994e14c70b9a0052e82f10de497a23db450c36379c9716ebfc4d/grpcio-1.83.1-cp314-cp314-manylinux2014_i686.manylinux_2_17_i686.whl", hash = "sha256:215cec07d11176507387bda4bf2751816e880f9bff8dc1ca524bfbb8ed8f2fad", size = 7624293, upload-time = "2026-08-28T07:08:55.709Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/bb/7a/4b672814b0cd0fe63bdd735379d88b165759f3144ab023ad8ec5fc4d53ac/grpcio-1.83.1-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:abce7d43ec29cd39230fa8339de1a07643b55adc412a454850fbd875349950ff", size = 7044346, upload-time = "2026-08-28T07:08:57.802Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/50/b8/d89fe60e4239ad51be333dd9cc703741d449a35064e51f8a0b5bfa755432/grpcio-1.83.1-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:e256f95a40e3b0183a98556fb7164d24b97eeb353123ccabfcba94712b35ee2a", size = 7584187, upload-time = "2026-08-28T07:08:59.867Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/dc/b2/b290d7402633d9166e4dd47e6f5f74a24ce10a8340b84455896ebc349f85/grpcio-1.83.1-cp314-cp314-musllinux_1_2_i686.whl", hash = "sha256:2110059146fb0ea216e1ffddb29377b5cc2fd412a5b0a92e102616bd5edf18c2", size = 8608730, upload-time = "2026-08-28T07:09:02.592Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/f5/44/fa89e44d1b5cf5b9fa71b2fd7abf506f182fd43917231a92fbf1ea326b02/grpcio-1.83.1-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:20d944d967843f8183f9f23d5916388362e5f8eeeae855bbe4354d906dc9f31b", size = 7983283, upload-time = "2026-08-28T07:09:05.087Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/ce/b8/9db73ed1f35ffa76124ac574bf296d06a359798dfd6b50d382f2b8a060a1/grpcio-1.83.1-cp314-cp314-win32.whl", hash = "sha256:623c87c6d4a1cb30d82c4e896f95477050f2e01b4a1f8cf91ff2b1abdf89c457", size = 4474327, upload-time = "2026-08-28T07:09:07.179Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/65/22/fc9a622d885a7a37ff972a12faaef443d74e47407181da70d0ab62ab41f0/grpcio-1.83.1-cp314-cp314-win_amd64.whl", hash = "sha256:47e6934ad38779271e2e7cc5f78a63a407cf3d98114c65c1fdbcd3f5a716f29b", size = 5302032, upload-time = "2026-08-28T07:09:09.285Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/31/8c/b6d9ea0bf02a6b47ba34c5f936da2921d76f5e40cbb411e9abb246b70d2d/grpcio-1.85.1-cp312-cp312-linux_armv7l.whl", hash = "sha256:1a10d337967ec2be049c6a2345320f6a59f71bf9f54febfd80e5a966cffaa945", size = 6797195, upload-time = "2026-10-30T15:59:35.364Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c6/ee/f60cfacd679fe811944be391c899955c3d9c7e07db922b47e535ddda550c/grpcio-1.85.1-cp312-cp312-macosx_11_0_universal2.whl", hash = "sha256:658a9d89c5736bf4aa3ef4ecbc79528e26d8e23c5e1c83417d2870a1a06063e5", size = 12633025, upload-time = "2026-10-30T15:59:37.66Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/f1/0d/5dbe225f0ceb208538dc8c16c5f52b0c402b91611f981604b5e280439dfb/grpcio-1.85.1-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:843aa281a48188621f50880496d35defed51298bcb66d5345d5f282fd3f87354", size = 7170616, upload-time = "2026-10-30T15:59:40.138Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/54/35/ce972a4e5bb721ba85f5c9e20a0029253ae0b2deb5276dafa3383e025133/grpcio-1.85.1-cp312-cp312-manylinux2014_i686.manylinux_2_17_i686.whl", hash = "sha256:e768556a2346d1d2921f511f3145e2462e4fe68095c31e4db407558bcd3f1d4f", size = 8180786, upload-time = "2026-10-30T15:59:42.7Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/00/8d/74a8649d2787dae0a661855cdf09a8e2238fa741689bb368ca1b4f6d5b6f/grpcio-1.85.1-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:a1a72d19c0ab84b4b73b6c47eeaade76d84b1973a51593ff1160a73df33d03d9", size = 7362744, upload-time = "2026-10-30T15:59:45.076Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/03/72/87ef13aba6bd2c5c6d4c5117238b17b1e3c1c1efa26c66cb377053124eb7/grpcio-1.85.1-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:0e07f477e1d1a05bdbe71d63add964c5457e7ab2e3f5fd32859639ed8ecb976e", size = 7929643, upload-time = "2026-10-30T15:59:47.294Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/09/f1/2e75b2906c9643e0be81a74bf23ae10c29661e0199c8f3a6e2c23707e882/grpcio-1.85.1-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:b2846c70ed58c8e149e8e5d867af40805a13b151d84157d8272952d711a77c5c", size = 9181161, upload-time = "2026-10-30T15:59:49.399Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c1/d9/6b9127e8fa3ef14a3ec199436bec6c1a54a0bb429ca261b1a2fb518938d1/grpcio-1.85.1-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:9998f03ac0dfed226eead6e93cee1b547d7a32e47e1915dee94eff0e113b167e", size = 8318829, upload-time = "2026-10-30T15:59:52.09Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/21/46/ff3374d33efee490a0e50e3c3fc59280b7f7fc2ed3ab1ee8c4e9873dc83d/grpcio-1.85.1-cp312-cp312-win32.whl", hash = "sha256:2670c03d154f6bec66a0fef97c607116761b032183187dfdfe229b5975820a4f", size = 4768056, upload-time = "2026-10-30T15:59:54.132Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/dd/48/4030a63540089d00a36cea15282623bcf084a5ea4c0ffc4685a42ef0f342/grpcio-1.85.1-cp312-cp312-win_amd64.whl", hash = "sha256:eaad7e6aa9ac3aded4f6bc86a18bf2cff3de356f972bf32a5558df9788085b85", size = 5607218, upload-time = "2026-10-30T15:59:56.721Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c1/05/2d40be7dbfd8e66e8e5675ec695fafacc69823dcd2ef5d387ad7431c7af7/grpcio-1.85.1-cp313-cp313-linux_armv7l.whl", hash = "sha256:e117b074d707d418ff411e0ad6fc86e97e83047b742488b41d7a5b7a62953cd3", size = 6801759, upload-time = "2026-10-30T15:59:58.834Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/b0/98/530af74d704dc8e79c79b26888af44ccbdd1827bfabc9cb405b3d4cc184e/grpcio-1.85.1-cp313-cp313-macosx_11_0_universal2.whl", hash = "sha256:6bb4bbb5cb46010687db552fd88852c405595814fb7d435b072124bd6b93f827", size = 12629341, upload-time = "2026-10-30T16:00:01.159Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/21/cb/bac12e6c7ab3b1c6b50816fdcbf7f97aec1bd0992cc0d193e332aff716a5/grpcio-1.85.1-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:0bde4264ca71aaf3bc56c587380c426b1c959d1db0ab0a3f632bc66515f9726f", size = 7174387, upload-time = "2026-10-30T16:00:04.847Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/90/0a/7770a652508a3a6c7d16fbb81db0f0b2be8a73a469af88a6cdfdc3d29cf2/grpcio-1.85.1-cp313-cp313-manylinux2014_i686.manylinux_2_17_i686.whl", hash = "sha256:7b931335c163510fb054c30007fe3556ef3bf354a1c37b5da403f2e52c6bbd95", size = 8185778, upload-time = "2026-10-30T16:00:07.009Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/bf/cb/52417fb272b7603d13ec8688e843dfd8df64584da1951ad954b9120d7c80/grpcio-1.85.1-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:de520b1555ae445cdc4f8f1cc7ccba12a19992bfafa7c292ebe7fe1fe5da6c53", size = 7364062, upload-time = "2026-10-30T16:00:09.777Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/ba/86/9329799fa9defe9327084b9ca7b9a9745e83e7174bb90f2bfb2f37063967/grpcio-1.85.1-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:2b20ba567ca818b8393fd4668878b5688cab32a46e8e7a4d1a58641fc0072df9", size = 7932775, upload-time = "2026-10-30T16:00:11.956Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/48/e4/826e0ae8f89a3d2ab3a15b91ee4ef486bdd7a09fd1ff72e12d01505341dc/grpcio-1.85.1-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:f0ebfbd8ba42497e0ff7229c8c5e166e07c2b348462c1481dbd90faa978ad8af", size = 9173461, upload-time = "2026-10-30T16:00:15.696Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/88/2d/d4baf37bf1a9ba8222dcb133c6aeb09119b183bd7b471061762a1198461c/grpcio-1.85.1-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:000999ea9bba80217b1625782d638e7a688790f6154e845e18826f7da859bfc7", size = 8311104, upload-time = "2026-10-30T16:00:18.533Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/e4/02/b07af232a583727fa84665d11165bbd7be6ddd31d84c2b8cb62a7b69062f/grpcio-1.85.1-cp313-cp313-win32.whl", hash = "sha256:b3722f4e01820f4d2422679a567fe33f31b6f14eba4352657a1078f4b4ed323e", size = 4769351, upload-time = "2026-10-30T16:00:21.165Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/f9/f0/d2448e860d884e8c89dd9135cd9373df064c10227d90973d822c2125428d/grpcio-1.85.1-cp313-cp313-win_amd64.whl", hash = "sha256:c17d61af28b322c48ab3881c685e5f6e7e367c56844cf589ee7707be9477b969", size = 5606831, upload-time = "2026-10-30T16:00:23.621Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/39/cc/da49c22b9c571b5315acc507e2ff6568e5ff9d4c99895285910283bf87e3/grpcio-1.85.1-cp314-cp314-linux_armv7l.whl", hash = "sha256:2a378eb60ea42996be5a8c7167302fb30d968fcfcf9edd7b3fa6c985906c4500", size = 6803626, upload-time = "2026-10-30T16:00:26.587Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/12/92/35bcee92bcfc2b0f66290a5dd6dd23ced7b9423fe269cf4495136e73d55b/grpcio-1.85.1-cp314-cp314-macosx_11_0_universal2.whl", hash = "sha256:90a7e0f26de39d15f5c741b8848bb2065c9ab7351c57d4fc973ff5cbda0cb9c7", size = 12640307, upload-time = "2026-10-30T16:00:28.969Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/f2/b5/469b69dadb2c413706f16e0c3e7a2749cc70abaab10d718873603bec29b2/grpcio-1.85.1-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:421925365f9a665830eded01b8053033abbc2fbabc9bb4e9c59c3b5b12acbab9", size = 7187308, upload-time = "2026-10-30T16:00:31.652Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/c4/df/2fcb1567d37e91ce26bddfca30f39fe6c39cbc5a2f4a210cfb1246ced1b2/grpcio-1.85.1-cp314-cp314-manylinux2014_i686.manylinux_2_17_i686.whl", hash = "sha256:8a921a98ed6142a29651b4a6f4c7b8e051d115f1e78c31655a9642dcf6356dd9", size = 8188002, upload-time = "2026-10-30T16:00:33.893Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/7b/b2/c67c1d8c7b70a094d404b28233458887bc1ca1319daa95d8952621216717/grpcio-1.85.1-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:e0e6d5829b50a2ffcfcd2dbf08d02ac0d6919051a2e97c2ee27c99bc9916a245", size = 7368045, upload-time = "2026-10-30T16:00:36.675Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/80/48/5cf6c704be4b059d508e8f6c981154223533595ba7a3ee531211ef8be62e/grpcio-1.85.1-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:58b5ebe509da292bec5a1913c1e4c14d842a33f6cb330a87d3713c5089dd0f55", size = 7941330, upload-time = "2026-10-30T16:00:39.173Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/67/96/5ef14edb784ea2053610753993601e98a76a18b541a8a74103dc390540ab/grpcio-1.85.1-cp314-cp314-musllinux_1_2_i686.whl", hash = "sha256:016982ebd21d2b48e955aa808e9db8d628708a35c6eba852cd0e70765826ab06", size = 9176909, upload-time = "2026-10-30T16:00:41.335Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/50/01/4264ae95364bdeede4c8a5f0d83df83a21b477935f9ab8c829ae5606e1d4/grpcio-1.85.1-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:0fa3d7b8b95e8a609967991c3b0a302b2f9d510fe417efadfa7c7d2d044a99ba", size = 8316226, upload-time = "2026-10-30T16:00:44.199Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/75/b8/79dace38eb4bb904751b804cfdc71609a3840f34084af7475169059dce20/grpcio-1.85.1-cp314-cp314-win32.whl", hash = "sha256:39b1965266b579f3758db20d74f9075b130d1b1edcf0464cda316e403a15da9b", size = 4853260, upload-time = "2026-10-30T16:00:47.098Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/48/c9/68a6bbd2450f08942c3056acd8995ac28af2b4eeb0574c0a8e59fa59b140/grpcio-1.85.1-cp314-cp314-win_amd64.whl", hash = "sha256:5f015600190124813032da0560ec950c13c257f77c1307abd77c393c0994f76f", size = 5758958, upload-time = "2026-10-30T16:00:49.145Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/1b/bd/1a2481b354ab4528eb8b3462937904c9206e2a54748f3f74a2576205ef3e/grpcio-1.85.1-cp315-cp315-linux_armv7l.whl", hash = "sha256:07bfef5df75875d8481d3403f864785e30096594162e8041c53a84fb11ee4f8e", size = 6803392, upload-time = "2026-10-30T16:00:51.782Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/40/45/1868c12c18058d778fcecee0e04c867891a82d983d2dd0de2639158aa960/grpcio-1.85.1-cp315-cp315-macosx_10_15_universal2.whl", hash = "sha256:e909e0f9145a555d3968dd2a448616b0d3cb58748b9e2053de3e7974b3e429bc", size = 12657793, upload-time = "2026-10-30T16:00:55.335Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/ed/af/c283032a42df5217913b98bd0113738b68dd94b91cea16b2209565fefe67/grpcio-1.85.1-cp315-cp315-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:1f3064e209167e5fcb75a72cbc18918c06027b92b29fa06eaff0126f9a2aab5a", size = 7209146, upload-time = "2026-10-30T16:00:58.279Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/45/64/8a72fd6c20c206cff07eaa49b2ca63bb15d7ed9b6bf7c653ea10ec578e4b/grpcio-1.85.1-cp315-cp315-manylinux2014_i686.manylinux_2_17_i686.whl", hash = "sha256:07675c635a2da0c772e58ac736a7fb10c7c7c1613157766441e6866ad97d25b4", size = 7511067, upload-time = "2026-10-30T16:01:00.806Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/5d/b8/32afa404288c7eea4c6034d031f1a07eff772a8cdbfc7751314382e7b724/grpcio-1.85.1-cp315-cp315-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:759f7df78954e3ac0ed4c87612eff9125021b9271be37be8c88167aa533e29ee", size = 7410227, upload-time = "2026-10-30T16:01:02.966Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/89/a4/1c51e2c2d0d9e4d37e8e8a7be412c5dfb3fd5c80ab100dd531fd81b44d43/grpcio-1.85.1-cp315-cp315-musllinux_1_2_aarch64.whl", hash = "sha256:7cd08bd5ad063ad9639dbebf95d3a6b8c8aa2c9d49049bc0e8f47e73ecf1c1a2", size = 7964886, upload-time = "2026-10-30T16:01:05.208Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/07/f3/e26f570129c162d8f15a02af6edb49e592ac1c88a63490cd3ec9142d8c67/grpcio-1.85.1-cp315-cp315-musllinux_1_2_i686.whl", hash = "sha256:2198269c8b69cb1e9d5d20628029245e40b7227d5f6fc6f298a420701d8fb652", size = 8504060, upload-time = "2026-10-30T16:01:07.82Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/16/e1/e334cf7442c01892ed813563b21b2a8ab5b042e34f33ad76cf64526d1de8/grpcio-1.85.1-cp315-cp315-musllinux_1_2_x86_64.whl", hash = "sha256:7bc5de50374416223bc35332aa8185567ec065f86190ff0ca6e13176ed39a3b4", size = 8346563, upload-time = "2026-10-30T16:01:10.394Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/66/bb/cf72913ce0baae1fed95445f1ba8ac309184ac16b4f20fb5f88219eff72c/grpcio-1.85.1-cp315-cp315-win32.whl", hash = "sha256:5740aedf1e6acde538d7b80a2507eb6ee0b8983c577a36890d27a0e2b62cc1eb", size = 4853404, upload-time = "2026-10-30T16:01:12.239Z" },
|
||||
{ url = "https://files.pythonhosted.org/packages/ea/b8/b7cff7b9e1ff7b6a8d36a19ce8b9c575963e71fcbb3878b276cff6748b05/grpcio-1.85.1-cp315-cp315-win_amd64.whl", hash = "sha256:b32f39c56d22d2e8722eececd4376074d94e01595a29f4f944ae0b6cea1caa70", size = 5758584, upload-time = "2026-10-30T16:01:14.325Z" },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "grpcio-health-checking"
|
||||
version = "1.85.1"
|
||||
source = { registry = "https://pypi.org/simple" }
|
||||
dependencies = [
|
||||
{ name = "grpcio" },
|
||||
{ name = "protobuf" },
|
||||
]
|
||||
sdist = { url = "https://files.pythonhosted.org/packages/9a/2c/ca51c42fbebecffa7129b347b95a2753b7c1a37db80803abef72e46390f8/grpcio_health_checking-1.85.1.tar.gz", hash = "sha256:93a5eeb29262165949b32fdaa86505f11018d1b8161382ee373a85530b11d281", size = 17986, upload-time = "2026-10-30T16:05:20.323Z" }
|
||||
wheels = [
|
||||
{ url = "https://files.pythonhosted.org/packages/0e/87/9be2c7b713907545cb88f5cd318107a58c77cdc146198f6175122d0aa931/grpcio_health_checking-1.85.1-py3-none-any.whl", hash = "sha256:05e1cb0cc69706f89e884d219c9b2b9da4f561c1c610e9987ee4492b9c826ad1", size = 20011, upload-time = "2026-10-30T16:03:53.049Z" },
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -499,6 +522,7 @@ source = { editable = "services/bff" }
|
||||
dependencies = [
|
||||
{ name = "fastapi" },
|
||||
{ name = "grpcio" },
|
||||
{ name = "httpx" },
|
||||
{ name = "jinja2" },
|
||||
{ name = "magnetflix-contracts" },
|
||||
{ name = "protobuf" },
|
||||
@@ -510,6 +534,7 @@ dependencies = [
|
||||
requires-dist = [
|
||||
{ name = "fastapi", specifier = ">=0.115.0" },
|
||||
{ name = "grpcio", specifier = ">=1.83.1" },
|
||||
{ name = "httpx", specifier = ">=0.28.0" },
|
||||
{ name = "jinja2", specifier = ">=3.1.4" },
|
||||
{ name = "magnetflix-contracts", editable = "services/contracts" },
|
||||
{ name = "protobuf", specifier = ">=7.36.1" },
|
||||
@@ -540,6 +565,7 @@ dependencies = [
|
||||
{ name = "aiosqlite" },
|
||||
{ name = "alembic" },
|
||||
{ name = "grpcio" },
|
||||
{ name = "grpcio-health-checking" },
|
||||
{ name = "httpx" },
|
||||
{ name = "magnetflix-contracts" },
|
||||
{ name = "protobuf" },
|
||||
@@ -553,6 +579,7 @@ requires-dist = [
|
||||
{ name = "aiosqlite", specifier = ">=0.20.0" },
|
||||
{ name = "alembic", specifier = ">=1.14.0" },
|
||||
{ name = "grpcio", specifier = ">=1.83.1" },
|
||||
{ name = "grpcio-health-checking", specifier = ">=1.83.1" },
|
||||
{ name = "httpx", specifier = ">=0.28.0" },
|
||||
{ name = "magnetflix-contracts", editable = "services/contracts" },
|
||||
{ name = "protobuf", specifier = ">=7.36.1" },
|
||||
|
||||
Reference in new issue
Block a user