chr56 / Phonograph_Plus

A fork of kabouzeid/Phonograph in maintenance and development
GNU General Public License v3.0
344 stars 19 forks source link

[Bug] warning `RuntimeException ( xxx has unresolved theme attributes)` in logcat at startup #188

Open eku opened 3 weeks ago

eku commented 3 weeks ago

Bug Summary

Taping an album cover in the artist view does nothing. Behind the scenes a java.lang.RuntimeException is thrown.

Version

1.7.1-beta1

Steps to reproduce the bug

  1. Select artist tab
  2. Select an artist with more than one album
  3. Tap on an album cover in the view
  4. Sometimes nothing happens and exception is thrown

Environment

LOS 21 (Android 14)

Screenshots or Screen recordings

No response

Other helpful information

Logcat output

06-08 15:24:13.015  2449  2559 V WindowManagerShell: Transition requested (#292): android.os.BinderProxy@607dd4b TransitionRequestInfo { type = OPEN, triggerTask = TaskInfo{userId=0 taskId=1618 displayId=0 isRunning=true baseIntent=Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=player.phonograph.plus.preview/player.phonograph.ui.activities.LauncherActivity } baseActivity=ComponentInfo{player.phonograph.plus.preview/player.phonograph.ui.activities.MainActivity} topActivity=ComponentInfo{player.phonograph.plus.preview/player.phonograph.ui.activities.AlbumDetailActivity} origActivity=null realActivity=ComponentInfo{player.phonograph.plus.preview/player.phonograph.ui.activities.LauncherActivity} numActivities=3 lastActiveTime=23515439 supportsMultiWindow=true resizeMode=1 isResizeable=true minWidth=-1 minHeight=-1 defaultMinSize=220 token=WCT{android.window.IWindowContainerToken$Stub$Proxy@9c84328} topActivityType=1 pictureInPictureParams=null shouldDockBigOverlays=false launchIntoPipHostTaskId=-1 lastParentTaskIdBeforePip=-1 displayCutoutSafeInsets=Rect(0, 113 - 0, 0) topActivityInfo=ActivityInfo{7aaf841 player.phonograph.ui.activities.AlbumDetailActivity} launchCookies=[] positionInParent=Point(0, 0) parentTaskId=-1 isFocused=true isVisible=true isVisibleRequested=true isSleeping=false locusId=null displayAreaFeatureId=1 isTopActivityTransparent=false appCompatTaskInfo=AppCompatTaskInfo { topActivityInSizeCompat=false topActivityEligibleForLetterboxEducation= false isLetterboxDoubleTapEnabled= false topActivityEligibleForUserAspectRatioButton= false topActivityBoundsLetterboxed= false isFromLetterboxDoubleTap= false topActivityLetterboxVerticalPosition= -1 topActivityLetterboxHorizontalPosition= -1 topActivityLetterboxWidth=-1 topActivityLetterboxHeight=-1 isUserFullscreenOverrideEnabled=false cameraCompatControlState=hidden}}, pipTask = null, remoteTransition = null, displayChange = null, flags = 0, debugId = 292 }
06-08 15:24:13.050 22002 22002 W Resources: Drawable player.phonograph.plus.preview:drawable/above_shadow has unresolved theme attributes! Consider using Resources.getDrawable(int, Theme) or Context.getDrawable(int).
06-08 15:24:13.050 22002 22002 W Resources: java.lang.RuntimeException
06-08 15:24:13.050 22002 22002 W Resources:     at android.content.res.Resources.getDrawable(Resources.java:916)
06-08 15:24:13.050 22002 22002 W Resources:     at com.sothree.slidinguppanel.SlidingUpPanelLayout.<init>(SourceFile:271)
06-08 15:24:13.050 22002 22002 W Resources:     at java.lang.reflect.Constructor.newInstance0(Native Method)
06-08 15:24:13.050 22002 22002 W Resources:     at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
06-08 15:24:13.050 22002 22002 W Resources:     at android.view.LayoutInflater.createView(LayoutInflater.java:742)
06-08 15:24:13.050 22002 22002 W Resources:     at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:894)
06-08 15:24:13.050 22002 22002 W Resources:     at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:849)
06-08 15:24:13.050 22002 22002 W Resources:     at android.view.LayoutInflater.inflate(LayoutInflater.java:543)
06-08 15:24:13.050 22002 22002 W Resources:     at android.view.LayoutInflater.inflate(LayoutInflater.java:462)
06-08 15:24:13.050 22002 22002 W Resources:     at zf.r.k(SourceFile:10)
06-08 15:24:13.050 22002 22002 W Resources:     at player.phonograph.ui.activities.AlbumDetailActivity.i(SourceFile:1)
06-08 15:24:13.050 22002 22002 W Resources:     at zf.r.onCreate(SourceFile:4)
06-08 15:24:13.050 22002 22002 W Resources:     at player.phonograph.ui.activities.AlbumDetailActivity.onCreate(SourceFile:165)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.Activity.performCreate(Activity.java:8767)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.Activity.performCreate(Activity.java:8745)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1519)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3928)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4126)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:108)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.servertransaction.TransactionExecutor.executeNonLifecycleItem(TransactionExecutor.java:195)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:157)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:90)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2544)
06-08 15:24:13.050 22002 22002 W Resources:     at android.os.Handler.dispatchMessage(Handler.java:107)
06-08 15:24:13.050 22002 22002 W Resources:     at android.os.Looper.loopOnce(Looper.java:232)
06-08 15:24:13.050 22002 22002 W Resources:     at android.os.Looper.loop(Looper.java:317)
06-08 15:24:13.050 22002 22002 W Resources:     at android.app.ActivityThread.main(ActivityThread.java:8501)
06-08 15:24:13.050 22002 22002 W Resources:     at java.lang.reflect.Method.invoke(Native Method)
06-08 15:24:13.050 22002 22002 W Resources:     at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
06-08 15:24:13.050 22002 22002 W Resources:     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:878)
06-08 15:24:13.054 22002 22002 V ReflectMenu: null cannot be cast to non-null type androidx.appcompat.view.menu.MenuPresenter.Callback
06-08 15:24:13.054  1229  1229 I BpBinder: onLastStrongRef automatically unlinking death recipients: 
06-08 15:24:13.056 22002 22002 V ReflectMenu: null cannot be cast to non-null type androidx.appcompat.view.menu.MenuPresenter.Callback
chr56 commented 3 weeks ago

