GithubHelp home page GithubHelp logo

Comments (4)

ashutoshgngwr avatar ashutoshgngwr commented on May 27, 2024 1

#12 works on Android Pie emulator but not on a physical device. Needs more work!
The origin of the bug is in AboutPage dependency which is implicitly trying to change Day and Night mode configuration on the fragment ultimately causing the activity to be recreated. Activity recreation causes SoundLibraryFragment to be recreated in background which means it won't initialize its views. Service is rebound to it and RecyclerView's adapter is refreshed when RecyclerView wasn't initialized.

This is also likely to happen with PresetFragment which also uses similar pattern.

from android-app.

ashutoshgngwr avatar ashutoshgngwr commented on May 27, 2024 1

I went through the source code of AboutPage. It does not seem to be causing the problem. Since I do not have a physical device with Android Pie and there is no other way to reproduce this behaviour, I did a workaround to avoid crash (#15). I'll leave this open until the exact origin of this bug is pinpointed and fixed.

from android-app.

ashutoshgngwr avatar ashutoshgngwr commented on May 27, 2024 1

I am closing this. I give up. 😓
The workaround works. End of STORY!

from android-app.

ashutoshgngwr avatar ashutoshgngwr commented on May 27, 2024

Corresponding stacktrace

kotlin.UninitializedPropertyAccessException: 
  at com.github.ashutoshgngwr.noice.fragment.SoundLibraryFragment.getMRecyclerView (SoundLibraryFragment.java)
  at com.github.ashutoshgngwr.noice.fragment.SoundLibraryFragment$mServiceConnection$1.onServiceConnected (SoundLibraryFragment.java)
  at android.app.LoadedApk$ServiceDispatcher.doConnected (LoadedApk.java:1725)
  at android.app.LoadedApk$ServiceDispatcher$RunConnection.run (LoadedApk.java:1757)
  at android.os.Handler.handleCallback (Handler.java:873)
  at android.os.Handler.dispatchMessage (Handler.java:99)
  at android.os.Looper.loop (Looper.java:193)
  at android.app.ActivityThread.main (ActivityThread.java:6762)
  at java.lang.reflect.Method.invoke (Method.java)
  at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:493)
  at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:858)

from android-app.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.