7

My android app is filling up the logs with messages like this (making logcat almost useless):

W ResourceType: For resource 0x7f1001b5, entry index(437) is beyond type entryCount(157)

The resource ID changes from line to line, as well as the index and entryCount numbers.

This issue only happens on release builds. I know it happens on Android 7.0, 7.1, and 8.0. I have seen some logcats from Android 10 where I do not have the issue.

My app targets sdk 30, with minSdk 24. I have multiDexEnabled true. Compile with Java 8 (1.8). Written 100% in Kotlin.

There are some similar questions, without any answers that work for me, here, and here, and here

I tried aapt dump --values resources myAPK.apk > c:\my-res.txt mentioned in one of the answers which gives me enough info that I can see it has to do with theme I'm using, which is Theme.AppCompat.DayNight.NoActionBar

I already set vectorDrawables.useSupportLibrary = true in gradle

I don't know where to look or what to try from here.

Any pointers on how I might be able to fix it so I don't get those entries in my log?

Update: I have not confirmed a 100% but it seems this only happens to apps installed through Play Store that are uploaded by .aab file. When I upload .apk I'm starting to think the issue is gone. But I'll need to wait a bit longer and make sure.

TimB
  • 493
  • 3
  • 16
  • Just filter them out with a custom logcat filter; problem solved. – Martin Zeitler Mar 13 '21 at 11:39
  • @MartinZeitler if there were a dozen or 2 lines it would work, but there are so many that I am actually losing important logs. In some cases, in just a matter of seconds there's thousands of those logs. So filtering them out is useless because I still don't get what I need – TimB Mar 13 '21 at 16:15
  • When I send updates to Play Store with .apk instead of .aab I no longer have this issue. But that fix will not work for too long because Google is phasing out being able to upload .apk files. – TimB May 12 '21 at 16:58
  • 1
    The same issue on Android 7.0 and other mentioned versions. Any solution? – Vitaly Dec 01 '21 at 05:28

0 Answers0