The exception is thrown by SlidingUpPanelLayout, a very old library, which is used in Main Sliding Player. However, currently there is no any evidence that this exception causes serious troubles.

Deobfuscated stacktrace:

Drawable player.phonograph.plus.preview.debug:drawable/above_shadow has unresolved theme attributes! Consider using Resources.getDrawable(int, Theme) or Context.getDrawable(int).
                                           java.lang.RuntimeException
                                            at android.content.res.Resources.getDrawable(Resources.java:927)
                                            at com.sothree.slidinguppanel.SlidingUpPanelLayout.<init>(SlidingUpPanelLayout.java:334)
                                            at com.sothree.slidinguppanel.SlidingUpPanelLayout.<init>(SlidingUpPanelLayout.java:269)
                                            at java.lang.reflect.Constructor.newInstance0(Native Method)
                                            at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
                                            at android.view.LayoutInflater.createView(LayoutInflater.java:877)
                                            at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:1029)
                                            at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:984)
                                            at android.view.LayoutInflater.inflate(LayoutInflater.java:676)
                                            at android.view.LayoutInflater.inflate(LayoutInflater.java:544)
                                            at player.phonograph.databinding.SlidingMusicPanelLayoutBinding.inflate(SlidingMusicPanelLayoutBinding.java:58)
                                            at player.phonograph.ui.activities.base.AbsSlidingMusicPanelActivity.wrapSlidingMusicPanel(AbsSlidingMusicPanelActivity.kt:74)
                                            at player.phonograph.ui.activities.AlbumDetailActivity.createContentView(AlbumDetailActivity.kt:90)
                                            at player.phonograph.ui.activities.base.AbsSlidingMusicPanelActivity.onCreate(AbsSlidingMusicPanelActivity.kt:85)
                                            at player.phonograph.ui.activities.AlbumDetailActivity.onCreate(AlbumDetailActivity.kt:59)
                                            at android.app.Activity.performCreate(Activity.java:8757)
                                            at android.app.Activity.performCreate(Activity.java:8729)
                                            at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1475)
                                            at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3985)
                                            at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4161)
                                            at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:114)
                                            at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:144)
                                            at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:101)
                                            at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2627)
                                            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:8825)

or

Drawable player.phonograph.plus.preview.debug:drawable/above_shadow has unresolved theme attributes! Consider using Resources.getDrawable(int, Theme) or Context.getDrawable(int).
                                           java.lang.RuntimeException
                                            at android.content.res.Resources.getDrawable(Resources.java:927)
                                            at com.sothree.slidinguppanel.SlidingUpPanelLayout.<init>(SlidingUpPanelLayout.java:334)
                                            at com.sothree.slidinguppanel.SlidingUpPanelLayout.<init>(SlidingUpPanelLayout.java:269)
                                            at java.lang.reflect.Constructor.newInstance0(Native Method)
                                            at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
                                            at android.view.LayoutInflater.createView(LayoutInflater.java:877)
                                            at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:1029)
                                            at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:984)
                                            at android.view.LayoutInflater.inflate(LayoutInflater.java:676)
                                            at android.view.LayoutInflater.inflate(LayoutInflater.java:544)
                                            at player.phonograph.databinding.SlidingMusicPanelLayoutBinding.inflate(SlidingMusicPanelLayoutBinding.java:58)
                                            at player.phonograph.ui.activities.base.AbsSlidingMusicPanelActivity.wrapSlidingMusicPanel(AbsSlidingMusicPanelActivity.kt:74)
                                            at player.phonograph.ui.activities.MainActivity.createContentView(MainActivity.kt:159)
                                            at player.phonograph.ui.activities.base.AbsSlidingMusicPanelActivity.onCreate(AbsSlidingMusicPanelActivity.kt:85)
                                            at player.phonograph.ui.activities.MainActivity.onCreate(MainActivity.kt:87)
                                            at android.app.Activity.performCreate(Activity.java:8757)
                                            at android.app.Activity.performCreate(Activity.java:8729)
                                            at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1475)
                                            at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3985)
                                            at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4161)
                                            at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:114)
                                            at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:144)
                                            at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:101)
                                            at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2627)
                                            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:8825)