Screenshots: the cast in the details pane
The fake Trakt answers the id lookup and people requests with invented names. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@@ -158,7 +158,23 @@ UPCOMING = {"id": 0, "title": catalog.UPCOMING[1], "year": catalog.UPCOMING[2],
|
|||||||
"tmdbId": 9001, "titleSlug": "the-long-orbit-return", "genres": ["Science Fiction"], "studio": "Halcyon Pictures", "runtime": 0,
|
"tmdbId": 9001, "titleSlug": "the-long-orbit-return", "genres": ["Science Fiction"], "studio": "Halcyon Pictures", "runtime": 0,
|
||||||
"images": [{"coverType": "poster", "remoteUrl": "http://127.0.0.1:%d/remote/m9001.jpg" % RADARR}], "status": "announced", "ratings": {}}
|
"images": [{"coverType": "poster", "remoteUrl": "http://127.0.0.1:%d/remote/m9001.jpg" % RADARR}], "status": "announced", "ratings": {}}
|
||||||
|
|
||||||
|
FIRST = ["Maren", "Theo", "Ilse", "Jonah", "Priya", "Oskar", "Lena", "Rafael", "Wren", "Tobias", "Noor", "Elias", "Saoirse", "Kenji", "Ada", "Milo"]
|
||||||
|
LAST = ["Halvorsen", "Achebe", "Lindqvist", "Moreau", "Okafor", "Brandt", "Castellano", "Yamada", "Petrov", "Quinn", "Ferreira", "Novak"]
|
||||||
|
ROLES = ["Captain Ilsa Rhee", "Dr. Amos Kell", "Navigator Juno", "The Engineer", "Mara Voss", "Commander Teague", "Pilot Sev", "Young Ilsa", "Radio Operator", "Station Chief"]
|
||||||
|
|
||||||
|
def people(seed, show):
|
||||||
|
def name(i): return FIRST[(seed * 3 + i * 5) % len(FIRST)] + " " + LAST[(seed * 7 + i * 3) % len(LAST)]
|
||||||
|
cast = [{"character": ROLES[(seed + i) % len(ROLES)], "characters": [ROLES[(seed + i) % len(ROLES)]], "person": {"name": name(i), "ids": {"trakt": i}}} for i in range(9)]
|
||||||
|
lead = {"job": "Creator" if show else "Director", "jobs": ["Creator" if show else "Director"], "person": {"name": name(20), "ids": {"trakt": 99}}}
|
||||||
|
return {"cast": cast, "crew": {("created by" if show else "directing"): [lead]}}
|
||||||
|
|
||||||
def trakt(path):
|
def trakt(path):
|
||||||
|
parts = path.strip("/").split("/")
|
||||||
|
if parts[0] == "search": # /search/tmdb/1013?type=movie or /search/tvdb/2001?type=show
|
||||||
|
id = int(parts[2]); key = "movie" if parts[1] == "tmdb" else "show"
|
||||||
|
return [{"type": key, "score": 1000, key: {"title": "x", "year": 2020, "ids": {"trakt": id, "slug": "x"}}}]
|
||||||
|
if len(parts) == 3 and parts[2] == "people":
|
||||||
|
return people(int(parts[1]), parts[0] == "shows")
|
||||||
def movie(id, title, year): return {"title": title, "year": year, "ids": {"trakt": id, "slug": "x", "tmdb": 1000 + id if id < 9000 else id}}
|
def movie(id, title, year): return {"title": title, "year": year, "ids": {"trakt": id, "slug": "x", "tmdb": 1000 + id if id < 9000 else id}}
|
||||||
def show(id): s = next(x for x in catalog.SERIES if x[0] == id); return {"title": s[1], "year": s[2], "ids": {"trakt": id, "slug": "x", "tvdb": 2000 + id}}
|
def show(id): s = next(x for x in catalog.SERIES if x[0] == id); return {"title": s[1], "year": s[2], "ids": {"trakt": id, "slug": "x", "tvdb": 2000 + id}}
|
||||||
by = {m[0]: m for m in catalog.MOVIES}
|
by = {m[0]: m for m in catalog.MOVIES}
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 91 KiB After Width: | Height: | Size: 112 KiB |
|
Before Width: | Height: | Size: 69 KiB After Width: | Height: | Size: 91 KiB |
|
Before Width: | Height: | Size: 91 KiB After Width: | Height: | Size: 112 KiB |
|
Before Width: | Height: | Size: 123 KiB After Width: | Height: | Size: 140 KiB |
|
Before Width: | Height: | Size: 129 KiB After Width: | Height: | Size: 148 KiB |
|
Before Width: | Height: | Size: 66 KiB After Width: | Height: | Size: 88 KiB |