Error when searching via TUI or command line
Hi, the search function was working fine a couple of weeks ago, but I tried it today and got an API error, both in the TUI and via the command-line search
spt search "Mega Circuit Japanese Breakfast" --tracks Error: convert result failed, reason: Error("invalid type: null, expected struct SimplifiedPlaylist", line: 1, column: 312); content: ["{\"playlists\":{\"href\":\"https://api.spotify.com/v1/search?offset=0&limit=1&query=Mega%20Circuit%20Japanese%20Breakfast&type=playlist\",\"limit\":1,\"next\":\"https://api.spotify.com/v1/search?offset=1&limit=1&query=Mega%20Circuit%20Japanese%20Breakfast&type=playlist\",\"offset\":0,\"previous\":null,\"total\":800,\"items\":[null]}}"]
Note in the command line that it seems to be doing a playlist search even though I specified --tracks. If I do a playlist search I still get an error, though it does show some results:
` spt search "Electronica" --playlists Error: convert result failed, reason: Error("invalid type: null, expected struct SimplifiedPlaylist", line: 1, column: 259); content: ["{"playlists":{"href":"https://api.spotify.com/v1/search?offset=0&limit=4&query=Electronica&type=playlist\",\"limit\":4,\"next\":\"https://api.spotify.com/v1/search?offset=4&limit=4&query=Electronica&type=playlist\",\"offset\":0,\"previous\":null,\"total\":10,\"items\":[null,{\"collaborative\":false,\"description\":\"\",\"external_urls\":{\"spotify\":\"https://open.spotify.com/playlist/5YxJKtbkL0sbkbtpJvyjxH\"},\"href\":\"https://api.spotify.com/v1/playlists/5YxJKtbkL0sbkbtpJvyjxH\",\"id\":\"5YxJKtbkL0sbkbtpJvyjxH\",\"images\":[{\"height\":640,\"url\":\"https://mosaic.scdn.co/640/ab67616d00001e0236cd5096b7e30f9e44d8cc5cab67616d00001e02631fc778e74925f0caeb4ca1ab67616d00001e027168d021e2f52d8f909649d4ab67616d00001e02aaf8cc0fcc7f117fcf5b9157\",\"width\":640},{\"height\":300,\"url\":\"https://mosaic.scdn.co/300/ab67616d00001e0236cd5096b7e30f9e44d8cc5cab67616d00001e02631fc778e74925f0caeb4ca1ab67616d00001e027168d021e2f52d8f909649d4ab67616d00001e02aaf8cc0fcc7f117fcf5b9157\",\"width\":300},{\"height\":60,\"url\":\"https://mosaic.scdn.co/60/ab67616d00001e0236cd5096b7e30f9e44d8cc5cab67616d00001e02631fc778e74925f0caeb4ca1ab67616d00001e027168d021e2f52d8f909649d4ab67616d00001e02aaf8cc0fcc7f117fcf5b9157\",\"width\":60}],\"name\":\"Julian Electronica","owner":{"display_name":"Julian Lawson","external_urls":{"spotify":"https://open.spotify.com/user/1137848221\"},\"href\":\"https://api.spotify.com/v1/users/1137848221\",\"id\":\"1137848221\",\"type\":\"user\",\"uri\":\"spotify:user:1137848221\"},\"primary_color\":null,\"public\":true,\"snapshot_id\":\"AAAAj3JuhrykYaMUII6G8V/HDgubUplY\",\"tracks\":{\"href\":\"https://api.spotify.com/v1/playlists/5YxJKtbkL0sbkbtpJvyjxH/tracks\",\"total\":118},\"type\":\"playlist\",\"uri\":\"spotify:playlist:5YxJKtbkL0sbkbtpJvyjxH\"},{\"collaborative\":false,\"description\":\"\",\"external_urls\":{\"spotify\":\"https://open.spotify.com/playlist/6rAs3WXg8xQco1tORQZoQt\"},\"href\":\"https://api.spotify.com/v1/playlists/6rAs3WXg8xQco1tORQZoQt\",\"id\":\"6rAs3WXg8xQco1tORQZoQt\",\"images\":[{\"height\":null,\"url\":\"https://image-cdn-ak.spotifycdn.com/image/ab67706c0000da84d9542e4cbc9ee9914a8703d5\",\"width\":null}],\"name\":\"Electronic 80s The Collection - Ministry Of Sound","owner":{"display_name":"PaulBenedict1878","external_urls":{"spotify":"https://open.spotify.com/user/cfe4afl6vknm5cady9t4o5rca\"},\"href\":\"https://api.spotify.com/v1/users/cfe4afl6vknm5cady9t4o5rca\",\"id\":\"cfe4afl6vknm5cady9t4o5rca\",\"type\":\"user\",\"uri\":\"spotify:user:cfe4afl6vknm5cady9t4o5rca\"},\"primary_color\":null,\"public\":true,\"snapshot_id\":\"AAAAU3Gos64XFq5MKNuBeE3j2/ZG94lA\",\"tracks\":{\"href\":\"https://api.spotify.com/v1/playlists/6rAs3WXg8xQco1tORQZoQt/tracks\",\"total\":80},\"type\":\"playlist\",\"uri\":\"spotify:playlist:6rAs3WXg8xQco1tORQZoQt\"},null]}}"]
`
Version: spotify-tui 0.25.0
Thanks
Source: Rigellute/spotify-tui