sentriz / gonic

music streaming server / free-software subsonic server API implementation
ircs://irc.libera.chat/#gonic
GNU General Public License v3.0
1.5k stars 105 forks source link

Support for Artists tag (Picard) #406

Closed TypicalFence closed 8 months ago

TypicalFence commented 8 months ago

gonic version: v0.16.0

if from docker, docker tag: sentriz/gonic:nightly

I struggled getting multiple artists to work, my files were tagged by beets but beets seems to follow the default tag format of Picard, which can be found here: https://picard-docs.musicbrainz.org/en/variables/tags_basic.html

to quote the docs:

artist
Track Artist Name(s). (string)

artists
Track Artist Name(s). (multi-value) (since Picard 1.3)

Retaining the value of the artist field would also be nice as it appears to contain the artists in a formatted way, example (eyeD3 output).

ID3 v2.4:
title: UN1TE
artist: Massive New Krew ft. YUC'e

UserTextFrame: [Description: ARTISTS]
Massive New KrewYUC'e

OpenSubsonic appears to have a displayArtist field that would fit that.

The AlbumArtists field is also a thing that might make sense should this feature be considered.

Also the type mapping per file format: https://picard-docs.musicbrainz.org/en/appendices/tag_mapping.html#artists

sentriz commented 8 months ago

are you asking about getting the multi valued tags scanned into gonic, or returning the display artist / artist credit tags over the api?

TypicalFence commented 8 months ago

I am asking about the multi value tags under Artists & Albumartists being scanned into gonic, which doesn't seem to be the case at the moment.

But I was overthinking the whole thing because I started to wondering if it should be merged with the content of Artist or overwrite it and the fact that potentially some meaning could get lost from the single value string.

Due to that I found out about display artist and wanted to note that probably the single value should be used based on what beets is tagging opposed to for instance concatenating the content of the artists fields.

sentriz commented 8 months ago

have you set the multi valued settings like GONIC_MULTI_VALUE_ARTIST, GONIC_MULTI_VALUE_ALBUM_ARTIST? they need to be set first, check the readme. in your case they need the value multi

also, when setting these settings for the first time with an existing library, a "slow" scan must be done from the admin interface


as for tags, yes the picard settings should work. for example this release https://musicbrainz.org/release/d7e1ff31-5bc1-4d8a-a218-5861eaf4a59a

if picard sets the albumartist and albumartists tags, you would see for example in a gonic album response

{
  "id": "al-22",
  "name": "Liumin",
  "year": 2010,

  // compatibility
  "artistId": "ar-18",
  "artist": "DeepChord",

  // from picard `albumartists` tag
  "artists": [
    { "id": "ar-18", "name": "DeepChord" },
    { "id": "ar-19", "name": "Echospace" }
  ],

  // from picard `albumartist` tag
  "displayArtist": "DeepChord Presents Echospace",

  "genre": "electronic",
  "genres": [
    { "name": "electronic" },
    { "name": "techno" }
  ],
}

as for the displayAlbumArtist displayArtist fields missing. they are just cosmetic but i added them now

sentriz commented 8 months ago

does that make sense?

TypicalFence commented 8 months ago

I just ran another full scan and it appears to pick it up now.