Skip to content

Commit d35a8cd

Browse files
authored
Merge pull request #4804 from arsaboo/fetchfix
Fetchart: Use the right field to obtain Spotify album id
2 parents 430a75d + c0bae4e commit d35a8cd

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

beetsplug/fetchart.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -956,7 +956,11 @@ def available(cls, log, config):
956956
return HAS_BEAUTIFUL_SOUP
957957

958958
def get(self, album, plugin, paths):
959-
url = self.SPOTIFY_ALBUM_URL + album.mb_albumid
959+
try:
960+
url = self.SPOTIFY_ALBUM_URL + album.items().get().spotify_album_id
961+
except AttributeError:
962+
self._log.debug('Fetchart: no Spotify album ID found')
963+
return
960964
try:
961965
response = requests.get(url)
962966
response.raise_for_status()

docs/changelog.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ for Python 3.6).
1111

1212
New features:
1313

14+
* Fetchart: Use the right field (`spotify_album_id`) to obtain the Spotify album id
15+
:bug:`4803`
1416
* Prevent reimporting album if it is permanently removed from Spotify
1517
:bug:`4800`
1618
* Added option use `cover_art_arl` as an album art source in the `fetchart` plugin.

0 commit comments

Comments
 (0)