mirror of
https://github.com/jpochyla/psst.git
synced 2026-04-27 07:25:52 +03:00
[GH-ISSUE #461] No playlist on psst-gui and failed to read json error #289
Labels
No labels
api
bug
build
documentation
duplicate
enhancement
good first issue
help wanted
idea
invalid
linux
lowprio
macos
pull-request
upstream
windows
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/psst#289
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 @slovanos on GitHub (Mar 21, 2024).
Original GitHub issue: https://github.com/jpochyla/psst/issues/461
Bug description: There is no playlist menu.
Error shown on the gui:
"failed to read JSON"
Error shown on the terminal:
ERROR psst_gui::webapi::client] failed to read local tracks: No such file or directory (os error 2)
To Reproduce
Simple open the app with ./psst-gui
Environment
OS: Linux Mint 21
@mackcoding commented on GitHub (Mar 22, 2024):
I am having the same issue. I get an error saying network timed out, and it gives an api url. I can't see anything that would be pulled with the API.
This started out of nowhere. I'm able to access the API directly with no issue, so I don't believe it's a network issue. This started yesterday (3/21/24).
Spot works with no issue.
@peorth80 commented on GitHub (Mar 22, 2024):
Same issue here! Probably the JSON changed

@mackcoding commented on GitHub (Mar 22, 2024):
I'm not even getting that far:

@nicolasf commented on GitHub (Mar 25, 2024):
Similar issue here on MacOS.
In my case the file exists but is not what's expected.
The odd thing is that the file it's trying to load with local : load_tracks_for_user has some content that is unrelated to Spotify or PSST. I have no idea why.
It starts with "SPCOLocalFilesStoraged` " and continues with data unrelated to Spotify.
@dylannorthrup commented on GitHub (Mar 28, 2024):
I attempted to add some debugging in the "make request" code path, but I am not a rust programmer so it is possible/likely I did something incorrectly.
After adding
log::info!(...)bits and various values ofexport PSST_LOG=debug,function=trace, I could see requests initiated fromget_playlistsand dispatched tofor_all_pageswhich callsself.loadthat callsureq::Response.into_json. Becauseinto_jsonconsumes the contents of the response, it's non-obvious how to log the contents of the request and have that request used by thepsst-guiclient.Unlike @mackcoding, it seems I'm able to get a response, but there's something about the returned JSON that
psst-guidoes not like. Happy to re-run if someone can provide a way to simultaneously log the response (or print to STDOUT) and have it used bypsst, but since isrustis outside my area of knowledge, I'll need someone else to provide the code for it (or point to an example of it elsewhere).@kingosticks commented on GitHub (Mar 28, 2024):
Recently (few weeks back) Spotify changed the format of some of their responses so that empty lists return 'null' instead of being actual empty lists like they are supposed to be. I had to change my (python) app to handle that, maybe you're hitting the same thing here.
The other problem in this thread appears to be the different case of where they turned off one of their undocumented (private) endpoints. I did see someone with a workaround for that but I helpfully can't find it now. I don't use the undocumented endpoints myself (in a futile attempt to avoid Spotify breaking my app all the time with their stupid random changes).
@nicolasf commented on GitHub (Mar 30, 2024):
Took a stab at fixing the error based on this info from @kingosticks (thanks!).
Here's a PR: https://github.com/jpochyla/psst/pull/464
Tested locally and it looks good to me, but I'm not familiar with Rust, so please review it :).
@kingosticks commented on GitHub (Apr 1, 2024):
Regarding the other problem, with endpoints being removed (made-for-x etc), I found the related issue I was looking for: https://github.com/michaelherger/Spotty-Plugin/issues/117
I'm not sure if the fix they used there is directly relevant here, I don't personally use either software. But maybe it helps.