cleanup
parent
88a7526721
commit
827ace2e97
|
|
@ -19,6 +19,8 @@ def logger(message: str, log_type=0):
|
|||
output = f"[ERROR]: {output}"
|
||||
elif log_type == 3 and (debug and debug_level == "debug"):
|
||||
output = f"[DEBUG]: {output}"
|
||||
elif log_type == 4:
|
||||
output = f"[WARNING]: {output}"
|
||||
else:
|
||||
output = None
|
||||
|
||||
|
|
@ -101,7 +103,7 @@ def generate_library_guids_dict(user_list: dict):
|
|||
else:
|
||||
show_output_dict[provider_key.lower()].append(provider_value.lower())
|
||||
except:
|
||||
pass
|
||||
logger(f"Generating show_output_dict failed, skipping", 1)
|
||||
|
||||
try:
|
||||
for show in user_list:
|
||||
|
|
@ -116,7 +118,7 @@ def generate_library_guids_dict(user_list: dict):
|
|||
else:
|
||||
episode_output_dict[episode_key.lower()].append(episode_value.lower())
|
||||
except:
|
||||
pass
|
||||
logger(f"Generating episode_output_dict failed, skipping", 1)
|
||||
|
||||
try:
|
||||
for movie in user_list:
|
||||
|
|
@ -129,7 +131,7 @@ def generate_library_guids_dict(user_list: dict):
|
|||
else:
|
||||
movies_output_dict[movie_key.lower()].append(movie_value.lower())
|
||||
except:
|
||||
pass
|
||||
logger(f"Generating movies_output_dict failed, skipping", 1)
|
||||
|
||||
return show_output_dict, episode_output_dict, movies_output_dict
|
||||
|
||||
|
|
|
|||
|
|
@ -396,9 +396,9 @@ def main_loop():
|
|||
|
||||
logger("Creating watched lists", 1)
|
||||
server_1_watched = server_1_connection.get_watched(server_1_users, blacklist_library, whitelist_library, blacklist_library_type, whitelist_library_type, library_mapping)
|
||||
logger("Finished creating watched list server 1", 0)
|
||||
logger("Finished creating watched list server 1", 1)
|
||||
server_2_watched = asyncio.run(server_2_connection.get_watched(server_2_users, blacklist_library, whitelist_library, blacklist_library_type, whitelist_library_type, library_mapping))
|
||||
logger("Finished creating watched list server 2", 0)
|
||||
logger("Finished creating watched list server 2", 1)
|
||||
logger(f"Server 1 watched: {server_1_watched}", 3)
|
||||
logger(f"Server 2 watched: {server_2_watched}", 3)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue