advplyr / audiobookshelf-app

Mobile application for Audiobookshelf
https://audiobookshelf.org
GNU General Public License v3.0
1.29k stars 173 forks source link

[Bug]: [ANDROID APP] Client app is unable to start streaming or downloading locally #761

Closed papastanb closed 1 year ago

papastanb commented 1 year ago

Hello, I'm having an issue when I whant to start a stream on my phone using the android app.

I can't tell how to reproduce because it is permanent and nothing particular has been done on the phone or the server recently.

When I log intoo abs with the app web socket connect normaly (using local ip for debug purpose). I choose my book and click on stream (got an haptic vribration from the phone when clicking on "stream") Nothing happen on the phone.

Here is what i've got from the server logs (trying to stream 3 times in a row):

2023-06-27 16:31:49 DEBUG [Server] User Online stan

2023-06-27 16:31:49 DEBUG [DB] Updated user: 1

2023-06-27 16:31:56 DEBUG [PlaybackSessionManager] "stan" starting direct play session for item "li_38jr1c4gx0kw28rx2s"

2023-06-27 16:32:06 INFO [PlaybackSessionManager] startSession: Closing open session "In Enemy Hands" for user "stan"

2023-06-27 16:32:06 DEBUG [PlaybackSessionManager] closeSession "play_3sfozv9tw5az13d80h"

2023-06-27 16:32:06 DEBUG [PlaybackSessionManager] Removed session "play_3sfozv9tw5az13d80h"

2023-06-27 16:32:06 DEBUG [PlaybackSessionManager] "stan" starting direct play session for item "li_38jr1c4gx0kw28rx2s"

2023-06-27 16:32:11 INFO [PlaybackSessionManager] startSession: Closing open session "In Enemy Hands" for user "stan"

2023-06-27 16:32:11 DEBUG [PlaybackSessionManager] closeSession "play_8q2is5gdhz5czmps4i"

2023-06-27 16:32:11 DEBUG [PlaybackSessionManager] Removed session "play_8q2is5gdhz5czmps4i"

2023-06-27 16:32:11 DEBUG [PlaybackSessionManager] "stan" starting direct play session for item "li_38jr1c4gx0kw28rx2s"

Then I try to download the book localy Got the download sucess message almost immediately

On the server side logs show:

2023-06-27 16:37:33 DEBUG [FfmpegHelpers] Resize Image Cmd: ffmpeg -i /metadata/items/li_38jr1c4gx0kw28rx2s/cover.jpg -y -vf scale=400:-1 /metadata/cache/covers/li_38jr1c4gx0kw28rx2s_400.jpeg

2023-06-27 16:37:33 DEBUG [FfmpegHelpers] Image resized Successfully

2023-06-27 16:37:33 DEBUG Not modifying permissions since no uid/gid is specified

When i try to play local files:

I've got the message "Playback Failed: Sources error"

If I try to play this book on webui it works.

Server logs:


2023-06-27 16:43:39 DEBUG [PlaybackSessionManager] closeSession "play_atp2s9mcl8j16ncwoa"

2023-06-27 16:43:39 DEBUG [PlaybackSessionManager] Removed session "play_atp2s9mcl8j16ncwoa"

2023-06-27 16:43:39 DEBUG [PlaybackSessionManager] "stan" starting direct play session for item "li_38jr1c4gx0kw28rx2s"

2023-06-27 16:43:44 DEBUG [PlaybackSessionManager] syncSession "play_y3aszelve5tgqjd71w" | Total Time Listened: 5

2023-06-27 16:43:44 DEBUG [DB] Updated user: 1

2023-06-27 16:43:44 DEBUG [DB] Inserted 1 session

2023-06-27 16:43:50 DEBUG [PlaybackSessionManager] syncSession "play_y3aszelve5tgqjd71w" | Total Time Listened: 11

2023-06-27 16:43:50 DEBUG [DB] Updated user: 1

2023-06-27 16:43:50 DEBUG [DB] Updated session: 1

2023-06-27 16:43:55 DEBUG [PlaybackSessionManager] syncSession "play_y3aszelve5tgqjd71w" | Total Time Listened: 16

2023-06-27 16:43:55 DEBUG [DB] Updated user: 1

2023-06-27 16:43:55 DEBUG [DB] Updated session: 1

2023-06-27 16:44:00 DEBUG [PlaybackSessionManager] syncSession "play_y3aszelve5tgqjd71w" | Total Time Listened: 21

2023-06-27 16:44:00 DEBUG [DB] Updated user: 1

2023-06-27 16:44:00 DEBUG [DB] Updated session: 1

2023-06-27 16:44:06 DEBUG [PlaybackSessionManager] syncSession "play_y3aszelve5tgqjd71w" | Total Time Listened: 27

2023-06-27 16:44:06 DEBUG [DB] Updated user: 1

2023-06-27 16:44:06 DEBUG [DB] Updated session: 1

2023-06-27 16:44:12 DEBUG [PlaybackSessionManager] syncSession "play_y3aszelve5tgqjd71w" | Total Time Listened: 32

2023-06-27 16:44:12 DEBUG [DB] Updated user: 1

2023-06-27 16:44:12 DEBUG [DB] Updated session: 1

2023-06-27 16:44:18 DEBUG [PlaybackSessionManager] syncSession "play_y3aszelve5tgqjd71w" | Total Time Listened: 38

2023-06-27 16:44:18 DEBUG [DB] Updated user: 1

2023-06-27 16:44:18 DEBUG [DB] Updated session: 1

Environment data

UnRaid Server: v6.12.1 ABS Server : v2.2.14 [Docker - UNRAID] Network: doing it locally for troubleshoot purpose

Audiobookshelf Version:

Server : v2.2.14 [UNRAID]

App version: 0.9.65-beta

Android Issue

Android version: ANDROID 13

Device model: Samsung Galaxy S21+ Model: SM-G996B/DS

Stock or customized system: One UI 5.1 (Samsung)

papastanb commented 1 year ago

Here is what I have done so far to troubleshoot:

On phone side:

On Server Side

advplyr commented 1 year ago

What version of the android app?

You should be using server version v2.2.23 https://github.com/advplyr/audiobookshelf-app/releases/tag/v0.9.65-beta

papastanb commented 1 year ago

App version: 0.9.65-beta

I haven't updated the server on unraid because the comunity app repro do not propose any updates.

Should I force it ?

papastanb commented 1 year ago

I've forced Server update to v2.2.23.

And problem done. Thanks for you help.