siper / Youamp

Material You android player for subsonic music stream servers written with jetpack compose
MIT License
81 stars 3 forks source link

Not able to play when using self hosted navidrome server #219

Open accforgithubtest opened 1 month ago

accforgithubtest commented 1 month ago

I have a self-hosted navidrome server, which I am able to access via browser and listen to music. I added the same server to youamp app, and I am able to see the albums / songs listed.

However I am unable to play any music, and nothing happens when I click Play / Play All, and I do not see any album art images for all songs/artists/etc as well.

This server is using a self-signed certificate - could that be causing any issues ? I was able to successfully login successfully, without any issues because of the self-signed certificate, so not sure what the issue could be.

The latest version of the app installed from f-droid store.

siper commented 1 month ago

Hello, thanks you for reply. Can you play songs from official navidrome demo server, connection info here?

siper commented 1 month ago

I test it on my own instance of navidrome and it works well. Maybe your instance have special settings or you try play unusual media types? Try to turn on/off transcoding in navidrome player settings. image image image

accforgithubtest commented 1 month ago

thank you for your detailed reply @siper !

  1. I am able to successfully play the songs from demo server using youamp on my phone.
  2. On my navidrome server, I only have mp3 and flac formats, no other special media types. I only have a default installation of navidrome, I did not modify any settings on the server.
  3. The transcoding settings on navidrome server was already blank. I tried to change it to mp3 and save it, then back to blank and save it for the "Youamp [okhttp]" player. Max bitrate is also displaying "-". This did not help and I am still having the same issues.

Can you help me understand -

  1. Self-signed certificates - You have mentioned above that your own navidrome server works fine - does your personal navidrome server use self-signed certificates ? and does it serve over https and not via http ?
  2. Does youamp try to download the audio file before playing it ? I check the permissions on the android app settings and it says "no permissions". Should the app have access to any files/folder/media on the android settings ?
siper commented 1 month ago
  1. No, it's not self signed certificate issue. You can't login, when it's be.
  2. Youamp not uses write permissions, it's play music as stream from url.
accforgithubtest commented 1 month ago

Thanks for the reply.

Do you have any suggestions for me on what to check next ? Is there any suggestion forhow to send you any logs from the app that can help to check the issue further ?

siper commented 1 month ago

Latest Youamp version does't collect any logs or personal data. Maybe in future, I make an option for it. Maybe you can try other selfhosted music stream servers? Like gonic or airsonic-advanced. If you have same error, you can give me an example media file, which not plays, I'll try it on my own instance.

accforgithubtest commented 4 weeks ago

Thank you for your reply.

I am able to confirm that the issue is definitely in scenarios where a self-signed certificate is being used for https in a self-hosted navidrome set-up.

I removed the self signed certificate, and set up my navidrome server to use only via http and not https. Then YouAmp is working properly. Once I put the self-signed certificate and https back, then the issue is seen again.

No, it's not self signed certificate issue. You can't login, when it's be.

It looks like the app is somehow allowing the login when self-signed certificates are being used for https, but then runs into issues during the playback.

siper commented 4 weeks ago

Hello, thanks for you research. I understand the problem. ExoPlayer uses it's own instance of http client, and it not allow self signed certificates. I have a question for you: do you install you self signed certificate in you system?

accforgithubtest commented 4 weeks ago

Yes, on my phone I have installed the rootCA for the self signed certificate. On Android TV, Fire TV (newer) does not have the option to install self signed certificates.

If there is a option to skip cert authority validations, that would be ideal.

Kobaratz commented 3 weeks ago

Just wanted to add I have the same issue.

Tested HTTP (ip:port) and no issues. Self signed with HTTPs shows the albums and song names, but wont play the music.

Also installed self signed certificates on my android device

siper commented 3 weeks ago

@accforgithubtest @Kobaratz hello. I published version 1.0.1, that should work, when root CA installed in you system. Can you test it?

Kobaratz commented 2 weeks ago

Apologies for a bit of a late reply, It works for me! Thanks so much @siper !!