music-assistant-server

Branch:dev-lidarr-plugin

Commit Details

Fix a Spotify audiobook stopping when you seek to another chapter (#6063)

# What does this implement/fix?

Seeking forward in a Spotify audiobook played through the Soloist
backend could stop the queue instead of continuing playback.

An audiobook is one item stitched from a Spotify URI per chapter, so a
seek that crosses a chapter boundary asks the session for a different
URI than the one it is playing. That read as another item arriving at a
busy session, which is reported as capacity and stops the queue. It is
really the queue's own seek of what the session is delivering, so it now
takes the session over and restarts it at the target.

- Recognise a queue's own seek of the item the session is delivering,
whichever chapter it lands on; another player, or an early fetch of the
next item, still gives up softly as before
- End the stream a seek replaced instead of letting it stitch the item's
next chapter on, which would take the session straight back off the seek
- Tests for both, and the provider README updated

## Types of changes

- [x] Bugfix (non-breaking change which fixes an issue) — `bugfix`
- [ ] New feature (non-breaking change which adds functionality) —
`new-feature`
- [ ] Enhancement to an existing feature — `enhancement`
- [ ] New music/player/metadata/plugin provider — `new-provider`
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected) — `breaking-change`
- [ ] Refactor (no behaviour change) — `refactor`
- [ ] Documentation only — `documentation`
- [ ] Maintenance / chore — `maintenance`
- [ ] CI / workflow change — `ci`
- [ ] Dependencies bump — `dependencies`

## Checklist

- [x] The code change is tested and works locally.
- [x] `pre-commit run --all-files` passes.
- [x] `pytest` passes, and tests have been added/updated under `tests/`
where applicable.
- [ ] For changes to shared models, the companion PR in
`music-assistant/models` is linked.
- [ ] For changes affecting the UI, the companion PR in
`music-assistant/frontend` is linked.
- [x] I have read and complied with the project's [AI
Policy](https://github.com/music-assistant/.github/blob/main/AI_POLICY.md)
for any AI-assisted contributions.
- [ ] I have [raised a PR against the documentation
repository](https://github.com/music-assistant/music-assistant.io/blob/main/CONTRIBUTING.md)
targeting the main or beta branch as appropriate.
Forgejo

Author

Marcel van der Veldt<[email protected]>
August 27, 2026 at 06:43 PM UTC

Committer

Marcel van der Veldt<[email protected]>
August 29, 2026 at 12:28 AM UTC
435additions
53deletions
7files changed

Parent commits

Changes

7 files
+435-53

Changed Files (7)

music_assistant/providers/spotify/
music_assistant/providers/spotify/backends/
tests/providers/spotify/
music_assistant/providers/spotify/README.md
music_assistant/providers/spotify/backends/__init__.py
+1-1
music_assistant/providers/spotify/backends/base.py
+14
music_assistant/providers/spotify/backends/librespot.py
+1
music_assistant/providers/spotify/backends/soloist.py
+90-18
music_assistant/providers/spotify/provider.py
+14-2
tests/providers/spotify/test_soloist_backend.py
+315-32