Repository navigation
Persisted queue reuses expired YouTube stream URLs after restart, causing an endless 403 Forbidden retry loop #2226
lmcastillofo
started this conversation in
General
Replies: 1 comment 2 replies
|
Can you summarize what claude said in your own words? |
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Originally opened as #2225, which was auto-closed because external issues go to Discussions. Reposting here.
Description
When a track is resolved via the YouTube streaming provider, the resolved stream (a
googlevideo.com/videoplayback?...URL) is persisted insidequeue.jsontogether with the queue item. After restarting Nuclear later, the queue is restored and playback reuses that stored URL instead of resolving a fresh one.YouTube stream URLs expire after a few hours (
expire=query parameter) and are bound to the IP address that requested them (ip=parameter). Once either changes, the stream server answers403 Forbidden, and Nuclear keeps retrying the same dead URL. The track never plays and there is no automatic recovery.In my case the log accumulated more than 11,000 lines of:
followed by:
Steps to reproduce
Expected behavior
If a stored stream URL is expired (its
expiretimestamp is in the past) or the stream server answers 401/403/410, Nuclear should discard the cached stream, re-resolve it through the streaming provider (getStreamUrl/ yt-dlp), and retry once. If re-resolving also fails, mark the item as failed and stop retrying.Actual behavior
queue.jsonhad"lastResolvedAtIso": "2026-07-04T07:51:03.445Z". Its stored URL hadexpire=on 2026-07-04 and anip=from a different network."status": "error","error": "Streaming service returned error: 403 Forbidden".Verification that the source itself was fine
Using the bundled yt-dlp (
~/Library/Application Support/com.nuclearplayer/ytdlp/yt-dlp_macos, version2026.10.10.233141) to resolve the same video ID returned a fresh URL that respondedHTTP 206immediately. Clearing the queue and re-adding the track fixed playback. So the failure is caused only by reusing the persisted stream.Related
#2067 fixed stale stream URLs when loading playlists created from queues. This looks like the same root cause in the queue persistence path itself. #1397 ("No way to reload stale songs") is also related.
Environment
All reactions