2
0
Fork 0

fix duplicate output

This commit is contained in:
Luca Bilke 2023-06-26 21:56:42 +02:00
parent fc9896ad41
commit 882fdb22cb
1 changed files with 1 additions and 3 deletions

View File

@ -80,8 +80,6 @@ def download_track(
dl_path = f"{DL_PATH}/{track.album.name}/{track.name}.part" # type: ignore[reportOptionalMemberAccess] dl_path = f"{DL_PATH}/{track.album.name}/{track.name}.part" # type: ignore[reportOptionalMemberAccess]
dest_path = f"{DEST_PATH}/{track.album.name}/{track.name}" # type: ignore[reportOptionalMemberAccess] dest_path = f"{DEST_PATH}/{track.album.name}/{track.name}" # type: ignore[reportOptionalMemberAccess]
print(f"Downloading {track.name} - {track.artist.name}") # type: ignore[reportOptionalMemberAccess]
if os.path.exists(dest_path) and SKIP_DOWNLOADED: if os.path.exists(dest_path) and SKIP_DOWNLOADED:
print(dest_path + " exists!") print(dest_path + " exists!")
return True, "Skipping downloaded song" return True, "Skipping downloaded song"
@ -147,7 +145,7 @@ favorites = tidalapi.user.Favorites(session, user.id)
tracks = favorites.tracks() tracks = favorites.tracks()
for track in tracks: for track in tracks:
print(f"Downloading {track.album.name} by {track.artist}") print(f"Downloading {track.name} - {track.artist.name}") # type: ignore[reportOptionalMemberAccess]
check, msg = download_track(track) check, msg = download_track(track)
print(msg) print(msg)
time.sleep(3) time.sleep(3)