MMA constantly crashing on Android 11

Report bugs & feature requests for MediaMonkey for Android and learn about the newest beta build.

Moderator: Gurus

MCSmarties
Posts: 251
Joined: Tue Dec 06, 2005 8:01 pm

MMA constantly crashing on Android 11

Post by MCSmarties »

Hi I've been a Mediamonkey Gold user since version 2.5.4, never had major problems before. Just got a new phone and am at a loss what to do. MMA crashes extremely frequently (every minute or so), it is perfectly unusable.

Running MMA Pro 1.4.2.0945 on Xiaomi POCO F2 PRO 256GB running crDroid 7.2 based on Android 11 (MIUI V12.2.4.0.RJKMIXM). MMW Gold 4.1.29.1910.

I synched my phone with MMW over USB (playlist): 6141 MP3, 34.0GB.
Placed the tracks in /storage/emulated/0/Music.

Start MMA initiates library scan (turning circle), app often (not always) exits after 10-15 seconds. Rarely, the scan completes (turning circle stops) but going to "Folders" always shows exactly 2628 tracks in the library, less than half the correct number. Options -> check for new/changed media displays "Scanning started". Subsequently leaving the options menu ALWAYS leads to almost immediate app exit.

Using the MMA sync feature almost always fails; usually stops and returns to MMA home screen without error message. A few times it completed (I didn't try to actually sync new tracks, just check against the USB sync) and would end with "Everything is in sync". But there are still only 2628 tracks!

Playing a track stops usually within 30 seconds; track name turns gray but clicking on it in "Now playing" starts it again. Rinse and repeat.

I tried to several times to capture and send a debug log, but the app crashes too quickly to do so. I did however take a log with matlog. Lots of F/FuseDaemon(10372) fatal errors. I uploaded a portion of it on pastebin:

https://pastebin.com/ekUBuUfK

Thanks for any insight you can give!
Peke
Posts: 14186
Joined: Tue Jun 10, 2003 7:21 pm
Location: Serbia
Contact:

Re: MMA constantly crashing on Android 11

Post by Peke »

Hi,
Can you please use ⋮ -> About MediaMonkey -> Send Logs -> Write down log ID here in reply -> Press OK to send log.

When MM crashes and you restart it please repeat above steps to have LOG ID immediately after crash.

Send reply with above written LOG IDs here so that our MMA dev team can check for any other logs sent from your device model.
Best regards,
Peke
MediaMonkey Team lead QA/Tech Support guru
Admin of Free MediaMonkey addon Site HappyMonkeying
Image
Image
How to add SCREENSHOTS to forum
MCSmarties
Posts: 251
Joined: Tue Dec 06, 2005 8:01 pm

Re: MMA constantly crashing on Android 11

Post by MCSmarties »

Hi Peke,
Unfortunately I really cannot capture a MMA log: the app crashes too quickly. Whenever I go to "send log" the app exits within a second, much too quickly to even hit send.

However, I just managed to "fix" the problem! The "solution" (more of a hack, really) was to place a blank .nomedia file in the \sdcard\music folder. MMA works perfectly now, synchronizes 6000 songs without an issue. The downside is that only MMA will recognize the tracks anymore, no other media player will find any music on my phone. My hypothesis is that the problem is not with MMA per se but with the android media indexer (com.android.mediaprovider ?) that is somehow broken in my build.

Am I correct that MMA does not rely on the android media indexer but uses its own mechanism? That would explain why preventing android from indexing my files with the hack above solves the conflict.
martin.bohac
Posts: 187
Joined: Thu Nov 14, 2013 5:23 pm

Re: MMA constantly crashing on Android 11

Post by martin.bohac »

Hi MC,
the issue really seems to be on the System side, when
MediaProvider scans new files by scanFile method,
but this method fails and freezes.

It happens maybe due to a track with an invalid character (JNI DETECTED ERROR IN APPLICATION: input is not valid Modified UTF-8: illegal continuation byte 0x63),
unfortunately, I did not find which track is the cause.

So based on your log all processes that depend on MediaProvider are killed.
(Killing 10404:com.ventismedia.android.mediamonkey/u0a271 (adj 0): depends on provider com.android.providers.media.module/com.android.providers.media.MediaProvider in dying proc com.android.providers.media.module (adj -700))
...
Killing all processes referencing /storage/emulated/0

So your solution is working because the system media scanner skips this music folder and it avoids freeze on corrupted track.

If you are ok that your music files are visible in MMA only, then you can keep this solution at least to the next System update.

Or you can move and copy .nomedia to subfolders which are the most suspects. E.g from your log (which is not snipped?)
e.g.
[/storage/emulated/0/Music/World/Caribbean/Zouk, Biguine, Compas/Malavoi/1985 - Gram é gram/08. Ti-colibri.mp3,
/storage/emulated/0/Music/World/E

Great work on your side to find a solution.
Good luck!
MCSmarties
Posts: 251
Joined: Tue Dec 06, 2005 8:01 pm

Re: MMA constantly crashing on Android 11

Post by MCSmarties »

Very interesting that it might be about an invalid character. I have indeed a lot of "World music", notably with French and German characters.
I know, adding .nomedia is only a workaround, not a solution...

Some observations that may be helpful:
I am also running MMA on my old phone (LineageOS 14.1 based on Android 7.1.2). Synching the same playlist there works.

I went over my (unsnipped) logcat again and did find entries about two invalid characters:

Code: Select all

Abort message: 'JNI DETECTED ERROR IN APPLICATION: input is not valid Modified UTF-8: illegal continuation byte 0x72
    string: 'Carrère''
    input: '0x43 0x61 0x72 0x72 0xe8 <0x72> 0x65'
    in call to NewStringUTF
    from java.lang.String android.media.MediaMetadataRetriever.nativeExtractMetadata(int)'
and

Code: Select all

Abort message: 'JNI DETECTED ERROR IN APPLICATION: input is not valid Modified UTF-8: illegal continuation byte 0x63
    string: 'Déclic'
    input: '0x44 0xe9 <0x63> 0x6c 0x69 0x63'
    in call to NewStringUTF
    from java.lang.String android.media.MediaMetadataRetriever.nativeExtractMetadata(int)'
Above messages are if I select ANSI encoding, of course all other special characters are "wrong", e.g.
/storage/emulated/0/Music/World/Caribbean/Zouk, Biguine, Compas/Malavoi/1985 - Gram é gram/08. Ti-colibri.mp3

However if I change to UTF-8, the two strings above appear corrupted in the log:

Code: Select all

string: 'Carr貥'
(appears as 'CarrxE8re')

Code: Select all

string: 'D飬ic'
(appears as 'DxE9clic')

What is however really strange is that I did a search for these strings, they only appear in the lyrics not in filenames!!

Would there be any other way to test further than to delete all MP3 (again...) and synch in small packages until it fails? Tedious...
Post Reply