mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-08 17:06:15 -08:00
* fix(tmdb): restore trailers in packaged builds, fall back to original language for missing text Two production-only gaps reported against the packaged 0.22 build: 1. Trailers showed YouTube "Error 153 — Video player configuration error". YouTube requires a Referer on /embed requests; the packaged app loads the renderer from file://, which never sends one (dev works because the origin is localhost). The Electron main process now injects the project site as Referer for YouTube embed hosts when the header is absent (request-header-overrides.service.ts, registered at startup via registerStaticHeaderShims). Existing Referers are never overwritten, other hosts untouched. 2. Descriptions vanished for content whose original language differs from the app language: TMDB does not fall back on missing translations, so a Russian-only series has empty overviews in en-US. When the app-language payload carries no text, the enrichment refetches once in the content's original_language and fills ONLY the missing text fields (tmdb-language-fallback.ts): details overview, season overview and per-episode names/overviews. Genres, credits and artwork stay in the app language; both language rows share the cache. Tests: 3 new shim cases in request-header-overrides.service.spec.ts, new tmdb-language-fallback.spec.ts (9 cases). Docs updated (tmdb-metadata-enrichment.md). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> * fix(tmdb): address PR review — best-effort fallback fetch, /embed/ scope, names-only trigger - A failing original-language fallback fetch no longer costs the already-fetched primary details payload (Codex P2) — it is wrapped best-effort and the primary payload is returned on error. - The YouTube Referer shim now scopes to /embed/ paths, so regular www.youtube.com requests keep their real (missing) Referer (greptile). - seasonNeedsTextFallback also triggers when episode overviews exist but ALL episode names are empty (partially translated seasons; greptile). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> --------- Co-authored-by: Claude Fable 5 <noreply@anthropic.com>