android icon indicating copy to clipboard operation
android copied to clipboard

Crash: No implementation found for void com.tns.AssetExtractor.extractAssets

Open lambourn opened this issue 6 years ago • 1 comments

Environment

  • CLI: 4.2.1
  • Cross-platform modules: 4.2.0
  • Android Runtime: 4.2.0

Describe the bug

We got several crash reports mostly occuring on Huawei devices running Android 9.0 where the app crashes on startup because of a missing AssetExtractor implementation (which seems pretty weird)

Any ideas what's happening there and how to resolve it?

Stack trace:

12-07 15:44:02.932 10130 12663 12663 E No implementation found for void com.tns.AssetExtractor.extractAssets(java.lang.String, java.lang.String, java.lang.String, boolean) (tried Java_com_tns_AssetExtractor_extractAssets and Java_com_tns_AssetExtractor_extractAssets__Ljava_lang_String_2Ljava_lang_String_2Ljava_lang_String_2Z)
12-07 15:44:02.933 10130 12663 12663 D AndroidRuntime: Shutting down VM
--------- beginning of crash
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: FATAL EXCEPTION: main
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: Process: ***.***.control, PID: 12663
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: java.lang.UnsatisfiedLinkError: No implementation found for void com.tns.AssetExtractor.extractAssets(java.lang.String, java.lang.String, java.lang.String, boolean) (tried Java_com_tns_AssetExtractor_extractAssets and Java_com_tns_AssetExtractor_extractAssets__Ljava_lang_String_2Ljava_lang_String_2Ljava_lang_String_2Z)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at com.tns.AssetExtractor.extractAssets(Native Method)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at com.tns.AssetExtractor.extractAssets(Unknown Source:38)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at com.tns.RuntimeHelper.initRuntime(Unknown Source:111)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at com.tns.NativeScriptApplication.onCreate(Unknown Source:19)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1162)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at android.app.ActivityThread.handleBindApplication(ActivityThread.java:6535)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at android.app.ActivityThread.access$1900(ActivityThread.java:267)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1957)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at android.os.Handler.dispatchMessage(Handler.java:109)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at android.os.Looper.loop(Looper.java:207)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at android.app.ActivityThread.main(ActivityThread.java:7439)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at java.lang.reflect.Method.invoke(Native Method)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
12-07 15:44:02.934 10130 12663 12663 E AndroidRuntime: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:958)

lambourn avatar Dec 07 '18 08:12 lambourn

@lambourn sorry for the late response. Do you still experience the same crashes. It's very odd as the method that cannot be found is part of the NativeScript.so library. Seems that the file exists as otherwise the crash would happen when trying to load the library here - https://github.com/NativeScript/android-runtime/blob/master/test-app/app/src/main/java/com/tns/RuntimeHelper.java#L70. So maybe the library is somehow corrupt which is quite strange because it happens only on some devices. Do you use ProGuard, Google Play app signing? Can you send us the apk so that we can see what we have there?

vtrifonov avatar Apr 16 '19 12:04 vtrifonov