rive-app / rive-app/rive-android
Crash: crashing the app while came back to Rive View contain class.
Nobody has claimed this yet.
- Dominant language
- Kotlin
- Stars
- 538
- Forks
- 66
- PR merge metrics
- No merged PRs in 30d
Description
Scenario:
Activity A -> Activity B -> Activity C
Activity A contain rive view.
intent the screen from A to B without finish Activity A.
intent the screen from B to C , finish Activity B.
back button press from Activity C.
getting crash with log below:
android.renderscript.RSInvalidStateException: Calling RS with no Context active.
at android.renderscript.RenderScript.validate(RenderScript.java:1241)
at android.renderscript.Allocation.copyFrom(Allocation.java:992)
at com.github.mmin18.widget.AndroidStockBlurImpl.blur(AndroidStockBlurImpl.java:66)
at com.github.mmin18.widget.RealtimeBlurView.blur(RealtimeBlurView.java:233)
at com.github.mmin18.widget.RealtimeBlurView$1.onPreDraw(RealtimeBlurView.java:273)
at android.view.ViewTreeObserver.dispatchOnPreDraw(ViewTreeObserver.java:1093)
at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:3089)
at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1952)
at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:8171)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:972)
at android.view.Choreographer.doCallbacks(Choreographer.java:796)
at android.view.Choreographer.doFrame(Choreographer.java:731)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:957)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:223)
at android.app.ActivityThread.main(ActivityThread.java:7656)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)
2024-03-15 17:04:12.775 646-1748 TaskPersister system_process E File error accessing recents directory (directory doesn't exist?).
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the Activity A → B → C navigation sequence with the Rive view still in Activity A. Read the stack trace through AndroidStockBlurImpl.blur and RealtimeBlurView.onPreDraw, then inspect the Rive view and activity lifecycle behavior around returning to Activity A. Done means the navigation sequence no longer crashes with RSInvalidStateException.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, kotlin
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100