From ca5ab41677e2f518a77cc425e489d62543034128 Mon Sep 17 00:00:00 2001 From: William Bell <62452284+Ugric@users.noreply.github.com> Date: Sat, 27 Dec 2025 00:14:03 +0000 Subject: [PATCH] change to not load from the internet rn --- app.py | 21 +++++++++++++++++---- jelly.py | 53 ++++++++++++++++++++++++++++------------------------- 2 files changed, 45 insertions(+), 29 deletions(-) diff --git a/app.py b/app.py index 6d1cbdf..f03b852 100644 --- a/app.py +++ b/app.py @@ -78,12 +78,25 @@ print("add queue") player.add_to_queue( Song( - "/mnt/HDD/Downloads/72 Pantera.wav", - "Bullseye", + "bruhh", + "music/pink floyd/dark side of the moon/06 Money.flac", + "Money", 1, - "KDrew", + "The Dark Side Of The Moon", "", - "KDrew", + "Pink Floyd", + ) +) + +player.add_to_queue( + Song( + "bruhh", + "music/pink floyd/dark side of the moon/07 Us and Them.flac", + "Us and Them", + 1, + "The Dark Side Of The Moon", + "", + "Pink Floyd", ) ) diff --git a/jelly.py b/jelly.py index 7ef87c1..8c89673 100644 --- a/jelly.py +++ b/jelly.py @@ -6,36 +6,39 @@ import json load_dotenv() -album_covers = {} +# album_covers = {} -client = JellyfinClient() -client.config.app("UgPod", "0.0.1", "UgPod prototype", "UgPod_prototype_1") -client.config.data["auth.ssl"] = True +# client = JellyfinClient() +# client.config.app("UgPod", "0.0.1", "UgPod prototype", "UgPod_prototype_1") +# client.config.data["auth.ssl"] = True -try: - with open("data/auth.json", "r") as f: - credentials = json.load(f) +# try: +# with open("data/auth.json", "r") as f: +# credentials = json.load(f) - client.authenticate(credentials, discover=False) +# client.authenticate(credentials, discover=False) - # 🔴 THIS IS THE MISSING STEP - server = credentials["Servers"][0] - client.config.data["auth.server"] = server["Id"] - client.config.data["auth.servers"] = credentials["Servers"] +# # 🔴 THIS IS THE MISSING STEP +# server = credentials["Servers"][0] +# client.config.data["auth.server"] = server["Id"] +# client.config.data["auth.servers"] = credentials["Servers"] - client.start() +# client.start() - server = credentials["Servers"][0] +# server = credentials["Servers"][0] - assert server["Address"].startswith("http") - print("Server address:", server["Address"]) - print("Server ID:", server["Id"]) -except: - print("authenticating") - client.auth.connect_to_address(os.getenv("host")) - client.auth.login(os.getenv("URL"), os.getenv("username"), os.getenv("password")) +# assert server["Address"].startswith("http") +# print("Server address:", server["Address"]) +# print("Server ID:", server["Id"]) +# except: +# print("authenticating") +# client.auth.connect_to_address(os.getenv("host")) +# client.auth.login(os.getenv("URL"), os.getenv("username"), os.getenv("password")) - credentials = client.auth.credentials.get_credentials() -# with open("data/auth.json", 'w') as f: -# json.dump(credentials, f) -server = credentials["Servers"][0] \ No newline at end of file +# credentials = client.auth.credentials.get_credentials() +# # with open("data/auth.json", 'w') as f: +# # json.dump(credentials, f) +# server = credentials["Servers"][0] + +client = None +server = None \ No newline at end of file