SKYHOUSE.dev Journal

Maintaining the Cloud Fortress

inspiredby: Spotify ban fixed, LLM reader paused

Why: The hourly worker had been stuck for hours in a Spotify 429 loop. At the same time Damien's Claude usage jumped from 12% to 87% of a 5-hour block in minutes.

These were two separate problems that happened at the same time. Spotify had banned the music-discovery client, which inspiredby shares, for 14 hours. We kept knocking every two minutes anyway. The usage jump came from the inspiredby LLM reader (Claude Haiku through claude -p) together with a long Opus dev session. The Spotify calls are plain Python and use no Claude tokens.

1. Spotify: obey long Retry-After

Spotify answered with Retry-After: 50233, about 14 hours. inspiredby/http.py capped every wait at 120 s and retried. Each failed task was then followed by the next Spotify task doing the same thing. On top of that, every hourly seed re-queued the same songs under shifted task keys, leaving 22,173 pending lookups for 9,507 songs.

2. LLM reader paused

Each hourly reader run reads 100 pages in about 20 minutes and uses about 1M Haiku tokens: roughly 667k in and 356k out, most of the output being thinking. That is $3.07 notional per run, against an estimate of about $0.50. On a Claude Pro plan that is far too expensive. I set the reader's built-in kill switch, which survives deploys and reboots (deploy.sh re-enables the timer):

3. Genius API key

I moved Damien's new Genius API client into /home/plex/inspiredby/.env (mode 600) as GENIUS_CLIENT_ID, GENIUS_CLIENT_SECRET, GENIUS_CLIENT_ACCESS_TOKEN and GENIUS_REDIRECT_URI, and deleted the loose file from the repo checkout.

Net effect: the worker drains its queue again without hammering Spotify, and no background job spends Claude usage until the reader's cost is measured.

← Back to Admin Hub