Skip to content

fix: authenticate and resolve selected track before playback - #1390

Open
marcosdefina wants to merge 2 commits into
Jellify-Music:mainfrom
marcosdefina:fix/ios-first-track-playback
Open

fix: authenticate and resolve selected track before playback#1390
marcosdefina wants to merge 2 commits into
Jellify-Music:mainfrom
marcosdefina:fix/ios-first-track-playback

Conversation

@marcosdefina

@marcosdefina marcosdefina commented Aug 14, 2026

Copy link
Copy Markdown

What changed

  • Put Jellyfin authentication in extraPayload.headers, the field Nitro Player 1.5.0 reads on iOS and Android
  • Use the SDK-generated MediaBrowser authorization value instead of a raw token
  • Resolve an empty selected-track URL before calling TrackPlayer.play()
  • Let overlapping onTracksNeedUpdate requests complete independently instead of globally aborting the earlier iOS request
  • Add regressions for native track auth shape, update-before-play ordering, and overlapping URL updates

Why

On Jellify 1.2.7 for iOS, selecting a current Jellyfin item can fetch PlaybackInfo successfully but never issue the subsequent /Audio/{id}/stream request. The Jellyfin session remains paused at 0 ms. A live reproduction generated repeated PlaybackInfo requests but no audio request.

The immediate blocker is that Jellify stores headers at the top level of TrackItem, while Nitro Player explicitly reads extraPayload.headers. The native player therefore receives no usable Jellyfin authorization. The selected queue entry also starts with url: "", and a second lazy-load callback could abort the first selected-track request.

This addresses the first-track/paused-at-zero failure mode reported in #1214.

Validation

  • bunx jest jest/functional/ItemToTrack.test.ts jest/functional/Player/queue.test.ts jest/functional/Player/track-media-info.test.ts --runInBand (42 tests pass)
  • bun run tsc
  • Focused ESLint passes
  • Full unsigned iOS Debug build succeeds with Xcode 26.0.1

@marcosdefina marcosdefina changed the title fix: resolve selected track before playback fix: authenticate and resolve selected track before playback Aug 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant