asksven / BetterBatteryStats

An attempt to provide advanced battery stats for Android
618 stars 156 forks source link

Fallback to 'since boot', No stats have been collected #913

Open Titanspark21 opened 1 year ago

Titanspark21 commented 1 year ago

Hello, I bought this 2 days ago off the google play store for my rooted s21 ultra exynos running one ui 5.0. 99% of the time the app isn't working and all I see is "no stats have been collected yet" even tho the app has been running for days. It had worked once and I've been able to see stats but not since.

What am I doing wrong or is the app broken?

Screenshot_20230306_145938

Screenshot_20230306_145958

lazymonkey2 commented 1 year ago

you're doing nothing wrong. it's a bug. the exact same thing happens to me too, with identical error.

DARK7BEA5T commented 8 months ago

@asksven any solution to this? i am getting this too. please help.

birdie-github commented 6 months ago

Could be a dupe of #912.

I'm facing the same issue under Android 14.

Trying to view Raw Stats results in the BatteryInfo service could not be contacted error.

The stack trace contains this:

Build.VERSION.RELEASE: 14
Build.VERSION.SDK_INT: 34

FAILURE: an unhandled exception occured

STACK TRACE
java.lang.ClassNotFoundException: Didn't find class "com.android.internal.os.BatteryStatsImpl" on path: DexPathList[[zip file "/data/app/~~UsCdQFywa-ycqvYW_Yp_iA==/com.asksven.betterbatterystats-alguMv4GXJ2dR5v7BKKRaQ==/base.apk"],nativeLibraryDirectories=[/data/app/~~UsCdQFywa-ycqvYW_Yp_iA==/com.asksven.betterbatterystats-alguMv4GXJ2dR5v7BKKRaQ==/lib/arm64, /system/lib64, /system_ext/lib64]]
    at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:259)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
    at com.asksven.betterbatterystats.DiagnosticsActivity.diagGetService(DiagnosticsActivity.java:121)
    at com.asksven.betterbatterystats.DiagnosticsActivity.onResume(DiagnosticsActivity.java:95)
    at android.app.Instrumentation.callActivityOnResume(Instrumentation.java:1622)
    at android.app.Activity.performResume(Activity.java:8916)
    at android.app.ActivityThread.performResumeActivity(ActivityThread.java:5264)
    at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:5325)
    at android.app.servertransaction.ResumeActivityItem.execute(ResumeActivityItem.java:64)
    at android.app.servertransaction.ActivityTransactionItem.execute(ActivityTransactionItem.java:45)
    at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:185)
    at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:103)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2630)
    at android.os.Handler.dispatchMessage(Handler.java:106)
    at android.os.Looper.loopOnce(Looper.java:257)
    at android.os.Looper.loop(Looper.java:368)
    at android.app.ActivityThread.main(ActivityThread.java:8832)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:572)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1049)
derei commented 3 weeks ago

Same here on Android 14, GrapheneOS. The app won’t collect any stats, except showing the CPU States.

All permissions granted, but there is this error:

STATUS: Failed: Didn't find class
‘com.android.internal.os.BatteryStatsimpl"
on path: DexPathList[[zip file "/data/app/
~~ghxhYebd-1xsev54sjruFg==/com.asksven.be
tterbatterystats-K3UladG1djqrQPBumuVQug==/
base.apk"|],nativeLibraryDirectories=[/data/app/
~~ghxhYebd-1xsev54sjruFg==/com.asksven.betterbatteryst
ats-K3UladG1djgrQPBumuVQvg==/lib/armé64, /system/lib64, /
system_ext/lib64]]

BBS Permisions