2021-05-04 22:08:49 +00:00
# Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog ](https://keepachangelog.com/en/1.0.0/ ),
and this project adheres to [Semantic Versioning ](https://semver.org/spec/v2.0.0.html ) since v0.2.0.
2024-10-31 22:14:13 +00:00
## [Unreleased] - YYYY-MM-DD
### Changed
Spirc: Replace Mecury with Dealer (#1356)
This was a huge effort by photovoltex@gmail.com with help from the community.
Over 140 commits were squashed. Below, their commit messages are kept unchanged.
---
* dealer wrapper for ease of use
* improve sending protobuf requests
* replace connect config with connect_state config
* start integrating dealer into spirc
* payload handling, gzip support
* put connect state consistent
* formatting
* request payload handling, gzip support
* expose dealer::protocol, move request in own file
* integrate handle of connect-state commands
* spirc: remove ident field
* transfer playing state better
* spirc: remove remote_update stream
* spirc: replace command sender with connect state update
* spirc: remove device state and remaining unused methods
* spirc: remove mercury sender
* add repeat track state
* ConnectState: add methods to replace state in spirc
* spirc: move context into connect_state, update load and next
* spirc: remove state, adjust remaining methods
* spirc: handle more dealer request commands
* revert rustfmt.toml
* spirc: impl shuffle
- impl shuffle again
- extracted fill up of next tracks in own method
- moved queue revision update into next track fill up
- removed unused method `set_playing_track_index`
- added option to specify index when resetting the playback context
- reshuffle after repeat context
* spirc: handle device became inactive
* dealer: adjust payload handling
* spirc: better set volume handling
* dealer: box PlayCommand (clippy warning)
* dealer: always respect queued tracks
* spirc: update duration of track
* ConnectState: update more restrictions
* cleanup
* spirc: handle queue requests
* spirc: skip next with track
* proto: exclude spirc.proto
- move "deserialize_with" functions into own file
- replace TrackRef with ProvidedTrack
* spirc: stabilize transfer/context handling
* core: cleanup some remains
* connect: improvements to code structure and performance
- use VecDeque for next and prev tracks
* connect: delayed volume update
* connect: move context resolve into own function
* connect: load context asynchronous
* connect: handle reconnect
- might currently steal the active devices playback
* connect: some fixes and adjustments
- fix wrong offset when transferring playback
- fix missing displayed context in web-player
- remove access_token from log
- send correct state reason when updating volume
- queue track correctly
- fix wrong assumption for skip_to
* connect: replace error case with option
* connect: use own context state
* connect: more stabilising
- handle SkipTo having no Index
- handle no transferred restrictions
- handle no transferred index
- update state before shutdown, for smoother reacquiring
* connect: working autoplay
* connect: handle repeat context/track
* connect: some quick fixes
- found self-named uid in collection after reconnecting
* connect: handle add_to_queue via set_queue
* fix clippy warnings
* fix check errors, fix/update example
* fix 1.75 specific error
* connect: position update improvements
* connect: handle unavailable
* connect: fix incorrect status handling for desktop and mobile
* core: fix dealer reconnect
- actually acquire new token
- use login5 token retrieval
* connect: split state into multiple files
* connect: encapsulate provider logic
* connect: remove public access to next and prev tracks
* connect: remove public access to player
* connect: move state only commands into own file
* connect: improve logging
* connect: handle transferred queue again
* connect: fix all-features specific error
* connect: extract transfer handling into own file
* connect: remove old context model
* connect: handle more transfer cases correctly
* connect: do auth_token pre-acquiring earlier
* connect: handle play with skip_to by uid
* connect: simplified cluster update log
* core/connect: add remaining set value commands
* connect: position update workaround/fix
* connect: some queue cleanups
* connect: add uid to queue
* connect: duration as volume delay const
* connect: some adjustments and todo cleanups
- send volume update before general update
- simplify queue revision to use the track uri
- argument why copying the prev/next tracks is fine
* connect: handle shuffle from set_options
* connect: handle context update
* connect: move other structs into model.rs
* connect: reduce SpircCommand visibility
* connect: fix visibility of model
* connect: fix: shuffle on startup isn't applied
* connect: prevent loading a context with no tracks
* connect: use the first page of a context
* connect: improve context resolving
- support multiple pages
- support page_url of context
- handle single track
* connect: prevent integer underflow
* connect: rename method for better clarity
* connect: handle mutate and update messages
* connect: fix 1.75 problems
* connect: fill, instead of replace next page
* connect: reduce context update to single method
* connect: remove unused SpircError, handle local files
* connect: reduce nesting, adjust initial transfer handling
* connect: don't update volume initially
* core: disable trace logging of handled mercury responses
* core/connect: prevent takeover from other clients, handle session-update
* connect: add queue-uid for set_queue command
* connect: adjust fields for PlayCommand
* connect: preserve context position after update_context
* connect: unify metadata modification
- only handle `is_queued` `true` items for queue
* connect: polish request command handling
- reply to all request endpoints
- adjust some naming
- add some docs
* connect: add uid to tracks without
* connect: simpler update of current index
* core/connect: update log msg, fix wrong behavior
- handle became inactive separately
- remove duplicate stop
- adjust docs for websocket request
* core: add option to request without metrics and salt
* core/context: adjust context requests and update
- search should now return the expected context
- removed workaround for single track playback
- move local playback check into update_context
- check track uri for invalid characters
- early return with `?`
* connect: handle possible search context uri
* connect: remove logout support
- handle logout command
- disable support for logout
- add todos for logout
* connect: adjust detailed tracks/context handling
- always allow next
- handle no prev track available
- separate active and fill up context
* connect: adjust context resolve handling, again
* connect: add autoplay metadata to tracks
- transfer into autoplay again
* core/connect: cleanup session after spirc stops
* update CHANGELOG.md
* playback: fix clippy warnings
* connect: adjust metadata
- unify naming
- move more metadata infos into metadata.rs
* connect: add delimiter between context and autoplay playback
* connect: stop and resume correctly
* connect: adjust context resolving
- improved certain logging parts
- preload autoplay when autoplay attribute mutates
- fix transfer context uri
- fix typo
- handle empty strings for resolve uri
- fix unexpected stop of playback
* connect: ignore failure during stop
* connect: revert resolve_uri changes
* connect: correct context reset
* connect: reduce boiler code
* connect: fix some incorrect states
- uid getting replaced by empty value
- shuffle/repeat clearing autoplay context
- fill_up updating and using incorrect index
* core: adjust incorrect separator
* connect: move `add_to_queue` and `mark_unavailable` into tracks.rs
* connect: refactor - directly modify PutStateRequest
- replace `next_tracks`, `prev_tracks`, `player` and `device` with `request`
- provide helper methods for the removed fields
* connect: adjust handling of context metadata/restrictions
* connect: fix incorrect context states
* connect: become inactive when no cluster is reported
* update CHANGELOG.md
* core/playback: preemptively fix clippy warnings
* connect: minor adjustment to session changed
* connect: change return type changing active context
* connect: handle unavailable contexts
* connect: fix previous restrictions blocking load with shuffle
* connect: update comments and logging
* core/connect: reduce some more duplicate code
* more docs around the dealer
2024-12-10 19:36:09 +00:00
- [connect] Replaced `ConnectConfig` with `ConnectStateConfig` (breaking)
- [connect] Replaced `playing_track_index` field of `SpircLoadCommand` with `playing_track` (breaking)
- [connect] Replaced Mercury usage in `Spirc` with Dealer
2024-10-31 22:14:13 +00:00
### Added
Spirc: Replace Mecury with Dealer (#1356)
This was a huge effort by photovoltex@gmail.com with help from the community.
Over 140 commits were squashed. Below, their commit messages are kept unchanged.
---
* dealer wrapper for ease of use
* improve sending protobuf requests
* replace connect config with connect_state config
* start integrating dealer into spirc
* payload handling, gzip support
* put connect state consistent
* formatting
* request payload handling, gzip support
* expose dealer::protocol, move request in own file
* integrate handle of connect-state commands
* spirc: remove ident field
* transfer playing state better
* spirc: remove remote_update stream
* spirc: replace command sender with connect state update
* spirc: remove device state and remaining unused methods
* spirc: remove mercury sender
* add repeat track state
* ConnectState: add methods to replace state in spirc
* spirc: move context into connect_state, update load and next
* spirc: remove state, adjust remaining methods
* spirc: handle more dealer request commands
* revert rustfmt.toml
* spirc: impl shuffle
- impl shuffle again
- extracted fill up of next tracks in own method
- moved queue revision update into next track fill up
- removed unused method `set_playing_track_index`
- added option to specify index when resetting the playback context
- reshuffle after repeat context
* spirc: handle device became inactive
* dealer: adjust payload handling
* spirc: better set volume handling
* dealer: box PlayCommand (clippy warning)
* dealer: always respect queued tracks
* spirc: update duration of track
* ConnectState: update more restrictions
* cleanup
* spirc: handle queue requests
* spirc: skip next with track
* proto: exclude spirc.proto
- move "deserialize_with" functions into own file
- replace TrackRef with ProvidedTrack
* spirc: stabilize transfer/context handling
* core: cleanup some remains
* connect: improvements to code structure and performance
- use VecDeque for next and prev tracks
* connect: delayed volume update
* connect: move context resolve into own function
* connect: load context asynchronous
* connect: handle reconnect
- might currently steal the active devices playback
* connect: some fixes and adjustments
- fix wrong offset when transferring playback
- fix missing displayed context in web-player
- remove access_token from log
- send correct state reason when updating volume
- queue track correctly
- fix wrong assumption for skip_to
* connect: replace error case with option
* connect: use own context state
* connect: more stabilising
- handle SkipTo having no Index
- handle no transferred restrictions
- handle no transferred index
- update state before shutdown, for smoother reacquiring
* connect: working autoplay
* connect: handle repeat context/track
* connect: some quick fixes
- found self-named uid in collection after reconnecting
* connect: handle add_to_queue via set_queue
* fix clippy warnings
* fix check errors, fix/update example
* fix 1.75 specific error
* connect: position update improvements
* connect: handle unavailable
* connect: fix incorrect status handling for desktop and mobile
* core: fix dealer reconnect
- actually acquire new token
- use login5 token retrieval
* connect: split state into multiple files
* connect: encapsulate provider logic
* connect: remove public access to next and prev tracks
* connect: remove public access to player
* connect: move state only commands into own file
* connect: improve logging
* connect: handle transferred queue again
* connect: fix all-features specific error
* connect: extract transfer handling into own file
* connect: remove old context model
* connect: handle more transfer cases correctly
* connect: do auth_token pre-acquiring earlier
* connect: handle play with skip_to by uid
* connect: simplified cluster update log
* core/connect: add remaining set value commands
* connect: position update workaround/fix
* connect: some queue cleanups
* connect: add uid to queue
* connect: duration as volume delay const
* connect: some adjustments and todo cleanups
- send volume update before general update
- simplify queue revision to use the track uri
- argument why copying the prev/next tracks is fine
* connect: handle shuffle from set_options
* connect: handle context update
* connect: move other structs into model.rs
* connect: reduce SpircCommand visibility
* connect: fix visibility of model
* connect: fix: shuffle on startup isn't applied
* connect: prevent loading a context with no tracks
* connect: use the first page of a context
* connect: improve context resolving
- support multiple pages
- support page_url of context
- handle single track
* connect: prevent integer underflow
* connect: rename method for better clarity
* connect: handle mutate and update messages
* connect: fix 1.75 problems
* connect: fill, instead of replace next page
* connect: reduce context update to single method
* connect: remove unused SpircError, handle local files
* connect: reduce nesting, adjust initial transfer handling
* connect: don't update volume initially
* core: disable trace logging of handled mercury responses
* core/connect: prevent takeover from other clients, handle session-update
* connect: add queue-uid for set_queue command
* connect: adjust fields for PlayCommand
* connect: preserve context position after update_context
* connect: unify metadata modification
- only handle `is_queued` `true` items for queue
* connect: polish request command handling
- reply to all request endpoints
- adjust some naming
- add some docs
* connect: add uid to tracks without
* connect: simpler update of current index
* core/connect: update log msg, fix wrong behavior
- handle became inactive separately
- remove duplicate stop
- adjust docs for websocket request
* core: add option to request without metrics and salt
* core/context: adjust context requests and update
- search should now return the expected context
- removed workaround for single track playback
- move local playback check into update_context
- check track uri for invalid characters
- early return with `?`
* connect: handle possible search context uri
* connect: remove logout support
- handle logout command
- disable support for logout
- add todos for logout
* connect: adjust detailed tracks/context handling
- always allow next
- handle no prev track available
- separate active and fill up context
* connect: adjust context resolve handling, again
* connect: add autoplay metadata to tracks
- transfer into autoplay again
* core/connect: cleanup session after spirc stops
* update CHANGELOG.md
* playback: fix clippy warnings
* connect: adjust metadata
- unify naming
- move more metadata infos into metadata.rs
* connect: add delimiter between context and autoplay playback
* connect: stop and resume correctly
* connect: adjust context resolving
- improved certain logging parts
- preload autoplay when autoplay attribute mutates
- fix transfer context uri
- fix typo
- handle empty strings for resolve uri
- fix unexpected stop of playback
* connect: ignore failure during stop
* connect: revert resolve_uri changes
* connect: correct context reset
* connect: reduce boiler code
* connect: fix some incorrect states
- uid getting replaced by empty value
- shuffle/repeat clearing autoplay context
- fill_up updating and using incorrect index
* core: adjust incorrect separator
* connect: move `add_to_queue` and `mark_unavailable` into tracks.rs
* connect: refactor - directly modify PutStateRequest
- replace `next_tracks`, `prev_tracks`, `player` and `device` with `request`
- provide helper methods for the removed fields
* connect: adjust handling of context metadata/restrictions
* connect: fix incorrect context states
* connect: become inactive when no cluster is reported
* update CHANGELOG.md
* core/playback: preemptively fix clippy warnings
* connect: minor adjustment to session changed
* connect: change return type changing active context
* connect: handle unavailable contexts
* connect: fix previous restrictions blocking load with shuffle
* connect: update comments and logging
* core/connect: reduce some more duplicate code
* more docs around the dealer
2024-12-10 19:36:09 +00:00
- [connect] Add `seek_to` field to `SpircLoadCommand` (breaking)
- [connect] Add `repeat_track` field to `SpircLoadCommand` (breaking)
- [playback] Add `track` field to `PlayerEvent::RepeatChanged` (breaking)
- [core] Add `request_with_options` and `request_with_protobuf_and_options` to `SpClient`
2024-10-31 22:14:13 +00:00
### Fixed
2024-12-05 13:11:40 +00:00
- [core] Fix "no native root CA certificates found" on platforms unsupported
by `rustls-native-certs` .
2024-12-05 13:20:03 +00:00
- [core] Fix all APs rejecting with "TryAnotherAP" when connecting session
on Android platform.
- [core] Fix "Invalid Credentials" when using a Keymaster access token and
client ID on Android platform.
2024-12-16 20:48:39 +00:00
- [connect] Fix "play" command not handled if missing "offset" property
2024-12-05 13:11:40 +00:00
2024-10-31 22:14:13 +00:00
### Removed
2024-12-16 20:48:39 +00:00
- [core] Removed `get_canvases` from SpClient (breaking)
- [metadata] Removed `genres` from Album (breaking)
- [metadata] Removed `genre` from Artists (breaking)
2024-10-30 20:11:04 +00:00
## [0.6.0] - 2024-10-30
2024-10-15 19:32:50 +00:00
2024-10-30 20:11:04 +00:00
This version takes another step into the direction of the HTTP API, fixes a
couple of bugs, and makes it easier for developers to mock a certain platform.
Also it adds the option to choose avahi, dnssd or libmdns as your zeroconf
backend for Spotify Connect discovery.
2024-10-27 14:59:25 +00:00
2024-10-19 18:27:26 +00:00
### Changed
- [core] The `access_token` for http requests is now acquired by `login5`
2024-10-26 14:45:02 +00:00
- [core] MSRV is now 1.75 (breaking)
- [discovery] librespot can now be compiled with multiple MDNS/DNS-SD backends
(avahi, dns_sd, libmdns) which can be selected using a CLI flag. The defaults
are unchanged (breaking).
2024-10-19 18:27:26 +00:00
2024-10-15 19:32:50 +00:00
### Added
2024-10-30 19:24:01 +00:00
- [core] Add `get_token_with_client_id()` to get a token for a specific client ID
2024-10-19 18:27:26 +00:00
- [core] Add `login` (mobile) and `auth_token` retrieval via login5
2024-10-21 20:11:38 +00:00
- [core] Add `OS` and `os_version` to `config.rs`
2024-10-26 14:45:02 +00:00
- [discovery] Added a new MDNS/DNS-SD backend which connects to Avahi via D-Bus.
2024-10-15 19:32:50 +00:00
2024-10-30 20:11:04 +00:00
### Fixed
2024-10-17 15:02:56 +00:00
- [connect] Fixes initial volume showing zero despite playing in full volume instead
2024-10-30 20:11:04 +00:00
- [core] Fix "source slice length (16) does not match destination slice length
(20)" panic on some tracks
2024-10-17 15:02:56 +00:00
2024-10-15 19:32:50 +00:00
## [0.5.0] - 2024-10-15
2022-07-30 20:28:12 +00:00
2024-10-15 17:00:51 +00:00
This version is be a major departure from the architecture up until now. It
2022-07-30 22:04:08 +00:00
focuses on implementing the "new Spotify API". This means moving large parts
of the Spotify protocol from Mercury to HTTP. A lot of this was reverse
engineered before by @devgianlu of librespot-java. It was long overdue that we
started implementing it too, not in the least because new features like the
hopefully upcoming Spotify HiFi depend on it.
Splitting up the work on the new Spotify API, v0.5.0 brings HTTP-based file
downloads and metadata access. Implementing the "dealer" (replacing the current
Mercury-based SPIRC message bus with WebSockets, also required for social plays)
2024-10-15 17:00:51 +00:00
is a large and separate effort, slated for some later release.
2022-07-30 22:04:08 +00:00
While at it, we are taking the liberty to do some major refactoring to make
librespot more robust. Consequently not only the Spotify API changed but large
parts of the librespot API too. For downstream maintainers, we realise that it
can be a lot to move from the current codebase to this one, but believe us it
will be well worth it.
All these changes are likely to introduce new bugs as well as some regressions.
We appreciate all your testing and contributions to the repository:
https://github.com/librespot-org/librespot
2022-07-30 20:28:12 +00:00
### Changed
2022-07-30 22:04:08 +00:00
- [all] Assertions were changed into `Result` or removed (breaking)
2022-09-28 20:17:43 +00:00
- [all] Purge use of `unwrap` , `expect` and return `Result` (breaking)
2022-07-30 22:04:08 +00:00
- [all] `chrono` replaced with `time` (breaking)
- [all] `time` updated (CVE-2020-26235)
- [all] Improve lock contention and performance (breaking)
2023-07-19 11:57:44 +00:00
- [all] Use a single `player` instance. Eliminates occasional `player` and
`audio backend` restarts, which can cause issues with some playback
configurations.
2024-10-15 17:00:51 +00:00
- [all] Updated and removed unused dependencies
2022-07-30 22:04:08 +00:00
- [audio] Files are now downloaded over the HTTPS CDN (breaking)
2022-09-28 20:17:43 +00:00
- [audio] Improve file opening and seeking performance (breaking)
2024-08-27 21:16:48 +00:00
- [core] MSRV is now 1.74 (breaking)
2022-07-30 22:04:08 +00:00
- [connect] `DeviceType` moved out of `connect` into `core` (breaking)
2022-09-30 19:36:20 +00:00
- [connect] Update and expose all `spirc` context fields (breaking)
- [connect] Add `Clone, Defaut` traits to `spirc` contexts
- [connect] Autoplay contexts are now retrieved with the `spclient` (breaking)
2024-10-15 17:00:51 +00:00
- [contrib] Updated Docker image
2022-07-30 22:04:08 +00:00
- [core] Message listeners are registered before authenticating. As a result
there now is a separate `Session::new` and subsequent `session.connect` .
(breaking)
- [core] `ConnectConfig` moved out of `core` into `connect` (breaking)
- [core] `client_id` for `get_token` moved to `SessionConfig` (breaking)
- [core] Mercury code has been refactored for better legibility (breaking)
- [core] Cache resolved access points during runtime (breaking)
- [core] `FileId` is moved out of `SpotifyId` . For now it will be re-exported.
- [core] Report actual platform data on login
2024-09-13 05:35:55 +00:00
- [core] Support `Session` authentication with a Spotify access token
2024-09-23 18:44:51 +00:00
- [core] `Credentials.username` is now an `Option` (breaking)
- [core] `Session::connect` tries multiple access points, retrying each one.
2024-09-25 19:34:59 +00:00
- [core] Each access point connection now timesout after 3 seconds.
2024-10-06 20:11:57 +00:00
- [core] Listen on both IPV4 and IPV6 on non-windows hosts
2022-09-28 20:59:03 +00:00
- [main] `autoplay {on|off}` now acts as an override. If unspecified, `librespot`
now follows the setting in the Connect client that controls it. (breaking)
- [metadata] Most metadata is now retrieved with the `spclient` (breaking)
- [metadata] Playlists are moved to the `playlist4_external` protobuf (breaking)
2023-01-04 05:28:36 +00:00
- [metadata] Handle playlists that are sent with microsecond-based timestamps
2022-07-30 22:04:08 +00:00
- [playback] The audio decoder has been switched from `lewton` to `Symphonia` .
This improves the Vorbis sound quality, adds support for MP3 as well as for
FLAC in the future. (breaking)
- [playback] Improve reporting of actual playback cursor
- [playback] The passthrough decoder is now feature-gated (breaking)
- [playback] `rodio` : call play and pause
- [protocol] protobufs have been updated
2022-07-30 20:28:12 +00:00
### Added
2022-07-30 22:04:08 +00:00
- [all] Check that array indexes are within bounds (panic safety)
- [all] Wrap errors in librespot `Error` type (breaking)
2024-10-15 17:00:51 +00:00
- [audio] Make audio fetch parameters tunable
2022-11-25 08:57:14 +00:00
- [connect] Add option on which zeroconf will bind. Defaults to all interfaces. Ignored by DNS-SD.
2022-09-28 20:17:43 +00:00
- [connect] Add session events
- [connect] Add `repeat` , `set_position_ms` and `set_volume` to `spirc.rs`
- [contrib] Add `event_handler_example.py`
2022-07-30 22:04:08 +00:00
- [core] Send metrics with metadata queries: client ID, country & product
- [core] Verify Spotify server certificates (prevents man-in-the-middle attacks)
- [core] User attributes are stored in `Session` upon login, accessible with a
getter and setter, and automatically updated as changes are pushed by the
Spotify infrastructure (breaking)
- [core] HTTPS is now supported, including for proxies (breaking)
- [core] Resolve `spclient` and `dealer` access points (breaking)
- [core] Get and cache tokens through new token provider (breaking)
- [core] `spclient` is the API for HTTP-based calls to the Spotify servers.
It supports a lot of functionality, including audio previews and image
downloads even if librespot doesn't use that for playback itself.
- [core] Support downloading of lyrics
2022-11-28 03:03:36 +00:00
- [core] Support parsing `SpotifyId` for local files
2023-01-02 23:24:49 +00:00
- [core] Support parsing `SpotifyId` for named playlists
2023-06-01 19:39:35 +00:00
- [core] Add checks and handling for stale server connections.
2024-10-15 17:00:51 +00:00
- [core] Fix potential deadlock waiting for audio decryption keys.
- [discovery] Add option to show playback device as a group
2022-09-28 20:17:43 +00:00
- [main] Add all player events to `player_event_handler.rs`
- [main] Add an event worker thread that runs async to the main thread(s) but
sync to itself to prevent potential data races for event consumers
- [metadata] All metadata fields in the protobufs are now exposed (breaking)
2024-09-13 05:35:55 +00:00
- [oauth] Standalone module to obtain Spotify access token using OAuth authorization code flow.
2022-07-30 22:04:08 +00:00
- [playback] Explicit tracks are skipped if the controlling Connect client has
disabled such content. Applications that use librespot as a library without
Connect should use the 'filter-explicit-content' user attribute in the session.
2022-08-23 20:23:37 +00:00
- [playback] Add metadata support via a `TrackChanged` event
2022-12-03 11:25:27 +00:00
- [connect] Add `activate` and `load` functions to `Spirc` , allowing control over local connect sessions
2022-12-26 17:03:27 +00:00
- [metadata] Add `Lyrics`
2023-06-30 07:30:14 +00:00
- [discovery] Add discovery initialisation retries if within the 1st min of uptime
2022-07-30 22:04:08 +00:00
2022-07-30 20:28:12 +00:00
### Fixed
2022-09-28 20:17:43 +00:00
- [connect] Set `PlayStatus` to the correct value when Player is loading to
avoid blanking out the controls when `self.play_status` is `LoadingPlay` or
`LoadingPause` in `spirc.rs`
- [connect] Handle attempts to play local files better by basically ignoring
attempts to load them in `handle_remote_update` in `spirc.rs`
2022-09-30 19:36:20 +00:00
- [connect] Loading previous or next tracks, or looping back on repeat, will
only start playback when we were already playing
2022-09-28 20:17:43 +00:00
- [connect, playback] Clean up and de-noise events and event firing
2024-10-15 17:00:51 +00:00
- [core] Fixed frequent disconnections for some users
- [core] More strict Spotify ID parsing
- [discovery] Update active user field upon connection
2022-09-28 20:17:43 +00:00
- [playback] Handle invalid track start positions by just starting the track
from the beginning
- [playback] Handle disappearing and invalid devices better
- [playback] Handle seek, pause, and play commands while loading
2023-05-06 07:47:08 +00:00
- [playback] Handle disabled normalisation correctly when using fixed volume
2024-10-15 17:00:51 +00:00
- [playback] Do not stop sink in gapless mode
2023-01-28 09:53:23 +00:00
- [metadata] Fix missing colon when converting named spotify IDs to URIs
2022-09-28 20:17:43 +00:00
2022-07-29 19:34:01 +00:00
## [0.4.2] - 2022-07-29
2022-05-21 20:52:39 +00:00
2022-07-30 22:04:08 +00:00
Besides a couple of small fixes, this point release is mainly to blacklist the
ap-gew4 and ap-gue1 access points that caused librespot to fail to playback
anything.
Development will now shift to the new HTTP-based API, targeted for a future
v0.5.0 release. The new-api branch will therefore be promoted to dev. This is a
major departure from the old API and although it brings many exciting new
things, it is also likely to introduce new bugs and some regressions.
Long story short, this v0.4.2 release is the most stable that librespot has yet
to offer. But, unless anything big comes up, it is also intended as the last
release to be based on the old API. Happy listening.
2022-05-21 20:52:39 +00:00
### Changed
2022-07-21 01:27:45 +00:00
- [playback] `pipe` : Better error handling
2022-07-29 19:34:01 +00:00
- [playback] `subprocess` : Better error handling
2022-05-21 20:52:39 +00:00
### Added
2022-07-29 19:30:27 +00:00
- [core] `apresolve` : Blacklist ap-gew4 and ap-gue1 access points that cause channel errors
2022-07-21 01:27:45 +00:00
- [playback] `pipe` : Implement stop
2022-05-21 20:52:39 +00:00
### Fixed
2022-07-21 01:27:45 +00:00
- [main] fix `--opt=value` line argument logging
2022-07-29 19:34:01 +00:00
- [playback] `alsamixer` : make `--volume-ctrl fixed` work as expected when combined with `--mixer alsa`
2022-05-21 20:52:39 +00:00
2022-05-23 20:21:56 +00:00
## [0.4.1] - 2022-05-23
2022-07-30 22:04:08 +00:00
This release fixes dependency issues when installing from crates.
2022-05-23 20:21:56 +00:00
### Changed
- [chore] The MSRV is now 1.56
### Fixed
- [playback] Fixed dependency issues when installing from crate
2022-05-21 20:14:18 +00:00
## [0.4.0] - 2022-05-21
2021-10-04 19:44:03 +00:00
2022-07-30 22:04:08 +00:00
Note: This version was yanked, because a corrupt package was uploaded and failed
to install.
This is a polishing release, adding a few little extras and improving on many
thers. We had to break a couple of API's to do so, and therefore bumped the
minor version number. v0.4.x may be the last in series before we migrate from
the current channel-based Spotify backend to a more HTTP-based backend.
Targeting that major effort for a v0.5 release sometime, we intend to maintain
v0.4.x as a stable branch until then.
2021-10-30 19:22:24 +00:00
### Changed
2022-05-21 20:14:18 +00:00
- [chore] The MSRV is now 1.53
- [contrib] Hardened security of the `systemd` service units
- [core] `Session` : `connect()` now returns the long-term credentials
- [core] `Session` : `connect()` now accepts a flag if the credentails should be stored via the cache
- [main] Different option descriptions and error messages based on what backends are enabled at build time
2022-01-14 22:31:29 +00:00
- [playback] More robust dynamic limiter for very wide dynamic range (breaking)
2022-05-21 20:14:18 +00:00
- [playback] `alsa` : improve `--device ?` output for the Alsa backend
2022-05-21 18:55:55 +00:00
- [playback] `gstreamer` : create own context, set correct states and use sync handler
2022-05-21 20:14:18 +00:00
- [playback] `pipe` : create file if it doesn't already exist
- [playback] `Sink` : `write()` now receives ownership of the packet (breaking)
2021-10-30 19:22:24 +00:00
2021-10-27 03:18:10 +00:00
### Added
2022-05-21 20:14:18 +00:00
- [main] Enforce reasonable ranges for option values (breaking)
- [main] Add the ability to parse environment variables
- [main] Log now emits warning when trying to use options that would otherwise have no effect
- [main] Verbose logging now logs all parsed environment variables and command line arguments (credentials are redacted)
- [main] Add a `-q` , `--quiet` option that changes the logging level to WARN
- [main] Add `disable-credential-cache` flag (breaking)
- [main] Add a short name for every flag and option
- [playback] `pulseaudio` : set the PulseAudio name to match librespot's device name via `PULSE_PROP_application.name` environment variable (user set env var value takes precedence) (breaking)
- [playback] `pulseaudio` : set icon to `audio-x-generic` so we get an icon instead of a placeholder via `PULSE_PROP_application.icon_name` environment variable (user set env var value takes precedence) (breaking)
- [playback] `pulseaudio` : set values to: `PULSE_PROP_application.version` , `PULSE_PROP_application.process.binary` , `PULSE_PROP_stream.description` , `PULSE_PROP_media.software` and `PULSE_PROP_media.role` environment variables (user set env var values take precedence) (breaking)
2021-10-27 03:18:10 +00:00
2021-10-28 14:10:10 +00:00
### Fixed
2022-05-21 20:14:18 +00:00
- [connect] Don't panic when activating shuffle without previous interaction
2022-01-23 18:02:04 +00:00
- [core] Removed unsafe code (breaking)
2022-05-21 20:14:18 +00:00
- [main] Fix crash when built with Avahi support but Avahi is locally unavailable
- [main] Prevent hang when discovery is disabled and there are no credentials or when bad credentials are given
- [main] Don't panic when parsing options, instead list valid values and exit
- [main] `--alsa-mixer-device` and `--alsa-mixer-index` now fallback to the card and index specified in `--device` .
- [playback] Adhere to ReplayGain spec when calculating gain normalisation factor
- [playback] `alsa` : make `--volume-range` overrides apply to Alsa softvol controls
2021-10-30 19:22:24 +00:00
### Removed
2022-05-21 20:14:18 +00:00
- [playback] `alsamixer` : previously deprecated options `mixer-card` , `mixer-name` and `mixer-index` have been removed
2021-10-28 14:10:10 +00:00
2021-10-24 18:07:11 +00:00
## [0.3.1] - 2021-10-24
2021-10-14 10:57:33 +00:00
### Changed
- Include build profile in the displayed version information
2021-10-19 20:33:04 +00:00
- [playback] Improve dithering CPU usage by about 33%
2021-10-14 10:57:33 +00:00
2021-10-13 18:37:46 +00:00
### Fixed
- [connect] Partly fix behavior after last track of an album/playlist
## [0.3.0] - 2021-10-13
2021-10-04 19:44:03 +00:00
2021-05-24 13:53:32 +00:00
### Added
2021-05-26 18:50:42 +00:00
- [discovery] The crate `librespot-discovery` for discovery in LAN was created. Its functionality was previously part of `librespot-connect` .
Implement dithering (#694)
Dithering lowers digital-to-analog conversion ("requantization") error, linearizing output, lowering distortion and replacing it with a constant, fixed noise level, which is more pleasant to the ear than the distortion.
Guidance:
- On S24, S24_3 and S24, the default is to use triangular dithering. Depending on personal preference you may use Gaussian dithering instead; it's not as good objectively, but it may be preferred subjectively if you are looking for a more "analog" sound akin to tape hiss.
- Advanced users who know that they have a DAC without noise shaping have a third option: high-passed dithering, which is like triangular dithering except that it moves dithering noise up in frequency where it is less audible. Note: 99% of DACs are of delta-sigma design with noise shaping, so unless you have a multibit / R2R DAC, or otherwise know what you are doing, this is not for you.
- Don't dither or shape noise on S32 or F32. On F32 it's not supported anyway (there are no integer conversions and so no rounding errors) and on S32 the noise level is so far down that it is simply inaudible even after volume normalisation and control.
New command line option:
--dither DITHER Specify the dither algorithm to use - [none, gpdf,
tpdf, tpdf_hp]. Defaults to 'tpdf' for formats S16
S24, S24_3 and 'none' for other formats.
Notes:
This PR also features some opportunistic improvements. Worthy of mention are:
- matching reference Vorbis sample conversion techniques for lower noise
- a cleanup of the convert API
2021-05-26 19:19:17 +00:00
- [playback] Add support for dithering with `--dither` for lower requantization error (breaking)
2021-05-24 13:53:32 +00:00
- [playback] Add `--volume-range` option to set dB range and control `log` and `cubic` volume control curves
- [playback] `alsamixer` : support for querying dB range from Alsa softvol
2021-05-30 18:09:39 +00:00
- [playback] Add `--format F64` (supported by Alsa and GStreamer only)
2021-10-04 19:44:03 +00:00
- [playback] Add `--normalisation-gain-type auto` that switches between album and track automatically
2021-05-24 13:53:32 +00:00
### Changed
2021-09-20 17:29:12 +00:00
- [audio, playback] Moved `VorbisDecoder` , `VorbisError` , `AudioPacket` , `PassthroughDecoder` , `PassthroughError` , `DecoderError` , `AudioDecoder` and the `convert` module from `librespot-audio` to `librespot-playback` . The underlying crates `vorbis` , `librespot-tremor` , `lewton` and `ogg` should be used directly. (breaking)
2021-05-31 20:32:39 +00:00
- [audio, playback] Use `Duration` for time constants and functions (breaking)
2021-05-26 18:50:42 +00:00
- [connect, playback] Moved volume controls from `librespot-connect` to `librespot-playback` crate
- [connect] Synchronize player volume with mixer volume on playback
2021-05-30 18:09:39 +00:00
- [playback] Store and pass samples in 64-bit floating point
2021-05-24 13:53:32 +00:00
- [playback] Make cubic volume control available to all mixers with `--volume-ctrl cubic`
- [playback] Normalize volumes to `[0.0..1.0]` instead of `[0..65535]` for greater precision and performance (breaking)
- [playback] `alsamixer` : complete rewrite (breaking)
2021-10-04 19:44:03 +00:00
- [playback] `alsamixer` : query card dB range for the volume control unless specified otherwise
2021-05-24 13:53:32 +00:00
- [playback] `alsamixer` : use `--device` name for `--mixer-card` unless specified otherwise
2021-06-18 18:25:09 +00:00
- [playback] `player` : consider errors in `sink.start` , `sink.stop` and `sink.write` fatal and `exit(1)` (breaking)
2021-06-30 07:54:02 +00:00
- [playback] `player` : make `convert` and `decoder` public so you can implement your own `Sink`
2021-09-20 17:22:02 +00:00
- [playback] `player` : update default normalisation threshold to -2 dBFS
- [playback] `player` : default normalisation type is now `auto`
2021-05-04 22:08:49 +00:00
2021-05-26 18:50:42 +00:00
### Deprecated
2021-05-26 19:03:06 +00:00
- [connect] The `discovery` module was deprecated in favor of the `librespot-discovery` crate
2021-08-26 20:35:45 +00:00
- [playback] `alsamixer` : renamed `mixer-card` to `alsa-mixer-device`
- [playback] `alsamixer` : renamed `mixer-name` to `alsa-mixer-control`
- [playback] `alsamixer` : renamed `mixer-index` to `alsa-mixer-index`
2021-04-13 08:29:34 +00:00
2021-05-24 13:53:32 +00:00
### Removed
2021-05-26 18:50:42 +00:00
- [connect] Removed no-op mixer started/stopped logic (breaking)
2021-05-26 19:43:20 +00:00
- [playback] Removed `with-vorbis` and `with-tremor` features
2021-08-26 20:35:45 +00:00
- [playback] `alsamixer` : removed `--mixer-linear-volume` option, now that `--volume-ctrl {linear|log}` work as expected on Alsa
2021-04-13 08:29:34 +00:00
2021-05-16 20:30:35 +00:00
### Fixed
2021-05-26 18:50:42 +00:00
- [connect] Fix step size on volume up/down events
2021-10-05 20:08:26 +00:00
- [connect] Fix looping back to the first track after the last track of an album or playlist
2022-07-28 16:51:49 +00:00
- [playback] Incorrect `PlayerConfig::default().normalisation_threshold` caused distortion when using dynamic volume normalisation downstream
2021-05-26 18:50:42 +00:00
- [playback] Fix `log` and `cubic` volume controls to be mute at zero volume
2021-05-30 18:57:46 +00:00
- [playback] Fix `S24_3` format on big-endian systems
2021-05-26 18:50:42 +00:00
- [playback] `alsamixer` : make `cubic` consistent between cards that report minimum volume as mute, and cards that report some dB value
- [playback] `alsamixer` : make `--volume-ctrl {linear|log}` work as expected
2021-05-30 18:57:46 +00:00
- [playback] `alsa` , `gstreamer` , `pulseaudio` : always output in native endianness
2021-06-09 18:50:24 +00:00
- [playback] `alsa` : revert buffer size to ~500 ms
2021-06-30 19:14:23 +00:00
- [playback] `alsa` , `pipe` , `pulseaudio` : better error handling
2021-09-20 17:20:44 +00:00
- [metadata] Skip tracks whose Spotify ID's can't be found (e.g. local files, which aren't supported)
2021-05-16 20:30:35 +00:00
2021-05-04 22:08:49 +00:00
## [0.2.0] - 2021-05-04
## [0.1.6] - 2021-02-22
## [0.1.5] - 2021-02-21
## [0.1.3] - 2020-07-29
## [0.1.2] - 2020-07-22
## [0.1.1] - 2020-01-30
## [0.1.0] - 2019-11-06
2024-10-31 22:14:13 +00:00
[unreleased]: https://github.com/librespot-org/librespot/compare/v0.6.0...HEAD
2024-10-30 20:11:04 +00:00
[0.6.0]: https://github.com/librespot-org/librespot/compare/v0.5.0...v0.6.0
2024-10-15 19:32:50 +00:00
[0.5.0]: https://github.com/librespot-org/librespot/compare/v0.4.2...v0.5.0
[0.4.2]: https://github.com/librespot-org/librespot/compare/v0.4.1...v0.4.2
[0.4.1]: https://github.com/librespot-org/librespot/compare/v0.4.0...v0.4.1
[0.4.0]: https://github.com/librespot-org/librespot/compare/v0.3.1...v0.4.0
[0.3.1]: https://github.com/librespot-org/librespot/compare/v0.3.0...v0.3.1
[0.3.0]: https://github.com/librespot-org/librespot/compare/v0.2.0...v0.3.0
[0.2.0]: https://github.com/librespot-org/librespot/compare/v0.1.6...v0.2.0
[0.1.6]: https://github.com/librespot-org/librespot/compare/v0.1.5...v0.1.6
[0.1.5]: https://github.com/librespot-org/librespot/compare/v0.1.3...v0.1.5
[0.1.3]: https://github.com/librespot-org/librespot/compare/v0.1.2...v0.1.3
[0.1.2]: https://github.com/librespot-org/librespot/compare/v0.1.1...v0.1.2
[0.1.1]: https://github.com/librespot-org/librespot/compare/v0.1.0...v0.1.1
2021-05-04 22:08:49 +00:00
[0.1.0]: https://github.com/librespot-org/librespot/releases/tag/v0.1.0