# Phase 1 verification report Verification date: 23 October 2026. **Current result: all 158 tests passed, with no failures, cancellations, or skips.** This includes the unresolved-link pause fix following the user's report of successive failed episodes. The protected library matched the reviewed baseline before and after the integrated run, and an independent check passed afterward. The initial Phase 1 release passed 141 tests. The work is available as uncommitted local changes on `phase-1-reliability`, based on upstream commit `211bfd174dd78eac36f3c74411ecaa72f56eec79`. The user installed the initial file update and reported successful episode downloads, followed by an unresolved-link failure that did not pause the queue. This revision fixes that local handling; it has not been checked against the user's live source response or production server. Production validation remains part of the rollout. ## Executed checks The integrated command was: ```sh npm test ``` | Suite | Passed | What it establishes | |---|---:|---| | Python downloader | 44 | CLI validation, preserved filename conventions and stream call order, stdin credentials, completion records, resolution/status distinctions, and series stop/counts | | Node-to-Python integration | 5 | Actual subprocess invocation, credential transport, output verification, failure handling, and resolver failures that pause without consuming the next episode | | Protected-library guard | 10 | Exact baseline acceptance and detection of changed, added, missing, linked, or mode-altered entries | | Runtime services | 25 | Configuration, shared database connection handling, log redaction, and constrained PM2 operations | | HTTP, WebSocket, and PM2 interface | 19 | Request limits, generic errors, worker-only log subscriptions, cleanup and selection races, bounded log delivery, and safe DOM updates | | Web validation and status | 19 | Both submission modes, safe filenames and ranges, Unicode validation, public-field/log redaction, pause-reason allowlisting, and resume cleanup | | Worker lifecycle | 36 | Strict success criteria, process/storage failures, safe log truncation, pause/history/release ordering, acknowledged attention writes, and concurrent pause gates | | **Total** | **158** | **114 Node tests and 44 Python tests** | The run used Node.js `v24.19.0` and Python `3.12.14` in the local workspace. This does not establish compatibility of the installed Python dependency stack on the intended Debian 13 host. Additional checks passed: ```sh node tools/check-protected-lib.js git diff --check git diff --exit-code 211bfd174dd78eac36f3c74411ecaa72f56eec79 -- scripts/lib scripts/requirements.txt ``` The protected check covers all seven original files, their SHA-256 hashes and executable bits, the exact directory structure, and unexpected entries. It found no modifications, additions, deletions, or symbolic links. The Python requirements file is unchanged. The Node lockfile retains all dependency versions; its only change adds the application's minimum Node engine metadata. ## Failure behavior covered by the tests Completion requires exit code 0, exactly one valid completed result, and a nonempty regular output file. Nonzero exits, missing or malformed results, duplicate results, stderr-only results, signal termination, and invalid artifacts cannot become completed jobs. A nonempty file check is not full video-integrity validation. Ordinary source, network, and validation failures are written to failed history without pausing unrelated jobs. Verified HTTP 404 remains an ordinary source failure. Exact protected-library missing-marker errors now produce `resolution`; these and verified HTTP 401/403 access failures set the existing global pause before failed-attempt history and release of the affected claim. They retain the full request and credential in the queue. Post-claim and final launch checks prevent newly paused work from starting; failures reading pause state leave uncertain claims held. Transfers already admitted may finish. Missing worker infrastructure or unavailable output storage retains the request and stops the worker. A handled shutdown releases only its own claim after the child has terminated; a live-child error cannot release it early. History writes precede queue removal. If persistence fails, the worker stops with the processing claim held. These tests verify the ordering under simulated database results; they do not turn the legacy multi-collection sequence into an atomic transaction. Submitted cookie values are sent through stdin by workers. Complete log lines are redacted before bounded accumulation, including values split across chunks. Status queries may read a token internally to sanitize older logs, but the returned DTO contains only allowlisted public fields. Neither raw tokens nor PM2 environment objects are included in those tested public responses. ## Test isolation and remaining deployment checks The suites use synthetic jobs, temporary output files, fake database/PM2/process interfaces, and a fake browser DOM. The subprocess integration suite runs actual Node-to-Python launches against copied entrypoints and a synthetic stream module. Express body-limit tests exercise the actual parsers with in-memory HTTP objects. No authenticated media download, live MongoDB connection, PM2 daemon operation, or production-server change was performed. Before production rollout, verify the target account's effective `plex` membership and write access to `/mnt/media/WIP`, its actual interpreter and existing dependencies, the MongoDB configuration, and PM2 startup under the same download account. Exercise the real stream on staging before accepting transport compatibility. Replace the worker and Python entrypoints together after existing children have stopped; the new worker requires the new result and stdin interfaces. The legacy queue still has no expiring ownership or automatic worker-loss recovery. Forced kills and interrupted persistence can require reconciliation. The protected transfer still writes directly to its target and cannot resume a partial file. No bandwidth cap has been implemented or measured in this phase. These limits are tracked in the [rollout roadmap](rollout-roadmap.md) and [Debian deployment assessment](debian-13-deployment.md).