Spotify

Aug. 30, 2018

Program to blacklist artists on Spotify

Spotify seems not to allow to blacklist artists or songs by design (at least they reject the feature request in their forum), which means that these songs of these artists are added to radio streams even when you disliked them before.

But if you are using Mopidy (e.g. to use Spotify on a raspberry pi or just to have a nice web interface), you can use its MPD interface to remove blacklisted artists from the playlist as soon as they are added using this short python program:

#!/usr/bin/env python
# Licence: This code snippet is public domain

from mpd import MPDClient import time

blacklist = ["artist1", "artist2", "artist3"]

client = MPDClient() client.connect("localhost", 6600)

while True: time.sleep(10) for item in client.playlistinfo(): if item['artist'] in blacklist: client.deleteid(item['id'])

The program checks every 10 seconds if a song from a blacklisted artist in the playlist and then deletes it.

Kategorien OpenSource Kurz bemerkt Software
Tagged Spotify Songs music MPD Mopidy Blacklist
Mobil qrcode zeigen

0 Kommentare