mirror of
https://github.com/Rigellute/spotify-tui.git
synced 2026-04-27 00:25:53 +03:00
[GH-ISSUE #1152] Bug: Error parsing API response when performing a search #557
Labels
No labels
bug
enhancement
good first issue
help wanted
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/spotify-tui#557
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Harthuz on GitHub (Apr 21, 2025).
Original GitHub issue: https://github.com/Rigellute/spotify-tui/issues/1152
Description:
When performing a search in the application, an error occurs while parsing the response from the Spotify API.
The error message is:
This suggests that the application attempted to parse a
nullvalue into aSimplifiedPlayliststructure, which is not allowed.Steps to Reproduce:
Screenshot of the error:
Possible Cause:
The Spotify API may return
nullfor certain fields when there are no results or missing data. The app currently expects every item to conform to theSimplifiedPlayliststructure, so it's crashing instead of handlingnullvalues gracefully.Suggestion:
Add a check before parsing the API response to ensure that
nullvalues are handled appropriately or filtered out before deserialization.@sewnie commented on GitHub (Apr 21, 2025):
Spotify-tui has unfortunately been abandoned by the author, and since then, the Spotify API changed signficantly, breaking this project. You may also notice breaking Rust and library changes.
Please use spotify_player: https://github.com/aome510/spotify-player, which is more feature-packed and more convenient.