Skip to content

Application crashes when you tap a lot of times navigation back arrow #4986

Description

@miroslavaivanova

Tell us about the problem

Application crashes when you tap a lot of times navigation back arrow.

Which platform(s) does your issue occur on?

Android

Please provide the following version numbers that your issue occurs with:

  • CLI: rc
  • Cross-platform modules: rc
  • Plugin(s): nativescript-pro-ui: next

Please tell us how to recreate the issue in as much detail as possible.

Please, use the project: https://github.com/telerik/nativescript-ui-samples-angular
Run it and navigate to(for example): ListView/Selection/Single Selection. Tap back button 4 times and you will see the exception:

System.err: com.tns.NativeScriptException:
System.err: Calling js method run failed
System.err:
System.err: TypeError: Cannot read property 'resolvedPage' of undefined
System.err: File: "file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js, line: 142, column: 24
System.err:
System.err: StackTrace:
System.err: Frame: function:'FrameBase._onNavigatingTo', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/ui/frame/frame-common.js', line: 306, column: 23
System.err: Frame: function:'FrameBase.performGoBack', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/ui/frame/frame-common.js', line: 289, column: 14
System.err: Frame: function:'FrameBase._processNavigationContext', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/ui/frame/frame-common.js', line: 258, column: 18
System.err: Frame: function:'Frame._processNavigationContext', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/ui/frame/frame.js', line: 259, column: 52
System.err: Frame: function:'FrameBase._processNavigationQueue', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/ui/frame/frame-common.js', line: 225, column: 18
System.err: Frame: function:'Frame.setCurrent', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/ui/frame/frame.js', line: 83, column: 14
System.err: Frame: function:'', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/ui/frame/fragment.transitions.js', line: 523, column: 53
System.err: Frame: function:'ZoneDelegate.invokeTask', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 398, column: 31
System.err: Frame: function:'Zone.runTask', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 165, column: 47
System.err: Frame: function:'ZoneTask.invoke', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 460, column: 38
System.err: Frame: function:'timer', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 1634, column: 29
System.err: Frame: function:'invoke', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/timer/timer.js', line: 19, column: 48
System.err: Frame: function:'ZoneDelegate.invoke', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 365, column: 26
System.err: Frame: function:'Zone.runGuarded', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 138, column: 47
System.err: Frame: function:'', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 116, column: 29
System.err: Frame: function:'run', file:'file:///data/data/org.nativescript.sdkAngular/files/app/tns_modules/tns-core-modules/timer/timer.js', line: 23, column: 13
System.err:
System.err: at com.tns.Runtime.callJSMethodNative(Native Method)
System.err: at com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1088)
System.err: at com.tns.Runtime.callJSMethodImpl(Runtime.java:970)
System.err: at com.tns.Runtime.callJSMethod(Runtime.java:957)
System.err: at com.tns.Runtime.callJSMethod(Runtime.java:941)
System.err: at com.tns.Runtime.callJSMethod(Runtime.java:933)
System.err: at com.tns.gen.java.lang.Runnable.run(Runnable.java:10)
System.err: at android.os.Handler.handleCallback(Handler.java:751)
System.err: at android.os.Handler.dispatchMessage(Handler.java:95)
System.err: at android.os.Looper.loop(Looper.java:154)
System.err: at android.app.ActivityThread.main(ActivityThread.java:6077)
System.err: at java.lang.reflect.Method.invoke(Native Method)
System.err: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:865)
System.err: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:755)
ActivityManager: Process org.nativescript.sdkAngular (pid 31522) has died
ActivityManager: cleanUpApplicationRecord -- 31522

Activity

  1. jogboms commented on Nov 2, 2017

    @jogboms

    My attention was pointed to this same error on one of my apps too. Is there any way to work around this?

  2. hshristov commented on Nov 9, 2017

    @hshristov
    Contributor

    @miroslavaivanova Is this issue still reproducible?

  3. hshristov commented on Dec 15, 2017

    @hshristov
    Contributor

    @jogboms This should be fixed in master branch and will be included in 3.4
    @miroslavaivanova Can you please confirm master branch is OK and close the issue if it is?

    Thanks

  4. added this to the 3.4 milestone on Dec 20, 2017
  5. ghost removed on Dec 20, 2017
  6. BasyaLipman commented on Feb 4, 2018

    @BasyaLipman

    @hshristov - I have NS version 1.3.4 and my app is crashing on Android when I navigate around and then hit the back button multiple times quickly.

    Here's the error I'm getting, could it be there is still an issue here?

    com.tns.NativeScriptException: Calling js method run failed TypeError: Cannot read property '_callbacks' of null File: "file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js, line: 142, column: 24 StackTrace: Frame: function:'getFragmentCallbacks', file:'file:///data/data/com.x.y/files/app/tns_modules/tns-core-modules/ui/frame/fragment.transitions.js', line: 27, column: 20 Frame: function:'', file:'file:///data/data/com.x.y/files/app/tns_modules/tns-core-modules/ui/frame/fragment.transitions.js', line: 521, column: 60 Frame: function:'ZoneDelegate.invokeTask', file:'file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 398, column: 31 Frame: function:'Zone.runTask', file:'file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 165, column: 47 Frame: function:'ZoneTask.invoke', file:'file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 460, column: 38 Frame: function:'timer', file:'file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 1634, column: 29 Frame: function:'invoke', file:'file:///data/data/com.x.y/files/app/tns_modules/tns-core-modules/timer/timer.js', line: 19, column: 48 Frame: function:'ZoneDelegate.invoke', file:'file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 365, column: 26 Frame: function:'Zone.runGuarded', file:'file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 138, column: 47 Frame: function:'', file:'file:///data/data/com.x.y/files/app/tns_modules/nativescript-angular/zone-js/dist/zone-nativescript.js', line: 116, column: 29 Frame: function:'run', file:'file:///data/data/com.x.y/files/app/tns_modules/tns-core-modules/timer/timer.js', line: 23, column: 13

    Related? Ideas?

    Thanks!

  7. hshristov commented on Feb 4, 2018

    @hshristov
    Contributor

    @BasyaLipman Please double check that you have the latest version of tns-core-modules. Also check that dependencies are also updated and points to the new modules (for examples you don't have old angular dependency which points to older modules).

  8. BasyaLipman commented on Feb 5, 2018

    @BasyaLipman

    @hshristov - that seems to have worked. Also deleted the node_modules, package.lock.json, hooks folder and platforms, then rebuilt and ran the app, and all is well. 👍

  9. lock commented on Aug 27, 2019

    @lock

    This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

  10. locked and limited conversation to collaborators on Aug 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions