Skip Discogs query on insufficiently tagged files
When files are missing both, album and artist tags, the Discogs metadata
plugin sends empty information to the Discogs API which returns arbitrary
query results.
This patch catches this case and states it in beets import verbose output.
@@ -157,6 +157,11 @@ class DiscogsPlugin(BeetsPlugin):
if not self.discogs_client:
return
+ if not album and not artist:
+ self._log.debug('Skipping Discogs query. Files missing album and '
+ 'artist tags.')
+ return []
+
if va_likely:
query = album
else:
