Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: com.tns.NativeScriptException: Failed to find module: "./app/modules/core/index", relative to: app/ #486

Open
Shailendra420 opened this issue May 8, 2018 · 1 comment

Comments

@Shailendra420
Copy link

I cloned the angular-seed-advanced repo, ran npm install on ubuntu. The web part is working fine but the mobile app(nativescript) part is not.
I just ran npm run start.android.device in the root directory and I get the following error in my mobile device:

An uncaught Exception occurred on "main" thread.
java.lang.RuntimeException: Unable to create application com.tns.NativeScriptApplication: com.tns.NativeScriptException: 

Error calling module function 

Error calling module function 

Error: com.tns.NativeScriptException: Failed to find module: "./app/modules/core/index", relative to: app/
    com.tns.Module.resolvePathHelper(Module.java:146)
    com.tns.Module.resolvePath(Module.java:55)
    com.tns.Runtime.runModule(Native Method)
    com.tns.Runtime.runModule(Runtime.java:530)
    com.tns.Runtime.run(Runtime.java:522)
    com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
    android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1012)
    android.app.ActivityThread.handleBindApplication(ActivityThread.java:4586)
    android.app.ActivityThread.access$1600(ActivityThread.java:154)
    android.app.ActivityThread$H.handleMessage(ActivityThread.java:1378)
    android.os.Handler.dispatchMessage(Handler.java:102)
    android.os.Looper.loop(Looper.java:135)
    android.app.ActivityThread.main(ActivityThread.java:5296)
    java.lang.reflect.Method.invoke(Native Method)
    java.lang.reflect.Method.invoke(Method.java:372)
    com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
    com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)
File: "<unknown>, line: 1, column: 265

StackTrace: 
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/native.module.js', line: 18, column: 15
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/app.js', line: 6, column: 23
	Frame: function:'require', file:'', line: 1, column: 266


Error: com.tns.NativeScriptException: Failed to find module: "./app/modules/core/index", relative to: app/
    com.tns.Module.resolvePathHelper(Module.java:146)
    com.tns.Module.resolvePath(Module.java:55)
    com.tns.Runtime.runModule(Native Method)
    com.tns.Runtime.runModule(Runtime.java:530)
    com.tns.Runtime.run(Runtime.java:522)
    com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
    android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1012)
    android.app.ActivityThread.handleBindApplication(ActivityThread.java:4586)
    android.app.ActivityThread.access$1600(ActivityThread.java:154)
    android.app.ActivityThread$H.handleMessage(ActivityThread.java:1378)
    android.os.Handler.dispatchMessage(Handler.java:102)
    android.os.Looper.loop(Looper.java:135)
    android.app.ActivityThread.main(ActivityThread.java:5296)
    java.lang.reflect.Method.invoke(Native Method)
    java.lang.reflect.Method.invoke(Method.java:372)
    com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
    com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)
File: "<unknown>, line: 1, column: 265

StackTrace: 
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/native.module.js', line: 18, column: 15
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/app.js', line: 6, column: 23
	Frame: function:'require', file:'', line: 1, column: 266


Error: com.tns.NativeScriptException: Failed to find module: "./app/modules/core/index", relative to: app/
    com.tns.Module.resolvePathHelper(Module.java:146)
    com.tns.Module.resolvePath(Module.java:55)
    com.tns.Runtime.runModule(Native Method)
    com.tns.Runtime.runModule(Runtime.java:530)
    com.tns.Runtime.run(Runtime.java:522)
    com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
    android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1012)
    android.app.ActivityThread.handleBindApplication(ActivityThread.java:4586)
    android.app.ActivityThread.access$1600(ActivityThread.java:154)
    android.app.ActivityThread$H.handleMessage(ActivityThread.java:1378)
    android.os.Handler.dispatchMessage(Handler.java:102)
    android.os.Looper.loop(Looper.java:135)
    android.app.ActivityThread.main(ActivityThread.java:5296)
    java.lang.reflect.Method.invoke(Native Method)
    java.lang.reflect.Method.invoke(Method.java:372)
    com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
    com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)
File: "<unknown>, line: 1, column: 265

StackTrace: 
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/native.module.js', line: 18, column: 15
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/app.js', line: 6, column: 23
	Frame: function:'require', file:'', line: 1, column: 266


	at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4589)
	at android.app.ActivityThread.access$1600(ActivityThread.java:154)
	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1378)
	at android.os.Handler.dispatchMessage(Handler.java:102)
	at android.os.Looper.loop(Looper.java:135)
	at android.app.ActivityThread.main(ActivityThread.java:5296)
	at java.lang.reflect.Method.invoke(Native Method)
	at java.lang.reflect.Method.invoke(Method.java:372)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)
Caused by: com.tns.NativeScriptException: 

Error calling module function 

Error calling module function 

Error: com.tns.NativeScriptException: Failed to find module: "./app/modules/core/index", relative to: app/
    com.tns.Module.resolvePathHelper(Module.java:146)
    com.tns.Module.resolvePath(Module.java:55)
    com.tns.Runtime.runModule(Native Method)
    com.tns.Runtime.runModule(Runtime.java:530)
    com.tns.Runtime.run(Runtime.java:522)
    com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
    android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1012)
    android.app.ActivityThread.handleBindApplication(ActivityThread.java:4586)
    android.app.ActivityThread.access$1600(ActivityThread.java:154)
    android.app.ActivityThread$H.handleMessage(ActivityThread.java:1378)
    android.os.Handler.dispatchMessage(Handler.java:102)
    android.os.Looper.loop(Looper.java:135)
    android.app.ActivityThread.main(ActivityThread.java:5296)
    java.lang.reflect.Method.invoke(Native Method)
    java.lang.reflect.Method.invoke(Method.java:372)
    com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
    com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)
File: "<unknown>, line: 1, column: 265

StackTrace: 
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/native.module.js', line: 18, column: 15
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/app.js', line: 6, column: 23
	Frame: function:'require', file:'', line: 1, column: 266


Error: com.tns.NativeScriptException: Failed to find module: "./app/modules/core/index", relative to: app/
    com.tns.Module.resolvePathHelper(Module.java:146)
    com.tns.Module.resolvePath(Module.java:55)
    com.tns.Runtime.runModule(Native Method)
    com.tns.Runtime.runModule(Runtime.java:530)
    com.tns.Runtime.run(Runtime.java:522)
    com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
    android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1012)
    android.app.ActivityThread.handleBindApplication(ActivityThread.java:4586)
    android.app.ActivityThread.access$1600(ActivityThread.java:154)
    android.app.ActivityThread$H.handleMessage(ActivityThread.java:1378)
    android.os.Handler.dispatchMessage(Handler.java:102)
    android.os.Looper.loop(Looper.java:135)
    android.app.ActivityThread.main(ActivityThread.java:5296)
    java.lang.reflect.Method.invoke(Native Method)
    java.lang.reflect.Method.invoke(Method.java:372)
    com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
    com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)
File: "<unknown>, line: 1, column: 265

StackTrace: 
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/native.module.js', line: 18, column: 15
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/app.js', line: 6, column: 23
	Frame: function:'require', file:'', line: 1, column: 266


Error: com.tns.NativeScriptException: Failed to find module: "./app/modules/core/index", relative to: app/
    com.tns.Module.resolvePathHelper(Module.java:146)
    com.tns.Module.resolvePath(Module.java:55)
    com.tns.Runtime.runModule(Native Method)
    com.tns.Runtime.runModule(Runtime.java:530)
    com.tns.Runtime.run(Runtime.java:522)
    com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
    android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1012)
    android.app.ActivityThread.handleBindApplication(ActivityThread.java:4586)
    android.app.ActivityThread.access$1600(ActivityThread.java:154)
    android.app.ActivityThread$H.handleMessage(ActivityThread.java:1378)
    android.os.Handler.dispatchMessage(Handler.java:102)
    android.os.Looper.loop(Looper.java:135)
    android.app.ActivityThread.main(ActivityThread.java:5296)
    java.lang.reflect.Method.invoke(Native Method)
    java.lang.reflect.Method.invoke(Method.java:372)
    com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912)
    com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)
File: "<unknown>, line: 1, column: 265

StackTrace: 
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/native.module.js', line: 18, column: 15
	Frame: function:'require', file:'', line: 1, column: 266
	Frame: function:'', file:'file:///data/data/com.yourdomain.nativescript/files/app/app.js', line: 6, column: 23
	Frame: function:'require', file:'', line: 1, column: 266


	at com.tns.Runtime.runModule(Native Method)
	at com.tns.Runtime.runModule(Runtime.java:530)
	at com.tns.Runtime.run(Runtime.java:522)
	at com.tns.NativeScriptApplication.onCreate(NativeScriptApplication.java:19)
	at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1012)
	at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4586)
	... 9 more
  • Node: node --version = v6.14.2
  • npm: npm --version = v3.10.10
  • nativescript: tns info = v3.4.0
@ghost
Copy link

ghost commented Jun 17, 2018

i am facing same issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant