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

The application closes itself without crashed. #174

Closed
EugeneZaychenko opened this issue Nov 12, 2018 · 17 comments
Closed

The application closes itself without crashed. #174

EugeneZaychenko opened this issue Nov 12, 2018 · 17 comments

Comments

@EugeneZaychenko
Copy link

Hi! I use Android Premium SDK and the application just closes, without any errors, the only thing that is in the stackTrace I will indicate below. Even if the front service is running, it dies, and after a while it is restored. Since the stackTrace contains references to your inner classes, is there any suggestion that the error is in them? Please check it out?

2018-11-12 10:02:39.978 18057-18057/? A/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
2018-11-12 10:02:39.978 18057-18057/? A/DEBUG: Build fingerprint: 'google/sailfish/sailfish:9/PPR2.181005.003/4984323:user/release-keys'
2018-11-12 10:02:39.978 18057-18057/? A/DEBUG: Revision: '0'
2018-11-12 10:02:39.978 18057-18057/? A/DEBUG: ABI: 'arm64'
2018-11-12 10:02:39.978 18057-18057/? A/DEBUG: pid: 17650, tid: 17680, name: FinalizerDaemon >>> com.ua.eugenezaychenko.mocklocations <<<
2018-11-12 10:02:39.978 18057-18057/? A/DEBUG: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x794ac514e0
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x0 000000794ac514e0 x1 00000079c872a140 x2 0000000000000000 x3 00000079dcf1e99f
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x4 00000079c872a128 x5 0000008000000000 x6 284901ff3a535328 x7 7f7f7f7f7f7f7f7f
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x8 be569924098d6cee x9 be569924098d6cee x10 0000000000430000 x11 00000079dcfef688
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x12 0000000000000001 x13 0000000000000001 x14 0000000000000014 x15 0000000000000006
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x16 00000079dcfec3c8 x17 0000007a6091fa80 x18 000000000000001a x19 00000079dd0e1880
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x20 00000079c5c5794c x21 00000079c872a244 x22 0000000013d7b8c8 x23 0000000013d7b8c8
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x24 0000000013e7ee68 x25 00000079dcff2420 x26 0000000000000004 x27 00000079c75fcaa0
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: x28 00000079c872a240 x29 00000079c872a1f0
2018-11-12 10:02:39.979 18057-18057/? A/DEBUG: sp 00000079c872a1f0 lr 00000079c4391b10 pc 00000079c4391b28
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: backtrace:
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #00 pc 0000000000290b28 /data/app/com.ua.eugenezaychenko.mocklocations-oVGO7mZV7Tb_SfBDyQXObQ==/lib/arm64/libMAPSJNI.so (Java_com_nokia_maps_GeoCoordinateImpl_destroyGeoCoordinateNative+100)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #1 pc 00000000005693e0 /system/lib64/libart.so (art_quick_generic_jni_trampoline+144)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #2 pc 00000000000baa7c /dev/ashmem/dalvik-jit-code-cache (deleted) (com.nokia.maps.GeoCoordinateImpl.finalize+60)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #3 pc 00000000000bc09c /dev/ashmem/dalvik-jit-code-cache (deleted) (java.lang.Daemons$FinalizerDaemon.doFinalize+124)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #4 pc 000000000010e29c /dev/ashmem/dalvik-jit-code-cache (deleted) (java.lang.Daemons$FinalizerDaemon.runInternal+492)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #5 pc 00000000005606dc /system/lib64/libart.so (art_quick_osr_stub+44)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #6 pc 000000000030c6a8 /system/lib64/libart.so (art::jit::Jit::MaybeDoOnStackReplacement(art::Thread*, art::ArtMethod*, unsigned int, int, art::JValue*)+2024)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #7 pc 0000000000535f4c /system/lib64/libart.so (MterpMaybeDoOnStackReplacement+144)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #8 pc 0000000000557370 /system/lib64/libart.so (ExecuteMterpImpl+33136)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #9 pc 00000000000aed0e /system/framework/boot-core-libart.vdex (java.lang.Daemons$FinalizerDaemon.runInternal+178)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #10 pc 0000000000256d0c /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.3442999494+488)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #11 pc 000000000025c8bc /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+216)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #12 pc 000000000027cb90 /system/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+932)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #13 pc 000000000052fabc /system/lib64/libart.so (MterpInvokeVirtual+576)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #14 pc 0000000000552994 /system/lib64/libart.so (ExecuteMterpImpl+14228)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #15 pc 00000000000aeaf8 /system/framework/boot-core-libart.vdex (java.lang.Daemons$Daemon.run+20)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #16 pc 0000000000256d0c /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.3442999494+488)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #17 pc 000000000025c8bc /system/lib64/libart.so (art::interpreter::ArtInterpreterToInterpreterBridge(art::Thread*, art::CodeItemDataAccessor const&, art::ShadowFrame*, art::JValue*)+216)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #18 pc 000000000027cb90 /system/lib64/libart.so (bool art::interpreter::DoCall<false, false>(art::ArtMethod*, art::Thread*, art::ShadowFrame&, art::Instruction const*, unsigned short, art::JValue*)+932)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #19 pc 0000000000530a10 /system/lib64/libart.so (MterpInvokeInterface+1376)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #20 pc 0000000000552b94 /system/lib64/libart.so (ExecuteMterpImpl+14740)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #21 pc 00000000000ca806 /system/framework/boot.vdex (java.lang.Thread.run+12)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #22 pc 0000000000256d0c /system/lib64/libart.so (_ZN3art11interpreterL7ExecuteEPNS_6ThreadERKNS_20CodeItemDataAccessorERNS_11ShadowFrameENS_6JValueEb.llvm.3442999494+488)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #23 pc 0000000000520284 /system/lib64/libart.so (artQuickToInterpreterBridge+944)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #24 pc 00000000005694fc /system/lib64/libart.so (art_quick_to_interpreter_bridge+92)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #25 pc 0000000000560388 /system/lib64/libart.so (art_quick_invoke_stub+584)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #26 pc 00000000000cf6b8 /system/lib64/libart.so (art::ArtMethod::Invoke(art::Thread*, unsigned int*, unsigned int, art::JValue*, char const*)+200)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #27 pc 00000000004661e4 /system/lib64/libart.so (art::(anonymous namespace)::InvokeWithArgArray(art::ScopedObjectAccessAlreadyRunnable const&, art::ArtMethod*, art::(anonymous namespace)::ArgArray*, art::JValue*, char const*)+104)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #28 pc 00000000004672e8 /system/lib64/libart.so (art::InvokeVirtualOrInterfaceWithJValues(art::ScopedObjectAccessAlreadyRunnable const&, _jobject*, _jmethodID*, jvalue*)+424)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #29 pc 0000000000492660 /system/lib64/libart.so (art::Thread::CreateCallback(void*)+1116)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #30 pc 00000000000847bc /system/lib64/libc.so (__pthread_start(void*)+36)
2018-11-12 10:02:40.129 18057-18057/? A/DEBUG: #31 pc 0000000000023574 /system/lib64/libc.so (__start_thread+68)

@EugeneZaychenko EugeneZaychenko changed the title The application closes itself without being crashed. The application closes itself without crashed. Nov 12, 2018
@Merlin1stHere
Copy link
Contributor

@EugeneZaychenko, I can't reproduce this issue.
Could you provide the sample code that reproduces it?

@EugeneZaychenko
Copy link
Author

This is the problem, there is no specific code example. Just running the application with the map is closed or in the NavigationManager.getInstance ().simulate () mode - for some time it also closes. No specific algorithm for action. The only thing that repeats itself is the stack trace.

@Merlin1stHere
Copy link
Contributor

Which phone do you use? Maybe the application is closed by some software for power management? As example - MIUI system on the Xiaomi phones has very aggressive power management and it can close application unexpectedly.

@EugeneZaychenko
Copy link
Author

Pixel, HTC M5, Meizu 6 Pro, AVD - all devices have the same error. Since I have no idea what caused this behavior, I rewrite part of the application. When I finish, I will definitely report the result.

@Xgamefactory
Copy link

on android devices that have oreo os there is a battery optimization that closes inactive applications.

You can programmatically add your app with packagename to ignore battery optimization list.

PowerManager pm = (PowerManager) activity.getSystemService(Context.POWER_SERVICE);
pm.isIgnoringBatteryOptimizations(packageName);

