yaronzz / Tidal-Media-Downloader

Download 'TIDAL' Music On Windows/Linux/MacOs (PYTHON/C#)
http://doc.yaronzz.com/post/tidal_dl_installation/
Apache License 2.0
3.46k stars 477 forks source link

[BUG]: Metadata of Files has Contributing Artists in 'Artist' Section #1187

Closed Reasonable-Grape2698 closed 1 month ago

Reasonable-Grape2698 commented 2 months ago

Which tool

tidal-dl

Version

Latest

Platform

Linux, assume applies to all OS

Describe the bug

Metadata of Files has Contributing Artists in Artist Section too

Causes lots of issues with media scanners, ie plex creates Artists for EVERY single song with a contributing artist.

Relevant log output

No response

Add screenshots

image

Reasonable-Grape2698 commented 2 months ago

This may be included in the pulled file and not a tidal-dl issue

Reasonable-Grape2698 commented 1 month ago

Why was this closed?

Reasonable-Grape2698 commented 1 month ago

It's an easy fix

obj.composer = __parseContributors__('Composer', contributors) is correct (this works off other code that parses all contributors and maps to 'contributing artists' in meta data

obj.albumartist = list(map(lambda artist: artist.name, album.artists)) is incorrect. It should only be obj.albumartist = artist.name. This maps to Album Artist in meta data, which is what plex (and many others) use for sorting.

https://github.com/yaronzz/Tidal-Media-Downloader/blob/master/TIDALDL-PY/tidal_dl/download.py

Reasonable-Grape2698 commented 1 month ago

If someone wants to fork and make a fixed compile...

Reasonable-Grape2698 commented 1 month ago

This impacts plex, emby and Jellyfin as they all use 'artist' to sort which artist folder it goes into. You end up with thousands of folders due to this error. Example:

image

Reasonable-Grape2698 commented 1 month ago

It already correctly maps the other data to Contributing Artists, it doesn't need to be in Album Artist.

Reasonable-Grape2698 commented 1 month ago

I got it working and tested it in FROM Python:3.11 docker, worked as intended.

Reasonable-Grape2698 commented 1 month ago

May have actually fixed it by using:

{"albumFolderFormat": "{AlbumArtistName}/{AlbumTitle} {AudioQuality}", "apiKeyIndex": 4, "audioQuality": "HiFi", "checkExist": false, "downloadDelay": false, "downloadPath": "/downloads", "includeEP": true, "language": "0", "lyricFile": true, "multiThread": true, "playlistFolderFormat": "Playlist/{PlaylistName} {AudioQuality} ", "saveAlbumInfo": false, "saveCovers": true, "showProgress": true, "showTrackInfo": true, "trackFileFormat": "{ArtistName} - {TrackTitle}", "usePlaylistFolder": true, "videoFileFormat": "{VideoNumber} - {ArtistName} - {VideoTitle}{ExplicitFlag}", "videoQuality": "P1080"}r

I was accidentally using [Artistsname} for track title, which somehow didn't impact track title but impacted metadata?

image

`

Reasonable-Grape2698 commented 1 month ago

turns out metadata copies file names. If file names are wrong, meta data is too. Can close.

Reasonable-Grape2698 commented 1 month ago

Nevermind, still happens. I assume it is https://github.com/yaronzz/Tidal-Media-Downloader/blob/master/TIDALDL-PY/tidal_dl/download.py metadata section using a list instead of artist.name

Reasonable-Grape2698 commented 1 month ago

Fixed it DIY https://github.com/Reasonable-Grape2698/Tidal-DL_Plex-Friendly/

The issue we can't fix this easily is due to AIGPY, it treats everything as a list. You're essentially creating a list with one item to get around this currently. Created a pull request with the fix: https://github.com/AIGMix/AIGPY/pull/7

Once fixed simply using track.artist.name should work and album.artists.name. AIGPY will still determine if it's a list and do all the joining for us.