Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Beatport plugin does not apply tags to file #3387

Closed
temrix opened this issue Oct 1, 2019 · 16 comments · Fixed by #3389
Closed

Beatport plugin does not apply tags to file #3387

temrix opened this issue Oct 1, 2019 · 16 comments · Fixed by #3389
Labels
bug bugs that are confirmed and actionable

Comments

@temrix
Copy link
Contributor

temrix commented Oct 1, 2019

Problem

Continuation of issue #2080
The beatport plugin fetches genres, bpm and musical_key among others. These should be shown when querying using beat ls ... and written into the tags of the music files. However, genre is not applied, bpm is correctly applied and written to tags and musical_key is applied but not written to tags.

During writing this bug report I found that I did not pass the attribute self.genre to the hook. This explains why genre was not applied but not why musical_key is not written to tags.

I will issue a pull request resolving the first bug but I don't know why `musical_key_ is not written to the tags.

Reproducing

Deleting with a tag editor genre and bpm beforehand.

First, we import the album in timid (-t) mode:

$ beet -vv import ~/music -t

Output:

user configuration: /home/temrix/.config/beets/config.yaml
data directory: /home/temrix/.config/beets
plugin paths: 
Sending event: pluginload
library database: /home/temrix/Dokumente/musiclibrary.db
library directory: /home/temrix/music
Sending event: library_opened
Sending event: import_begin
Sending event: import_task_created
Sending event: import_task_start
Looking up: /home/temrix/music/Supersillyus - Charade - 2016 - MP3
Tagging Supersillyus - Charade
No album ID found.
Search terms: Supersillyus - Charade
Album might be VA: False
Searching for MusicBrainz releases with: {'release': 'charade', 'artist': 'supersillyus', 'tracks': '6'}
Requesting MusicBrainz release 311af76c-3c77-4603-8b64-b4de17ee6c3a
primary MB release type: album
Sending event: albuminfo_received
Candidate: Supersillyus - Charade (311af76c-3c77-4603-8b64-b4de17ee6c3a)
Computing track assignment...
...done.
Success. Distance: 0.00
Requesting MusicBrainz release 8613ba08-2700-48bc-8a2c-349a81e37a31
primary MB release type: album
Sending event: albuminfo_received
Candidate: Supersillyus - Tesselations (8613ba08-2700-48bc-8a2c-349a81e37a31)
Computing track assignment...
...done.
Success. Distance: 0.70
Requesting MusicBrainz release 8ff531fd-198c-4188-9a60-0eff01591153
primary MB release type: album
Sending event: albuminfo_received
Candidate: Supersillyus - Interabang‽ (8ff531fd-198c-4188-9a60-0eff01591153)
Computing track assignment...
...done.
Success. Distance: 0.58
Requesting MusicBrainz release a39d17fc-78c2-3daf-bc8e-c5408580423d
primary MB release type: album
secondary MB release type(s): soundtrack
Sending event: albuminfo_received
Candidate: Henry Mancini - Charade (a39d17fc-78c2-3daf-bc8e-c5408580423d)
Computing track assignment...
...done.
Success. Distance: 0.72
Requesting MusicBrainz release 8770c677-9199-4d97-867b-1a28804a3728
primary MB release type: single
Sending event: albuminfo_received
Candidate: Skids - Charade (8770c677-9199-4d97-867b-1a28804a3728)
Computing track assignment...
...done.
Success. Distance: 0.60
Sending event: albuminfo_received
Candidate: Supersillyus - Charade (1742984)
Computing track assignment...
...done.
Success. Distance: 0.12
Evaluating 6 candidates.

/home/temrix/music/Supersillyus - Charade - 2016 - MP3 (6 items)
Sending event: before_choose_candidate
Tagging:
    Supersillyus - Charade
URL:
    https://musicbrainz.org/release/311af76c-3c77-4603-8b64-b4de17ee6c3a
(Similarity: 100.0%) (Digital Media, 2016, XW, Gravitas Recordings, GR089)
 * Mirage a Trois ->
   Mirage à Trois
 * A List of Instructions for When I'm Human ->
   A List of Instructions for When I’m Human
