Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test Server raises a HTTP 501 error when using Navidrome (subsonic) #98

Open
Clusters opened this issue Jul 26, 2024 · 7 comments
Open
Labels
enhancement New feature or request

Comments

@Clusters
Copy link

Clusters commented Jul 26, 2024

Hi memen45,
first I have to thank you for maintaining this app, I really appreciate it.

After deploying the workaround from #97 I made some more progress on the Test Server functionality.

First of all some notes to my server:

  • Navidrome (subsonic) media server (current version)
  • Reverse proxy present serving Let's Encrypt SSL on port 443
  • All playlist combined have a response size of 5,7KB
  • The first playlist contains a single mp3. The playlist response size is around 1,5KB

When testing my server with the Test Server button on my watch I get the progress bar to 50% and the last log message is "Inlog OK\nPlaylists good". After that I get a HTTP 501 error "Unknown error".
My assumption is that the playlist retrieve fails because Navidrome answers following on that response as it does not support podcasts yet:

> curl "https://myNavidrome.tld/rest/getPodcasts.view?v=1.10.2&c=subsonic&f=json&u=a_dummy_user&p=a_dummy_pw" This endpoint is not implemented, but may be in future releases

As you can see the REST response is not even in JSON format but a plain string.
I'm not sure why this could trigger a HTTP error instead of an internal exception, but I have not that insight into MonkeyC nor Garmin App development 😶

Thanks a lot in advance! Looking forward to use this app 💯

edit: Browsing playlists on the watch also leads to a HTTP 501 error

@Clusters Clusters changed the title Test Server raises a HTTP 501 error when using Navidrome Test Server raises a HTTP 501 error when using Navidrome (subsonic) Jul 26, 2024
@memen45
Copy link
Owner

memen45 commented Jul 26, 2024

Interesting! Thanks for your detailed report.

With regards to the first issue: I have never seen a server have some methods not implemented before for Subsonic. Subsonic normally responds with their own custom error codes inside a HTTP/200 response. However, 'Not implemented' is not one of the Subsonic errors. Therefore the HTTP/501 is probably a good choice here from the server and SubMusic should handle it gracefully to show Podcasts are not supported.
This could be improved (therefore adding enhancement label).

With regards to the second issue of not being able to browse playlists: could you check the /getPlaylist response? It could be Navidrome is missing implementations for more endpoints and therefore you receive the server error. The endpoints used for playlist discovery are /getPlaylists and getPlaylist.

@Clusters
Copy link
Author

Clusters commented Jul 26, 2024

I'm sorry, that was a typo. I totally meant "browsing podcasts" instead of "browsing playlists" in my hasty edit 🙈

/getPlaylists and /getPlaylist works as intended.
However, the /getPodcast (without "s") endpoint returns HTTP 404

@memen45
Copy link
Owner

memen45 commented Jul 26, 2024

Ah okay, so same issue as with Test Server. Could be gracefully handled by SubMusic instead of passing the error to the user.

@gitviola
Copy link

I'm facing the same issue and enabled logging. But I don't know how to find the logs, so I'm not able to provide more information on what exactly is happening in the background. Do you know how to open the log file? I'm on macos and already tried to connect to my Garmin Watch through OpenMTP but I don't manage to connect to it

@memen45
Copy link
Owner

memen45 commented Jul 28, 2024

Definitely check your server logs too. They might help me more than the app logs!

Garmin app logs can be found when mounting your watch as USB mass storage device, then open GARMIN/APPS/LOGS folder and look for TXT and BAK files. (TXT is the latest log file, BAK is the previous, so both may be interesting). Each app has a certain code as filename.

Make sure you disable debugging if possible during normal use, as it uses a lot of memory and can cause crashes when enabled.

@Clusters
Copy link
Author

JFYI:
Podcast issue might resolve itself in the near future as Navidrome seem to have an update for that in the future:
navidrome/navidrome#3150

@gitviola
Copy link

this fixed it for me #99 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants