After update Nativescript Cli 3.2.1- Unfortunately app has stopped occurred!


#1

I have updated my app to Cli version 3.2.1 from Cli 3.0.3. After updated the tns-core-modules/platfroms to up to date.
I tried to build the app, Its won’t build and result with some errors on console. Then tried with suggestions from this similar github issue.

This time app builds successfully and splashscreen loaded then end up with " Unfortunately, app has stopped " in device. I was tested with android platform.

FYI,
Console -

PS D:\IRI_Laptop\IRI_Latest\AuditAppMobile> tns run android
Searching for devices...
Executing before-liveSync hook from D:\IRI_Laptop\IRI_Latest\AuditAppMobile\hooks\before-liveSync\nativescript-a
ngular-sync.js
Executing before-prepare hook from D:\IRI_Laptop\IRI_Latest\AuditAppMobile\hooks\before-prepare\nativescript-dev
-typescript.js
Found peer TypeScript 2.2.2
Preparing project...
Project successfully prepared (Android)
Refreshing application...
Successfully synced application org.nativescript.IFS on device 3004c567d59f1200.
Executing before-watch hook from D:\IRI_Laptop\IRI_Latest\AuditAppMobile\hooks\before-watch\nativescript-dev-typ
escript.js
Found peer TypeScript 2.2.2
ActivityManager: Permission Denial: getCurrentUser() from pid=9868, uid=13897 requires android.permission.INTERA
CT_ACROSS_USERS
System.err: java.lang.RuntimeException: Unable to create application com.tns.NativeScriptApplication: com.tns.Na
tiveScriptException:
System.err: Error calling module function
System.err: Error calling module function
System.err: Error calling module function
System.err: Error calling module function
System.err: Error calling module function
System.err: Error calling module function
System.err: Error: com.tns.NativeScriptException: Failed to find module: "ui/core/proxy", relative to: app/tns_m
odules/
System.err:     com.tns.Module.resolvePathHelper(Module.java:146)
System.err:     com.tns.Module.resolvePath(Module.java:55)
System.err:     com.tns.Runtime.runModule(Native Method)
System.err:     com.tns.Runtime.runModule(Runtime.java:530)
System.err:     com.tns.Runtime.run(Runtime.java:522)
System.err:     com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
System.err:     android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1013)
System.err:     android.app.ActivityThread.handleBindApplication(ActivityThread.java:4730)
System.err:     android.app.ActivityThread.access$1600(ActivityThread.java:175)
System.err:     android.app.ActivityThread$H.handleMessage(ActivityThread.java:1368)
System.err:     android.os.Handler.dispatchMessage(Handler.java:102)
System.err:     android.os.Looper.loop(Looper.java:146)
System.err:     android.app.ActivityThread.main(ActivityThread.java:5602)
System.err:     java.lang.reflect.Method.invokeNative(Native Method)
System.err:     java.lang.reflect.Method.invoke(Method.java:515)
System.err:     com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
System.err:     com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
System.err:     dalvik.system.NativeStart.main(Native Method)
System.err: File: "<unknown>, line: 1, column: 265
System.err: StackTrace:
System.err:     Frame: function:'require', file:'', line: 1, column: 266
System.err:     Frame: function:'', file:'file:///data/data/org.nativescript.IFS/files/app/tns_modules/nati
vescript-bottombar/src/common.js', line: 4, column: 15
System.err:     Frame: function:'require', file:'', line: 1, column: 266
System.err:     Frame: function:'', file:'file:///data/data/org.nativescript.IFS/files/app/tns_modules/nati
vescript-bottombar/bottombar.js', line: 6, column: 10
System.err:     Frame: function:'require', file:'', line: 1, column: 266
System.err:     Frame: function:'', file:'file:///data/data/org.nativescript.IFS/files/app/audit/ism/vessel
comdetails.js', line: 32, column: 32
System.err:     Frame: function:'require', file:'', line: 1, column: 266
System.err:     Frame: function:'', file:'file:///data/data/org.nativescript.IFS/files/app/app.routing.js',
 line: 7, column: 26
System.err:     Frame: function:'require', file:'', line: 1, column: 266
System.err:     Frame: function:'', file:'file:///data/data/org.nativescript.IFS/files/app/app.module.js',
line: 5, column: 21
System.err:     Frame: function:'require', file:'', line: 1, column: 266
System.err:     Frame: function:'', file:'file:///data/data/org.nativescript.IFS/files/app/main.js', line:
5, column: 20
System.err:     Frame: function:'require', file:'', line: 1, column: 266
System.err: Error: com.tns.NativeScriptException: Failed to find module: "ui/core/proxy", relative to: app/tns_m
odules/
System.err:     com.tns.Module.resolvePathHelper(Module.java:146)
System.err:     com.tns.Module.resolvePath(Module.java:55)
System.err:     com.tns.Runtime.runModule(Native Method)
System.err:     com.tns.Runtime.runModule(Runtime.java:530)
System.err:     com.tns.Runtime.run(Runtime.java:522)
System.err:     com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
System.err:     android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1013)
System.err:     android.app.ActivityThread.handleBindApplication(ActivityThread.java:4730)
System.err:     android.app.ActivityThread.access$1600(ActivityThread.java:175)
System.err:     android.app.ActivityThread$H.handleMessage(ActivityThread.java:1368)
System.err:     android.os.Handler.dispatchMessage(Handler.java:102)
System.err:     android.os.Looper.loop(Looper.java:146)
System.err:     android.app.ActivityThread.main(ActivityThread.java:5602)
System.err:     java.lang.reflect.Method.invokeNative(Native Method)
System.err:     java.lang.reflect.Method.invoke(Method.java:515)
System.err:     com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
System.err:     com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
System.err:     dalvik.system.NativeStart.main(Native Method)
System.err: File: "<unknown>, line: 1, column: 265
System.err: StackTrace:

After update if i tried with new angular sample project its works as expected.

Please suggest! What i did wrong?


Application Cache Error event: Manifest fetch failed (-1)
#2

Try to reinstall all node packages, with a npm clean beforehand.

Also, what is the device that this is occurring on?


#3

First thing to try is deleting both the node_modules and platforms directory.


#4

Hey @Pete.K,

I have done below steps,
1.Manually deleted node_modules folder
2.npm cache clean
3.tns run android

This time cannot find module errors occurred!
So i did,
4.npm install tns-core-modules@latest --save

Then again Unfortunately app has stopped occurred!

And i left my testing device in office…I will let you know later about device.


#5

I have tried with deleting the hooks, node_modules and platforms directory. Then tried with tns run android. Again same issue occurred.

Unfortunately app has stopped occurred!


#6

Device - Samsung GALAXY Tab4


#7

It would help if you shared your ADB LOGCAT, so we get a better idea on what’s causing that.


#8

ADB LOGCAT-

Here you can find my app’s logcat.


#9

@Pete.K this issue seems to be related to nativescript-bottombar plugin version which i used in my project.

FYI, As discussed on this github issue here.

As @NickIliev suggested, i have to try with previous version of plugin/need to wait until upcoming fix of the plugin.

Thanks for your support @Pete.K and @SP1966.


#10

As @NickIliev suggested, nativescript-bottombar plugin version 3.0.5 are for sure compatible with NativeScript 3.x.x.

I have tried and tested. So nativescript-bottombar@3.0.5 works as expected with NativeScript Cli version 3.2.1.