Repository: aome510/spotify-player (language: rust)

Issue:
Liked tracks are not playable
**Describe the bug**
When I try to play any track in the Liked tracks - nothing happens. Everything else, playlists and podcasts work fine.

**To Reproduce**
Go to Liked Tracks, try to play any track

**Expected behaviour**
Playback should start

**Log and backtrace**
```
2024-12-01T19:58:23.324372Z  INFO client_request{request=GetUserSavedTracks}: spotify_player::client: Successfully handled the client request, took: 13406ms
2024-12-01T19:58:24.362797Z ERROR client_request{request=Player(StartPlayback(Context(Tracks(TracksId { uri: "tracks:user-liked-tracks", kind: "Liked Tracks" }), Some(Uri("spotify:track:6zU0xyXN0AsFZ57dI3HM0s"))), None))}: spotify_player::client::handlers: Failed to handle client request: `StartPlayback` request for `tracks` context is not supported
```
**Screenshots**
If applicable, add screenshots to help explain your problem.

**Environment**

- OS: Windows 11
- Application version:  0.20.2


Discussion / hints:

Fix patch:
diff --git a/Cargo.lock b/Cargo.lock
index cb61828f..c8790fdb 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -5156,7 +5156,7 @@ dependencies = [
 
 [[package]]
 name = "spotify_player"
-version = "0.20.2"
+version = "0.20.3"
 dependencies = [
  "anyhow",
  "async-trait",
diff --git a/spotify_player/Cargo.toml b/spotify_player/Cargo.toml
index 04776001..b036ba75 100644
--- a/spotify_player/Cargo.toml
+++ b/spotify_player/Cargo.toml
@@ -1,6 +1,6 @@
 [package]
 name = "spotify_player"
-version = "0.20.2"
+version = "0.20.3"
 authors = ["Thang Pham <phamducthang1234@gmail.com>"]
 edition = "2021"
 license = "MIT"
diff --git a/spotify_player/src/event/window.rs b/spotify_player/src/event/window.rs
index 132a56a6..e99f449a 100644
--- a/spotify_player/src/event/window.rs
+++ b/spotify_player/src/event/window.rs
@@ -304,10 +304,14 @@ fn handle_command_for_track_table_window(
                 filtered_tracks[id].id.uri()
             };
 
-            let base_playback = if let Some(context_id) = context_id {
-                Playback::Context(context_id, None)
-            } else {
-                Playback::URIs(tracks.iter().map(|t| t.id.clone().into()).collect(), None)
+            let base_playback = match context_id {
+                None | Some(ContextId::Tracks(_)) => {
+                    Playback::URIs(tracks.iter().map(|t| t.id.clone().into()).collect(), None)
+                }
+                Some(ContextId::Show(_)) => unreachable!(
+                    "show context should be handled by handle_command_for_episode_table_window"
+                ),
+                Some(context_id) => Playback::Context(context_id, None),
             };
 
             client_pub.send(ClientRequest::Player(PlayerRequest::StartPlayback(


Test patch: