AgPerry's picture
Add files using upload-large-folder tool
a1c39ac verified
Raw History Blame Contribute Delete
780 Bytes
"""One declarative service source for preferences, tabs, and recommendations."""
from __future__ import annotations
STREAMING_SERVICES = (
{"id": "prime-video", "label": "Prime Video"},
{"id": "apple-tv-plus", "label": "Apple TV+"},
{"id": "netflix", "label": "Netflix"},
{"id": "disney-plus", "label": "Disney+"},
{"id": "hulu", "label": "Hulu"},
)
def services_for_title(title_id: str) -> tuple[str, ...]:
"""Return stable local availability labels without claiming live access."""
index = sum(title_id.encode("utf-8")) % len(STREAMING_SERVICES)
result = [STREAMING_SERVICES[index]["id"]]
if int(title_id[-1], 16) % 3 == 0:
result.append(STREAMING_SERVICES[(index + 2) % len(STREAMING_SERVICES)]["id"])
return tuple(result)