@EugeneZaychenko
Copy link
Author

This problem is not only on Oreo and higher and energy consumption is not high.

@starand
Copy link
Contributor

starand commented Nov 14, 2018

@EugeneZaychenko,
Do you see that issue on github samples or tutorial app? If not, it is more likely this is app issue.

@EugeneZaychenko
Copy link
Author

I found a similar problem on stackoverflow.com ( https://stackoverflow.com/questions/17840521/android-fatal-signal-11-sigsegv-at-0x636f7d89-code-1-how-can-it-be-tracked ), but I still haven't figured out what causes it. I have a suggestion that this is somehow related to the Route object. I use Route.serializeAsync and Route.deserializeAsync and the routes created on SDK 3.8 are not reproduced on SDK 3.9

@starand
Copy link
Contributor

starand commented Nov 15, 2018

@EugeneZaychenko that depends on map version. If map version was updated, then you cannot use serialized route with previous map version.
Can you provide serialized route in order to try to reproduce?

@EugeneZaychenko
Copy link
Author

EugeneZaychenko commented Nov 20, 2018

I checked and rewired my Java code. Error did not go away, start backtrace: #00 pc 0000000000290b2c /data/app/com.ua.eugenezaychenko.mocklocations-KA-jd6trdJwnrYSsfTjaOQ==/lib/arm64/libMAPSJNI.so (Java_com_nokia_maps_GeoCoordinateImpl_destroyGeoCoordinateNative+104) - this is the path to your SDK. Also consistently shows this error - signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x8 and Cause: null pointer dereference.

@EugeneZaychenko
Copy link
Author

Similar problem mapbox/mapbox-gl-native#10555

@starand
Copy link
Contributor

starand commented Nov 20, 2018

@EugeneZaychenko,
We will review Java_com_nokia_maps_GeoCoordinateImpl_destroyGeoCoordinateNative method and add possible fix. But we cannot reproduce the issue. There are still two questions:

  1. Which phone do you use?
  2. Was you able to reproduce the issue on github sample app w/o modifying it?

@EugeneZaychenko
Copy link
Author

  1. Pixel, HTC M5, Meizu 6 Pro, AVD - all devices have the same error.
  2. I did not try, I will answer later. Maybe the problem is incompatibility with some other library, such as a room or a dagger 2.

@EugeneZaychenko
Copy link
Author

I fixed this problem - signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x8. When I removed the field with the GeoCoordinate object from my object. I save the coordinates as Double and then everything works.

@starand
Copy link
Contributor

starand commented Nov 26, 2018

@EugeneZaychenko,
Thank you for your feedback. We will try to reproduce this with provided info.

@starand
Copy link
Contributor

starand commented Nov 27, 2018

@EugeneZaychenko, we found and fixed issue with double deletion (it can happen when you call finalize method manually).
We would appreciate if you provide sample code of how you used GeoCoordinate in your class.
Thank you!

@starand starand closed this as completed Nov 28, 2018
@EugeneZaychenko
Copy link
Author

GeoCoordinate was in the data class (entity for the Room library) field. Annotated @ignore. An error occurred when I interacted with the database (write and read).

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

4 participants