[A]pply, More candidates, Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? m
Finding tags for album "Supersillyus - Charade".
Candidates:
1. Supersillyus - Charade (100.0%) (Digital Media, 2016, XW, Gravitas Recordings, GR089)
2. Supersillyus - Charade (88.1%) (tracks, source) (Beatport, Digital, 2016, Gravitas Recordings, GR089)
3. Supersillyus - Interabang‽ (41.8%) (tracks, album, unmatched tracks, ...) (Digital Media, 2013, US)
4. Skids - Charade (39.9%) (tracks, unmatched tracks, artist, ...) (7" Vinyl, 1979, GB, Virgin, VS 288)
5. Supersillyus - Tesselations (29.7%) (tracks, missing tracks, album, ...) (Digital Media, 2011, US, Base Trip Records, [none])
6. Henry Mancini - Charade (28.0%) (tracks, missing tracks, artist, ...) (CD, 1998, ES, RCA Victor)
# selection (default 1), Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? 2
Tagging:
    Supersillyus - Charade
URL:
    https://beatport.com/release/charade/1742984
(Similarity: 88.1%) (tracks, source) (Beatport, Digital, 2016, Gravitas Recordings, GR089)
 * Mirage a Trois ->
   Mirage a Trois (source)
 * Aeon Bahamut ->
   Aeon Bahamut (source)
 * Trancendental Medication ->
   Trancendental Medication (source)
 * A List of Instructions for When I'm Human ->
   A List of Instructions for When I'm Human (source)
 * The Great Shenanigan ->
   The Great Shenanigan (source)
 * Charade ->
   Charade (source)
Apply, More candidates, Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? a
Sending event: import_task_choice
Sending event: import_task_apply
0 of 6 items replaced
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: item_copied
Sending event: database_change
Sending event: database_change
Sending event: write
Sending event: after_write
Sending event: item_copied
Sending event: database_change
Sending event: database_change
Sending event: write
Sending event: after_write
Sending event: item_copied
Sending event: database_change
Sending event: database_change
Sending event: write
Sending event: after_write
Sending event: item_copied
Sending event: database_change
Sending event: database_change
Sending event: write
Sending event: after_write
Sending event: item_copied
Sending event: database_change
Sending event: database_change
Sending event: write
Sending event: after_write
Sending event: item_copied
Sending event: database_change
Sending event: database_change
Sending event: write
Sending event: after_write
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: import_task_files
Sending event: album_imported
Sending event: import
Sending event: cli_exit

After that:

$ beet -vv ls -f '$title - $genre - $bpm - $musical_key'
user configuration: /home/temrix/.config/beets/config.yaml
data directory: /home/temrix/.config/beets
plugin paths: 
Sending event: pluginload
library database: /home/temrix/Dokumente/musiclibrary.db
library directory: /home/temrix/music
Sending event: library_opened
Mirage a Trois - Downtempo - 90 - Gmin
Aeon Bahamut - Downtempo - 100 - Gmaj
Trancendental Medication - Downtempo - 141 - Fmaj
A List of Instructions for When I'm Human - Downtempo - 88 - Amin
The Great Shenanigan - Downtempo - 123 - E♭maj
Charade - Downtempo - 123 - Amaj
Sending event: cli_exit

genre is left unaltered but should be changed to Glitch Hop, bpm is correct and written to tags, musical_key is correct and not written to tags.

We run this:

$ beet -vv ls -af '$album - $genre'

Album genre has not changed.

user configuration: /home/temrix/.config/beets/config.yaml
data directory: /home/temrix/.config/beets
plugin paths: 
Sending event: pluginload
library database: /home/temrix/Dokumente/musiclibrary.db
library directory: /home/temrix/music
Sending event: library_opened
Charade - Downtempo
Sending event: cli_exit

Here's a link to the music files that trigger the bug (if relevant):
Simple free download link to files, Creative Commons licensed, and also available in the Beatport catalogue: https://ektoplazm.com/free-music/supersillyus-charade

Setup

  • OS: Debian
  • Python version: 3.7.3
  • beets version: 1.5.0
  • Turning off plugins made problem go away (yes/no): yes
  • Tagging program used to read tags: Musicbrainz Picard

My configuration (output of beet config) is:

directory: ~/music
library: ~/Dokumente/musiclibrary.db

import:
    copy: yes
    write: yes

ui:
    color: yes

plugins: beatport
beatport:
    apikey: REDACTED
    apisecret: REDACTED
    tokenfile: beatport_token.json
    source_weight: 0.5
@sampsyo sampsyo added the bug bugs that are confirmed and actionable label Oct 1, 2019
@sampsyo
Copy link
Member

sampsyo commented Oct 1, 2019

Thanks for the writeup!

musical_key is not written to the files because it's a flexible attribute that was invented just for the Beatport plugin, so it doesn't have a tag mapping. In retrospect, the right field name to have used is initial_key, which you'll find (if you grep around in the codebase) is a pre-existing field used by multiple other plugins—namely, keyfinder and acousticbrainz. Let's switch to using that instead!

@temrix
Copy link
Contributor Author

temrix commented Oct 6, 2019

@wualex This is now merged. You can update to the development version by using pip install git+https://github.com/beetbox/beets.git again. Maybe you have to uninstall the old version by pip uninstall beets.

@wualex
Copy link

wualex commented Oct 11, 2019

@temrix unfortunately the problem persists...

After uninstall & install from git i did the following:

# beet import -s /mnt/d/test/

/mnt/d/test/Alex Niggemann - Bwana (Original Mix).flac
Correcting track tags from:
    Alex Niggemann - Bwana (Original Mix)
To:   Alex Niggemann - Bwana
URL:  https://beatport.com/track/bwana-original-mix/11381810
(Similarity: 93.8%) (title) (Beatport)
[A]pply, More candidates, Skip, Use as-is, Enter search, enter Id, aBort? A
/mnt/d/test/Avidus - Psalm 23.flac
Tagging track: Avidus - Psalm 23
URL: https://beatport.com/track/psalm-23-original-mix/11717455
(Similarity: 100.0%) (Beatport)
/mnt/d/test/Davi - The Gates Of Babylon (Original Mix).flac
Correcting track tags from:
    Davi - The Gates Of Babylon (Original Mix)To: DAVI - The Gates Of Babylon
URL: https://beatport.com/track/the-gates-of-babylon-original-mix/6061936
(Similarity: 96.5%) (title) (Beatport)
/mnt/d/test/Kellerkind - Shakti Pan (feat. Sven).flac
Correcting track tags from:
    Kellerkind Sven - Shakti Pan (feat. Sven)
To: Kellerkind - Shakti Pan feat. Sven
URL: https://beatport.com/track/shakti-pan-feat-sven-original-mix/8712463
(Similarity: 94.3%) (artist) (Beatport)
[A]pply, More candidates, Skip, Use as-is, Enter search, enter Id, aBort? A
/mnt/d/test/Tunnelvisions - Guava (Extended Mix).flac
Tagging track: Tunnelvisions - Guava (Extended Mix)
URL: https://beatport.com/track/guava-extended-mix/10227696
(Similarity: 100.0%) (Beatport)

And the result....

# beet -vv ls -f '$title - $genre - $bpm - $musical_key'

user configuration: /root/.config/beets/config.yaml
data directory: /root/.config/beets
plugin paths:
Sending event: pluginload
library database: /mnt/d/Music/musiclibrary.db
library directory: /mnt/d/Music
Sending event: library_opened
Bwana - Electro - 123 - $musical_key
Psalm 23 - Electro - 123 - $musical_key
The Gates Of Babylon - Electro - 119 - $musical_key
Shakti Pan feat. Sven - Electro - 121 - $musical_key
Guava (Extended Mix) - Dance - 0 - $musical_key

As you can see, no proper genre/key/bpm
Tried beet bpsync also but same result

Am I doing something wrong?

@temrix
Copy link
Contributor Author

temrix commented Oct 11, 2019

musical_key was renamed to initial_key because it already existed in the musicbrainz plugin and it even gets written to tags. If you don't use the singleton mode (-s) it should work.

@sampsyo How exactly does the singleton mode work or where can I look it up?

@wualex
Copy link

wualex commented Oct 11, 2019

@temrix it should but...

# beet import /mnt/d/test/

/mnt/d/test (5 items)
Finding tags for album "Avidus - Kellerkind - Fideles".
Candidates:
1. Fideles, Haptic, Kellerkind - Kellerkind, Fideles (57.3%) (tracks, artist, year, ...) (Beatport, Digital, 2016, Stil Vor Talent, SVT183)
2. Sun@Night - Kellerkind (34.5%) (tracks, artist, album, ...) (Digital Media, 2013, XW, Tokabeatz, TB281)
3. Various Artists - Stil Vor Talent Berlin: Alexanderplatz (22.1%) (missing tracks, tracks, album, ...) (Beatport, Digital, 2017, Stil Vor Talent, SVT200)
4. Eternal Nightmare - Kellerkind WEP (20.1%) (missing tracks, tracks, artist, ...) (Digital Media, 2008, XW, KOI Records)
5. Alain Lefèvre - Fidèles Insomnies (20.0%) (tracks, missing tracks, artist, ...) (CD, 2006, CA, Analekta, AN 2 9276)
6. Various Artists - Fidèles au vinyl (16.1%) (tracks, missing tracks, album, ...) (Vinyl, 1993, BE)
7. Les Fils de Teuhpu - Fidèles castors (15.6%) (tracks, missing tracks, album, ...) (CD, 2006, FR, Irfan (le label), FDT004)
8. Westminster Cathedral Choir - Adeste Fideles (14.1%) (missing tracks, tracks, artist, ...) (CD, GB, hyperion, CDA66668)
# selection (default 1), Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? 1
Correcting tags from:
Avidus - Kellerkind - Fideles
To:
Fideles, Haptic, Kellerkind - Kellerkind, Fideles
URL:
https://beatport.com/release/kellerkind-fideles/1909258
(Similarity: 57.3%) (tracks, artist, year, missing tracks) (Beatport, Digital, 2016, Stil Vor Talent, SVT183)
* Guava (Extended Mix) (4:28)                     -> Wave Echoes (8:00) (title, length)
* Psalm 23 (#2)                                   -> Illumino (#3) (title, index)
* The Gates Of Babylon (Original Mix) (#1) (6:39) -> Subzero (#4) (6:57) (title, index, length)
* Bwana (Original Mix) (#2)                       -> Take Your Soul (#5) (title, index)
* Shakti Pan (feat. Sven)                         -> Shakti Pan feat. Sven
Missing tracks (1/6 - 16.7%):
! Vitamins (# 1) (8:21)
Apply, More candidates, Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? T
/mnt/d/test/Alex Niggemann - Bwana (Original Mix).flac
Correcting track tags from:
Alex Niggemann - Bwana (Original Mix)
To:
Alex Niggemann - Bwana
URL:
https://beatport.com/track/bwana-original-mix/11381810
(Similarity: 93.8%) (title) (Beatport)
[A]pply, More candidates, Skip, Use as-is, Enter search, enter Id, aBort? A
/mnt/d/test/Avidus - Psalm 23.flac
Tagging track: Avidus - Psalm 23
URL:
https://beatport.com/track/psalm-23-original-mix/11717455
(Similarity: 100.0%) (Beatport)
/mnt/d/test/Davi - The Gates Of Babylon (Original Mix).flac
Correcting track tags from:
Davi - The Gates Of Babylon (Original Mix)
To:
DAVI - The Gates Of Babylon
URL:
https://beatport.com/track/the-gates-of-babylon-original-mix/6061936
(Similarity: 96.5%) (title) (Beatport)
/mnt/d/test/Kellerkind - Shakti Pan (feat. Sven).flac
Correcting track tags from:
Kellerkind;Sven - Shakti Pan (feat. Sven)
To:
Kellerkind - Shakti Pan feat. Sven
URL:
https://beatport.com/track/shakti-pan-feat-sven-original-mix/8712463
(Similarity: 94.3%) (artist) (Beatport)
[A]pply, More candidates, Skip, Use as-is, Enter search, enter Id, aBort? A
/mnt/d/test/Tunnelvisions - Guava (Extended Mix).flac
Tagging track: Tunnelvisions - Guava (Extended Mix)
URL:
https://beatport.com/track/guava-extended-mix/10227696
(Similarity: 100.0%) (Beatport)

Results the same wrong tagging

# beet -vv ls -f '$title - $genre - $bpm - $initial_key'                                                                                                                               

user configuration: /root/.config/beets/config.yaml
data directory: /root/.config/beets
plugin paths:
Sending event: pluginload
library database: /mnt/d/Music/musiclibrary.db
library directory: /mnt/d/Music
Sending event: library_opened
Bwana - Electro - 123 - 4a
Psalm 23 - Electro - 123 - 9a
The Gates Of Babylon - Electro - 119 - 5a
Shakti Pan feat. Sven - Electro - 121 - 12a
Guava (Extended Mix) - Dance - 0 -

@temrix
Copy link
Contributor Author

temrix commented Oct 11, 2019

It is because you selected them as tracks and not as albums when you press T in the dialog. How is it when you select them as albums, even if they are not albums? Directly select Apply.

@sampsyo
Copy link
Member

sampsyo commented Oct 11, 2019

@sampsyo How exactly does the singleton mode work or where can I look it up?

Hi! Anything in particular you're interested in knowing? The idea is pretty straightforward—tracks are tagged one at a time instead of as entire albums.

@wualex
Copy link

wualex commented Oct 12, 2019

@temrix if i don't select them as tracks they get the $artist and $title way wrong

# beet import /mnt/d/test/

/mnt/d/test (5 items)
Finding tags for album "Avidus - Kellerkind - Fideles".
Candidates:
1. Fideles, Haptic, Kellerkind - Kellerkind, Fideles (57.3%) (tracks, artist, year, ...) (Beatport, Digital, 2016, Stil Vor Talent, SVT183)
2. Sun@Night - Kellerkind (34.5%) (tracks, artist, album, ...) (Digital Media, 2013, XW, Tokabeatz, TB281)
3. Various Artists - Stil Vor Talent Berlin: Alexanderplatz (22.1%) (missing tracks, tracks, album, ...) (Beatport, Digital, 2017, Stil Vor Talent, SVT200)
4. Eternal Nightmare - Kellerkind WEP (20.1%) (missing tracks, tracks, artist, ...) (Digital Media, 2008, XW, KOI Records)
5. Alain Lefèvre - Fidèles Insomnies (20.0%) (tracks, missing tracks, artist, ...) (CD, 2006, CA, Analekta, AN 2 9276)
6. Les Petits Chanteurs du Mont‐Royal - Adeste Fideles (16.4%) (missing tracks, tracks, artist, ...) (CD, 1990, CA, Analekta, AN 2 9301)
7. Various Artists - Fidèles au vinyl (16.1%) (tracks, missing tracks, album, ...) (Vinyl, 1993, BE)
8. Les Fils de Teuhpu - Fidèles castors (15.6%) (tracks, missing tracks, album, ...) (CD, 2006, FR, Irfan (le label), FDT004)
9. Westminster Cathedral Choir - Adeste Fideles (14.1%) (missing tracks, tracks, artist, ...) (CD, GB, hyperion, CDA66668)
# selection (default 1), Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? 1
Correcting tags from:
Avidus - Kellerkind - Fideles
To:
Fideles, Haptic, Kellerkind - Kellerkind, Fideles
URL:
https://beatport.com/release/kellerkind-fideles/1909258
(Similarity: 57.3%) (tracks, artist, year, missing tracks) (Beatport, Digital, 2016, Stil Vor Talent, SVT183)
* Guava (Extended Mix) (4:28)                     -> Wave Echoes (8:00) (title, length)
* Psalm 23 (#2)                                   -> Illumino (#3) (title, index)
* The Gates Of Babylon (Original Mix) (#1) (6:39) -> Subzero (#4) (6:57) (title, index, length)
* Bwana (Original Mix) (#2)                       -> Take Your Soul (#5) (title, index)
* Shakti Pan (feat. Sven)                         -> Shakti Pan feat. Sven
Missing tracks (1/6 - 16.7%):
! Vitamins (# 1) (8:21)
Apply, More candidates, Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? A

Resulting in:

# beet -vv ls -f '$artist - $title - $genre - $bpm - $initial_key'

user configuration: /root/.config/beets/config.yaml
data directory: /root/.config/beets
plugin paths:
Sending event: pluginload
library database: /mnt/d/Music/musiclibrary.db
library directory: /mnt/d/Music
Sending event: library_opened
Fideles - Wave Echoes - Melodic House & Techno - 124 - Dmin
Fideles - Illumino - Melodic House & Techno - 125 - Emin
Kellerkind - Subzero - Melodic House & Techno - 120 - Cmin
Kellerkind - Take Your Soul - Progressive House - 121 - Emaj
Kellerkind - Shakti Pan feat. Sven - Afro House - 121 - D♭maj
Sending event: cli_exit

So as you can see, they have to be tagged as tracks, otherwise the $artist and $title are waaay wrong... but then the tagging for genre/etc. is not taken from Beatport

Also as kinda of a side issue, i found that it also doesn't get the release date properly, probably not finding it on Musicbrainz/discogs and it's not implemented to get it from Beatport as well 😬 - which would help a lot with electronic music that's not properly tagged otherwise

@wualex
Copy link

wualex commented Oct 18, 2019

Can we reopen this @sampsyo, given that it's not actually fixed?

Thanks.

@sampsyo
Copy link
Member

sampsyo commented Oct 18, 2019

@wualex, hmm, I seem to have lost the thread here. This was originally about musical_key, and we've addressed that. Is there a way you can summarize exactly what's going on now? Is it something just about singletons mode, for example?

@wualex
Copy link

wualex commented Oct 18, 2019

That's the thing, musical_key is not actually resolved, as i tried to explain in the previous comment.

To summarize, by default the import will mess up the naming & everything for ALL the tracks because it will get the information for the whole album from Beatport, which is/will only (be) correct for the first one
If i import them as singletons (as i don't want them grouped by albums anyway), it won't add any info from Beatport

Please see my previous comment: #3387 (comment) for more info
Am i doing something wrong?

@sampsyo
Copy link
Member

sampsyo commented Oct 18, 2019

Dang, I don’t know why I’m having such trouble understanding the landscape here. Are there two problems then? (Or perhaps more?)

  1. Something about getting the artist and title wrong in album mode.
  2. Something about values not getting applied in singleton mode.

And perhaps a third one also?

  1. Something specific about musical_key.

If so, can we open separate issues for each specific problem? One big thread with multiple underlying bugs makes it really hard to make plans for fixes.

@wualex
Copy link

wualex commented Oct 20, 2019

@sampsyo well, to be honest, to me it looks like the same problem
I want to use the tags from Beatport, but it doesn't work either in default/album mode or singleton mode, as i've explained above

If i need to open another issue though for the same problem please let me know.

@sampsyo
Copy link
Member

sampsyo commented Oct 20, 2019

I'm sorry if I'm being slow; I'm just not able to understand the problems from the information you've provided so far. If you have any way to break it down so I can see exactly what is supposed to happen and what is happening instead, I might be able to make a more informed recommendation.

@wualex
Copy link

wualex commented Oct 25, 2019

No worries @sampsyo - i'm sure i don't explain that good either.

So what SHOULD happen is the following files to be tagged on import with the correct genre (at least :) ):

Alex Niggemann - Bwana (Original Mix) (genre should be: Afro House)
Avidus - Psalm 23 (genre: Melodic House & Techno)
Davi - The Gates Of Babylon (Original Mix) (genre: Tech House)
Kellerkind - Shakti Pan (feat. Sven) (genre: Afro House)
Tunnelvisions - Guava (Extended Mix) (genre: Afro House)

Trying to achieve that, i did the following:

# beet import /mnt/d/test/

/mnt/d/test (5 items)
Finding tags for album "Avidus - Kellerkind - Fideles".
Candidates:
1. Fideles, Haptic, Kellerkind - Kellerkind, Fideles (57.3%) (tracks, artist, year, ...) (Beatport, Digital, 2016, Stil Vor Talent, SVT183)
2. Sun@Night - Kellerkind (34.5%) (tracks, artist, album, ...) (Digital Media, 2013, XW, Tokabeatz, TB281)
3. Various Artists - Stil Vor Talent Berlin: Alexanderplatz (22.1%) (missing tracks, tracks, album, ...) (Beatport, Digital, 2017, Stil Vor Talent, SVT200)
4. Eternal Nightmare - Kellerkind WEP (20.1%) (missing tracks, tracks, artist, ...) (Digital Media, 2008, XW, KOI Records)
5. Alain Lefèvre - Fidèles Insomnies (20.0%) (tracks, missing tracks, artist, ...) (CD, 2006, CA, Analekta, AN 2 9276)
6. Les Petits Chanteurs du Mont‐Royal - Adeste Fideles (16.4%) (missing tracks, tracks, artist, ...) (CD, 1990, CA, Analekta, AN 2 9301)
7. Various Artists - Fidèles au vinyl (16.1%) (tracks, missing tracks, album, ...) (Vinyl, 1993, BE)
8. Les Fils de Teuhpu - Fidèles castors (15.6%) (tracks, missing tracks, album, ...) (CD, 2006, FR, Irfan (le label), FDT004)
9. Westminster Cathedral Choir - Adeste Fideles (14.1%) (missing tracks, tracks, artist, ...) (CD, GB, hyperion, CDA66668)
# selection (default 1), Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? 1
Correcting tags from:
Avidus - Kellerkind - Fideles
To:
Fideles, Haptic, Kellerkind - Kellerkind, Fideles
URL:
https://beatport.com/release/kellerkind-fideles/1909258
(Similarity: 57.3%) (tracks, artist, year, missing tracks) (Beatport, Digital, 2016, Stil Vor Talent, SVT183)
* Guava (Extended Mix) (4:28)                     -> Wave Echoes (8:00) (title, length)
* Psalm 23 (#2)                                   -> Illumino (#3) (title, index)
* The Gates Of Babylon (Original Mix) (#1) (6:39) -> Subzero (#4) (6:57) (title, index, length)
* Bwana (Original Mix) (#2)                       -> Take Your Soul (#5) (title, index)
* Shakti Pan (feat. Sven)                         -> Shakti Pan feat. Sven
Missing tracks (1/6 - 16.7%):
! Vitamins (# 1) (8:21)
Apply, More candidates, Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? A

What happens is the wrong result
Instead of 5 different artists & titles as listed above, beets tagged them all as like being from the album of the first song, with wrong artist names & titles

BUT, as you can see, the genre/bpm/key are tagged correctly from Beatport, but for the wrong tracks :|

# beet -vv ls -f '$artist - $title - $genre - $bpm - $initial_key'

user configuration: /root/.config/beets/config.yaml
data directory: /root/.config/beets
plugin paths:
Sending event: pluginload
library database: /mnt/d/Music/musiclibrary.db
library directory: /mnt/d/Music
Sending event: library_opened
Fideles - Wave Echoes - Melodic House & Techno - 124 - Dmin
Fideles - Illumino - Melodic House & Techno - 125 - Emin
Kellerkind - Subzero - Melodic House & Techno - 120 - Cmin
Kellerkind - Take Your Soul - Progressive House - 121 - Emaj
Kellerkind - Shakti Pan feat. Sven - Afro House - 121 - D♭maj

Now my logic tells me that if with the normal import beets thinks that all tracks are from the same album (i don't get why...) maybe selecting them as tracks would work!

What should happen is the same as point 1, that's why i thought imho it's the same issue

# beet import /mnt/d/test/

/mnt/d/test (5 items)
Finding tags for album "Avidus - Kellerkind - Fideles".
Candidates:
1. Fideles, Haptic, Kellerkind - Kellerkind, Fideles (57.3%) (tracks, artist, year, ...) (Beatport, Digital, 2016, Stil Vor Talent, SVT183)
2. Sun@Night - Kellerkind (34.5%) (tracks, artist, album, ...) (Digital Media, 2013, XW, Tokabeatz, TB281)
3. Various Artists - Stil Vor Talent Berlin: Alexanderplatz (22.1%) (missing tracks, tracks, album, ...) (Beatport, Digital, 2017, Stil Vor Talent, SVT200)
4. Eternal Nightmare - Kellerkind WEP (20.1%) (missing tracks, tracks, artist, ...) (Digital Media, 2008, XW, KOI Records)
5. Alain Lefèvre - Fidèles Insomnies (20.0%) (tracks, missing tracks, artist, ...) (CD, 2006, CA, Analekta, AN 2 9276)
6. Various Artists - Fidèles au vinyl (16.1%) (tracks, missing tracks, album, ...) (Vinyl, 1993, BE)
7. Les Fils de Teuhpu - Fidèles castors (15.6%) (tracks, missing tracks, album, ...) (CD, 2006, FR, Irfan (le label), FDT004)
8. Westminster Cathedral Choir - Adeste Fideles (14.1%) (missing tracks, tracks, artist, ...) (CD, GB, hyperion, CDA66668)
# selection (default 1), Skip, Use as-is, as Tracks, Group albums,
Enter search, enter Id, aBort? T

/mnt/d/test/Alex Niggemann - Bwana (Original Mix).flac
Correcting track tags from:
    Alex Niggemann - Bwana (Original Mix)
To:
    Alex Niggemann - Bwana
URL:
    https://beatport.com/track/bwana-original-mix/11381810
(Similarity: 93.8%) (title) (Beatport)
[A]pply, More candidates, Skip, Use as-is, Enter search, enter Id, aBort? A

/mnt/d/test/Avidus - Psalm 23.flac
Tagging track: Avidus - Psalm 23
URL:
    https://beatport.com/track/psalm-23-original-mix/11717455
(Similarity: 100.0%) (Beatport)

/mnt/d/test/Davi - The Gates Of Babylon (Original Mix).flac
Correcting track tags from:
    Davi - The Gates Of Babylon (Original Mix)
To:
    DAVI - The Gates Of Babylon
URL:
    https://beatport.com/track/the-gates-of-babylon-original-mix/6061936
(Similarity: 96.5%) (title) (Beatport)

/mnt/d/test/Kellerkind - Shakti Pan (feat. Sven).flac
Correcting track tags from:
    Kellerkind;Sven - Shakti Pan (feat. Sven)
To:
    Kellerkind - Shakti Pan feat. Sven
URL:
    https://beatport.com/track/shakti-pan-feat-sven-original-mix/8712463
(Similarity: 94.3%) (artist) (Beatport)
[A]pply, More candidates, Skip, Use as-is, Enter search, enter Id, aBort? A

/mnt/d/test/Tunnelvisions - Guava (Extended Mix).flac
Tagging track: Tunnelvisions - Guava (Extended Mix)
URL:
    https://beatport.com/track/guava-extended-mix/10227696
(Similarity: 100.0%) (Beatport)

What happens is still not correct
As you can see this time beets finds the correct Beatport url for each of the songs, but doesn't write the tags properly

# beet -vv ls -f '$artist - $title - $genre - $bpm - $initial_key'
user configuration: /root/.config/beets/config.yaml
data directory: /root/.config/beets
plugin paths:
Sending event: pluginload
library database: /mnt/d/Music/musiclibrary.db
library directory: /mnt/d/Music
Sending event: library_opened
Alex Niggemann - Bwana - Electro - 123 - 4a
Avidus - Psalm 23 - Electro - 123 - 9a
DAVI - The Gates Of Babylon - Electro - 119 - 5a
Kellerkind - Shakti Pan feat. Sven - Electro - 121 - 12a
Tunnelvisions - Guava (Extended Mix) - Dance - 0 -

To be honest i don't understand how beets works & why if i try to import different tracks from different artists it just assumes they should be from the same album...

Please let me know what other info i can provide or what else i could test to get to the bottom of this.

@sampsyo
Copy link
Member

sampsyo commented Oct 25, 2019

Now my logic tells me that if with the normal import beets thinks that all tracks are from the same album (i don't get why...)

Aha, yes, this is a good place to start. This is a basic beets idea that's worth reading a bit more about. Start with the autotagger overview, which explains the album situation:
http://docs.beets.io/en/stable/guides/tagger.html#overview

To be clear, this is expected behavior—for all metadata matches, including MusicBrainz.

As you can see this time beets finds the correct Beatport url for each of the songs, but doesn't write the tags properly

I see—to summarize, I think the conclusion is that the $genre, $bpm, and $initial_key fields aren't provided in singleton mode? I don't entirely understand why this would be, but the fault might lie with the Beatport API itself—perhaps it just doesn't supply that information for those tracks, or it only supplies those fields for album track listings, not for individually-matched tracks. Might that be the case, @temrix?

In any case, that does seem like a problem, regardless of whether it's on beets's end or on the Beatport end. And it probably does warrant a separate issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug bugs that are confirmed and actionable
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants