LastGenre - Malformed Response from Last.fm


#1

Hi there - dove into the world of beets today, pretty exciting so far. I’ve got it up and running on Windows 10, with most plugins configured. I have been testing imports and subsequent results to see if I am confident enough to import my entire library.

One of the last issues irking me is that the lastgenre plugin can’t seem to either grab the genre from last.fm or understand the response from last.fm.

There error I am getting is:

lastgenre: last.fm error: Malformed response from Last.fm. Underlying error: mismatched tag: line 6, column 2

Setup:

  • Installed pylast with pip
  • enabled lastgenre in config.yaml

Things I have tried:

  • Google-fu, which got me here (and I reviewed what I could find on lastgenre)
  • Fiddled with lastgenre plugin configuration (still received same error)
  • Tried various albums, both with existing genres and some with blank genres
  • Tried to figure out if I needed an API key from last.fm, which I (think) have concluded ‘no’

Here is my verbose output:

$ beet -vv import E:\User\Music\New
user configuration: C:\Users\User\AppData\Roaming\beets\config.yaml
data directory: C:\Users\User\AppData\Roaming\beets
plugin paths:
Sending event: pluginload
lastgenre: Loading canonicalization tree c:\users\User\appdata\local\programs\python\python36\lib\site-packages\beetsplug\lastgenre\genres-tree.yaml
library database: E:\User\Music\musiclibrary.db
library directory: E:\User\Music\Test
Sending event: library_opened
Sending event: import_begin
Sending event: import_task_created
Sending event: import_task_start
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 01 - Funeral For A Great Drunken Bird.flac'
chroma: matched recordings ['ff17d3d1-0b66-4687-a4a9-16d93cf2d1f3'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 02 - When God Comes Back.flac'
chroma: matched recordings ['81e664e4-e2ec-4231-8531-db9b70fa482b'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 03 - The Marriage Of Coyote Woman.flac'
chroma: matched recordings ['c47998ad-0f13-4d5d-9f6b-3b051cd63555'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 04 - Swallowed By The Sea.flac'
chroma: matched recordings ['0aa885e6-159c-42b8-94b2-cc82113444d2'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 05 - Charles Useriam.flac'
chroma: matched recordings ['40f1558f-17b0-4690-9c5a-79e50da59b23', '8122b2a8-dc53-427f-bb43-810a11e32ad0'] on releases ['beef1141-3bf6-4467-84c0-7f25ae734e75', 'd307f214-e9c2-4d66-a174-18aa7b0bb4ab', 'fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 06 - The Death Of Coyote Woman.flac'
chroma: matched recordings ['382cd7ae-f684-4035-9612-019764c1b2ab'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 07 - Romany Dagger.flac'
chroma: matched recordings ['3bdabc12-74a2-43c3-9ad9-9c444cd627f8'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 08 - Mountain.flac'
chroma: matched recordings ['e81067da-5b5c-46e5-bff0-1515ed23eab9'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366', '0982a7ba-812d-4dd8-9c9f-fbf70841e1b5']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 09 - Romany Dagger (Remended).flac'
chroma: matched recordings ['a362b97d-2c87-416c-91af-92719860abc2'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366']
chroma: chroma: fingerprinted b'E:\\User\\Music\\New\\All Them Witches - Lightning At The Door (2013) [100 FLAC]\\All Them Witches - Lightning At The Door - 10 - Surface-To-Air Whistle.flac'
chroma: matched recordings ['020f1a4d-499a-4902-8fef-29cb2edb4aa7'] on releases ['fd88ceb5-2e9f-48fa-9efb-18a65eefe083', '2b0bcf48-0518-4219-9d45-566acbc2d366']
Looking up: E:\User\Music\New\All Them Witches - Lightning At The Door (2013) [100 FLAC]
Tagging All Them Witches - Lightning At The Door
No album ID found.
Search terms: All Them Witches - Lightning At The Door
Album might be VA: False
Searching for MusicBrainz releases with: {'release': 'lightning at the door', 'artist': 'all them witches', 'tracks': '10'}
Requesting MusicBrainz release 2b0bcf48-0518-4219-9d45-566acbc2d366
primary MB release type: album
Sending event: albuminfo_received
Candidate: All Them Witches - Lightning at the Door (2b0bcf48-0518-4219-9d45-566acbc2d366)
Computing track assignment...
...done.
Success. Distance: 0.00
Requesting MusicBrainz release fd88ceb5-2e9f-48fa-9efb-18a65eefe083
primary MB release type: album
Sending event: albuminfo_received
Candidate: All Them Witches - Lightning at the Door (fd88ceb5-2e9f-48fa-9efb-18a65eefe083)
Computing track assignment...
...done.
Success. Distance: 0.00
Requesting MusicBrainz release 0982a7ba-812d-4dd8-9c9f-fbf70841e1b5
primary MB release type: album
Sending event: albuminfo_received
Candidate: All Them Witches - Lightning at the Door (0982a7ba-812d-4dd8-9c9f-fbf70841e1b5)
Computing track assignment...
...done.
Success. Distance: 0.05
Requesting MusicBrainz release ee79e846-a9ac-4d17-b0d4-5694a9bddcaf
primary MB release type: album
secondary MB release type(s): live
Sending event: albuminfo_received
Candidate: All Them Witches - At the Garage (ee79e846-a9ac-4d17-b0d4-5694a9bddcaf)
Computing track assignment...
...done.
Success. Distance: 0.59
Requesting MusicBrainz release 036bebf8-210d-44a7-88c8-f22874e32a02
primary MB release type: album
Sending event: albuminfo_received
Candidate: All Them Witches - Sleeping Through the War (036bebf8-210d-44a7-88c8-f22874e32a02)
Computing track assignment...
...done.
Success. Distance: 0.77
Requesting MusicBrainz release fd88ceb5-2e9f-48fa-9efb-18a65eefe083
primary MB release type: album
Sending event: albuminfo_received
Requesting MusicBrainz release 2b0bcf48-0518-4219-9d45-566acbc2d366
primary MB release type: album
Sending event: albuminfo_received
Requesting MusicBrainz release 0982a7ba-812d-4dd8-9c9f-fbf70841e1b5
primary MB release type: album
Sending event: albuminfo_received
chroma: acoustid album candidates: 3
Sending event: albuminfo_received
Candidate: All Them Witches - Lightning at the Door (fd88ceb5-2e9f-48fa-9efb-18a65eefe083)
Duplicate.
Sending event: albuminfo_received
Candidate: All Them Witches - Lightning at the Door (2b0bcf48-0518-4219-9d45-566acbc2d366)
Duplicate.
Sending event: albuminfo_received
Candidate: All Them Witches - Lightning at the Door (0982a7ba-812d-4dd8-9c9f-fbf70841e1b5)
Duplicate.
Evaluating 5 candidates.

E:\User\Music\New\All Them Witches - Lightning At The Door (2013) [100 FLAC] (10 items)
Sending event: before_choose_candidate
Correcting tags from:
    All Them Witches - Lightning At The Door
To:
    All Them Witches - Lightning at the Door
URL:
    https://musicbrainz.org/release/2b0bcf48-0518-4219-9d45-566acbc2d366
(Similarity: 100.0%) (CD, 2016, US, New West Records)
 * Funeral For A Great Drunken Bird -> Funeral for a Great Drunken Bird
 * The Marriage Of Coyote Woman     -> The Marriage of Coyote Woman
 * Swallowed By The Sea             -> Swallowed by the Sea
 * The Death Of Coyote Woman        -> The Death of Coyote Woman
Sending event: import_task_choice
Sending event: import_task_apply
0 of 10 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: 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
lastgenre: last.fm error: Malformed response from Last.fm. Underlying error: mismatched tag: line 6, column 2
lastgenre: last.fm error: Malformed response from Last.fm. Underlying error: mismatched tag: line 6, column 2
lastgenre: added last.fm album genre (None):
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: 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
fetchart: trying source filesystem for album All Them Witches - Lightning at the Door
fetchart: using fallback art file All Them Witches - Lightning At The Door.jpg
fetchart: using local image E:\User\Music\New\All Them Witches - Lightning At The Door (2013) [100 FLAC]\All Them Witches - Lightning At The Door.jpg
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: 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: database_change
Sending event: database_change
Sending event: database_change
Sending event: database_change
Sending event: import_task_files
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\01 Funeral for a Great Drunken Bird.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\02 When God Comes Back.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\03 The Marriage of Coyote Woman.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\04 Swallowed by the Sea.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\05 Charles Useriam.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\06 The Death of Coyote Woman.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\07 Romany Dagger.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\08 Mountain.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\09 Romany Dagger (Remended).flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
scrub: auto-scrubbing E:\User\Music\Test\All Them Witches\Lightning at the Door\10 Surface-To-Air Whistle.flac
scrub: writing new tags after scrub
Sending event: write
Sending event: after_write
Sending event: art_set
Sending event: database_change
Sending event: album_imported
Sending event: import
Sending event: cli_exit
copyartifacts: Copying artifact: All Them Witches - Lightning At The Door.log
copyartifacts: Ignored files:
copyartifacts:    All Them Witches - Lightning At The Door.cue
copyartifacts:    All Them Witches - Lightning At The Door.jpg

Any help would be appreciated!


#2

Huh! It looks like the Last.fm servers are returning invalid XML results. In particular, I notice that the API calls we need are currently yielding 502 Bad Gateway errors.

There’s not too much you can do about that, sadly! Fingers crossed that the API comes back up soon…


#3

Thanks for the quick reply! Glad it is not on my end! I will check this over the next couple of days…