Spotify fix turns repeat on: the playlist ran out and autoplay played other songs (WRONG PLAYLIST overnight)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -3269,6 +3269,9 @@ def play_spotify(cfg, fix, chk, label, run=None):
|
|||||||
time.sleep(sp_.get("open_wait", 8))
|
time.sleep(sp_.get("open_wait", 8))
|
||||||
run(["/usr/bin/osascript", "-e", 'tell application "Spotify" to play track "%s"' % playlist],
|
run(["/usr/bin/osascript", "-e", 'tell application "Spotify" to play track "%s"' % playlist],
|
||||||
capture_output=True, text=True, timeout=15)
|
capture_output=True, text=True, timeout=15)
|
||||||
|
# Repeat on: with it off the playlist runs out and Spotify's autoplay carries on with similar songs that are
|
||||||
|
# not in it (2026-10-25 16:42 to the next morning: "WRONG PLAYLIST" while it sounded right).
|
||||||
|
run(["/usr/bin/osascript", "-e", 'tell application "Spotify" to set repeating to true'], capture_output=True, text=True, timeout=10)
|
||||||
time.sleep(sp_.get("play_wait", 3))
|
time.sleep(sp_.get("play_wait", 3))
|
||||||
r = run(["/usr/bin/osascript", "-e", 'tell application "Spotify" to player state as text'],
|
r = run(["/usr/bin/osascript", "-e", 'tell application "Spotify" to player state as text'],
|
||||||
capture_output=True, text=True, timeout=10)
|
capture_output=True, text=True, timeout=10)
|
||||||
|
|||||||
Reference in New Issue
Block a user