Search Unity

  1. How can our website serve you better? Give us your feedback. Take our survey and let us know.
    Dismiss Notice

Crashes on Android after migrating to Unity 2018.3 when use AndroidJavaProxy class

Discussion in 'Android' started by IceCatGames, Feb 11, 2019.

  1. nvtuan96

    nvtuan96

    Joined:
    Oct 12, 2017
    Posts:
    12
    Hi guys, How about your crash rate in Google Console with new unity version 2018.3.13 ?
     
  2. Fronne

    Fronne

    Joined:
    Sep 25, 2014
    Posts:
    110
    Hard to tell, only 4 tests (APK Version Code 18) completed after almost 48 hours (IL2CPP)...
    I noticed, there where no crashes with Unity 2018.3.11 and 2019.1.0, and always crashes with Unity 2018.3.12...
    1. Unity 2018.3.11 - APK Version Code 7, 19 and 20 (IL2CPP)
    2. Unity 2018.3.12 - APK Version Code 8, 9, 10 and 15
    3. Unity 2018.3.13 - APK Version Code 18 (IL2CPP)
    4. Unity 2019.1.0 - APK Version Code 11, 12, 14, 16 and 17
    I have some weird issues with 2018.3.13 and 2019.1.0 related to IAP so I might release our App with 2018.3.11 next week. IAP works perfect on iOS and on Android it works perfect the first time, but when starting the App a second time, IAP produces this error:

    https://forum.unity.com/threads/exception-error-called-non-existent-method-system-boolean-unityengine-vr-vrsettings-get_enabled.518868/#post-4424164

    With Unity 2018.3.11, no issues att all. I followed all recomeded steps several times with 2018.3.12, 2018.3.13 and 2019.1.0 but IAP stops working after the first time...

    Happy Easter!
    Cheers!
    Franco Palmieri - Fronne
     

    Attached Files:

    nvtuan96 likes this.
  3. digitalmoka

    digitalmoka

    Joined:
    Nov 11, 2016
    Posts:
    7
    Hi,

    I have the same error. It appears on Android after the application was closed the first time. I solved by changing the exit method. Before I used to Application.Quit() and now

    Code (CSharp):
    1. using (AndroidJavaClass javaClass = new AndroidJavaClass("com.unity3d.player.UnityPlayer"))
    2.         using (AndroidJavaObject javaActivity = javaClass.GetStatic<AndroidJavaObject>("currentActivity"))
    3.         {
    4.             javaActivity.Call<bool>("moveTaskToBack", true);
    5.             javaActivity.Call("finish");
    6.  
    7.         }
     
    Hardik and Fronne like this.
  4. Fronne

    Fronne

    Joined:
    Sep 25, 2014
    Posts:
    110
    Thank You VERY, VERY MUCH digitalmoka!!!

    I'll let you know this Easter weekend if this solves the problem, I'm investigating another option because the API Updater doesn't start automaticly, I have to trigger it by inserting some deprecated code, this step should run automaticly...

    I'm having the same issues with 2018.3.12, 2018.3.13 and 2019.1.0 but on 2018.3.11 there's no problem at all...
    I'm busy for three days trying to fix it but nothing seems to work, I'm going to create a new project and copy the files into the original project, that helped some victoms too and I prefer to publish with Unity 2019.1.0 to be honest...

    Tomorrow, I'll try your fix with Unity 2018.3.13 first, I'll let you know!

    Cheers!
    Franco Palmieri - Fronne
     
    nvtuan96 likes this.
  5. Fronne

    Fronne

    Joined:
    Sep 25, 2014
    Posts:
    110
    Correction: Thank You VERY, VERY,VERY, VERY,VERY, VERY,VERY, VERY MUCH digitalmoka!!! :) Karma +1000 ;)

    It seems to work with Unity 2018.3.13, I have to do some more testing to be absolutely sure, on some restarts I get the problem back but not for a long time, this has to be a Unity bug in 2018.3.12 and 2018.3.13...

    <edit>
    Tested on four Android devices now and on three of them it works 100% of the time. On my old Galaxy S5 it didn't work a few times but I'm not able to reproduce it after a second Build without any "junk code" in the exit method...
    </edit>

    Cheers!
    Franco Palmieri - Fronne
     
    Last edited: Apr 21, 2019
  6. Antony-Blackett

    Antony-Blackett

    Joined:
    Feb 15, 2011
    Posts:
    1,728
    Now I'm hesitant to use any versions. So what do we know?

    Versions before 2018.3.13 have Java.lang issues but versions 2018.3.12 and after have IAP issues?
     
  7. Fronne

    Fronne

    Joined:
    Sep 25, 2014
    Posts:
    110
    Not for everybody I think, perhaps the Errors show up after Upgrading you project to a new Unity Version in some cases. If everybody had the same problem, there where more posts on this subject...

    In U2019.1.0, the upgrade steps are not working in my case, but in other cases they do:

    https://forum.unity.com/threads/exc...r-vrsettings-get_enabled.518868/#post-4424164

    https://forum.unity.com/threads/iap-troubleshooting-remove-and-reinstall-unity-iap.511747/

    Cheers!
    Franco Palmieri - Fronne
     
    Last edited: Apr 21, 2019
  8. MohHeader

    MohHeader

    Joined:
    Aug 12, 2015
    Posts:
    41
    Edit ::
    Post created for that issue.
    https://forum.unity.com/threads/and...ont-initialize-after-application-quit.665497/

    I have the same issue too :(
    But invoking the native finish() didn't fix it in my case

    But I think this is another issue to be reported in another thread
     
    Last edited: Apr 21, 2019
    Fronne likes this.
  9. toberr

    toberr

    Joined:
    Oct 1, 2016
    Posts:
    36
    try
    Code (CSharp):
    1. AndroidJavaObject activity = new AndroidJavaClass("com.unity3d.player.UnityPlayer").GetStatic<AndroidJavaObject>("currentActivity");
    2.                  activity.Call<bool>("moveTaskToBack", true);
    with 2018.3.13
     
    Fronne likes this.
  10. MohHeader

    MohHeader

    Joined:
    Aug 12, 2015
    Posts:
    41
    Thanks, yes this is a smart workaround,
    so instead of quitting the app, just move it to the background,
    different logic, but perfect solution till we have a fix from Unity

    ;)
    Thanks
     
    Fronne likes this.
  11. Sparkline

    Sparkline

    Joined:
    Feb 8, 2013
    Posts:
    111
    Hi guys! Just found this thread. A week ago pushed an update with unity 2018.3.12 and started to get various crashes like you. So, did you collect enough statisctics with unity 2018.3.13?
    Does this bug fixed there?
    How do you think what version of unity is more stable now? 2018.3.13 or 2019.1.0 ?
     
  12. Fronne

    Fronne

    Joined:
    Sep 25, 2014
    Posts:
    110
    I don't get any (or incomplete) Pre-Launch reports for about a week or so, the only Report I get, is the Test in progress message. I had some crashes on a (very old) Galaxy 5S with Unity 2018.3.12 but no crashes yet with 2018.3.13 and no problems accept the IAP "bug"...

    Unity 2018.4 (LTS) should arrive very soon so I'll stick with 2018 for the time being...
    I'm going to publish our new App on the App Stores later this week, so I can tell you more about stability next week if I Pass Apple's Ballot Committee the first time. :p

    From the Blog:

    In the next few weeks we will also release the 2018.4 Long-Term Support (LTS) version of Unity for those of you with projects about to ship and thus who wish to lock-in their production on a rock-solid foundation for an extended period.

    https://blogs.unity3d.com/2019/04/16/introducing-unity-2019-1/


    Cheers!
    Franco Palmieri - Fronne
     

    Attached Files:

  13. Ogien

    Ogien

    Joined:
    Nov 21, 2012
    Posts:
    160
    So far so good with 2018.3.13, no serious issues for me.
     
  14. Antony-Blackett

    Antony-Blackett

    Joined:
    Feb 15, 2011
    Posts:
    1,728
    Yeah same here. it's working well for me too.
     
    shahmir9009 likes this.
  15. toberr

    toberr

    Joined:
    Oct 1, 2016
    Posts:
    36
  16. Antony-Blackett

    Antony-Blackett

    Joined:
    Feb 15, 2011
    Posts:
    1,728
    Screen Shot 2019-04-29 at 11.12.07 AM.png
     
  17. Ogien

    Ogien

    Joined:
    Nov 21, 2012
    Posts:
    160
    My ANR rate is 0.10% but that has never been 0 for me :)
     
  18. Nomibuilder

    Nomibuilder

    Joined:
    Apr 24, 2014
    Posts:
    19
    Crashes are back in Unity 2019.1.3
    I was having crashes on ILL2CPP 64bit Architecture in Unity 2019.1.1 and Unity 2019.1.2
    They fixed ARM64 crashes in Unity 2019.1.3
    But now I am getting same crashes as in Unity 2018.3.12
     
  19. BryanF

    BryanF

    Joined:
    Jan 24, 2017
    Posts:
    1
    Unity 2018.3.13 is working for me also. :)
     
    nvtuan96 likes this.
  20. alexev05

    alexev05

    Joined:
    Feb 6, 2019
    Posts:
    11
    2019.1.4f1 a lot of crashes.


    java.lang.Error
    : FATAL EXCEPTION [main] Unity version : 2019.1.4f1 Device model : samsung SM-J500H Device fingerprint: samsung/j53gxx/j53g:6.0.1/MMB29M/J500HXXU2BQI1:user/release-keys Caused by

    at com.unity3d.player.UnityPlayer.nativeRestartActivityIndicator (Native Method)

    at com.unity3d.player.UnityPlayer.resume (Unknown Source)

    at com.unity3d.player.UnityPlayerActivity.onResume (Unknown Source)

    at android.app.Instrumentation.callActivityOnResume (Instrumentation.java:1287)

    at android.app.Activity.performResume (Activity.java:7015)

    at android.app.ActivityThread.performResumeActivity (ActivityThread.java:4210)

    at android.app.ActivityThread.handleResumeActivity (ActivityThread.java:4323)

    at android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:3426)

    at android.app.ActivityThread.access$1100 (ActivityThread.java:229)

    at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1821)

    at android.os.Handler.dispatchMessage (Handler.java:102)

    at android.os.Looper.loop (Looper.java:148)

    at android.app.ActivityThread.main (ActivityThread.java:7325)

    at java.lang.reflect.Method.invoke (Native Method)

    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:1230)

    at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1120)
     
  21. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    2,983
    This is different crash, not related to AndroidJavaProxy.
    Do you use custom activity or some plugins that involve custom/background activities or notifications? That would help us to pinpoint the source of these.
     
  22. alexev05

    alexev05

    Joined:
    Feb 6, 2019
    Posts:
    11
    [QUOTE = "Aurimas-Cernius, post: 4630336, member: 365873"]
    This is different crash, not related to AndroidJavaProxy.
    Do you use custom activity or some plugins that involve custom/background activities or notifications? That would help us to pinpoint the source of these.
    [/ QUOTE]
    I use only appodeal sdk. Crashes about 23 devices for 5000. I can' t see errors on own real devices.
    manifest
    <?xml version="1.0" encoding="utf-8"?>
    <manifest
    xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.******.*****"
    xmlns:tools="http://schemas.android.com/tools"
    android:installLocation="preferExternal">
    <supports-screens
    android:smallScreens="true"
    android:normalScreens="true"
    android:largeScreens="true"
    android:xlargeScreens="true"
    android:anyDensity="true"/>

    <application
    android:name="android.support.multidex.MultiDexApplication"
    android:theme="@StyLe/UnityThemeSelector"
    android:icon="@Mipmap/app_icon"
    android:label="@String/app_name">
    <activity android:name="com.unity3d.player.UnityPlayerActivity"
    android:label="@String/app_name">
    <intent-filter>
    <action android:name="android.intent.action.MAIN" />
    <category android:name="android.intent.category.LAUNCHER" />
    </intent-filter>
    <meta-data android:name="com.google.android.gms.ads.APPLICATION_ID" android:value="*******************" />
    </activity>
    </application>
    </manifest>



    And google console test said that app has grey api.

    StrictMode policy violation: android.os.strictmode.NonSdkApiUsedViolation: Ljava/lang/invoke/MethodHandles$Lookup;-><init>(Ljava/lang/Class;I)V
    at android.os.StrictMode.lambda$static$1(StrictMode.java:428)
    at android.os.-$$Lambda$StrictMode$lu9ekkHJ2HMz0jd3F8K8MnhenxQ.accept(Unknown Source:2)
    at java.lang.Class.getDeclaredConstructorInternal(Native Method)
    at java.lang.Class.getConstructor0(Class.java:2325)
    at java.lang.Class.getDeclaredConstructor(Class.java:2166)
    at bitter.jnibridge.JNIBridge$a.<init>(Unknown Source:25)
    at bitter.jnibridge.JNIBridge.newInterfaceProxy(Unknown Source:8)
    at com.unity3d.player.UnityPlayer.nativeRender(Native Method)
    at com.unity3d.player.UnityPlayer.c(Unknown Source:0)
    at com.unity3d.player.UnityPlayer$e$2.queueIdle(Unknown Source:72)
    at android.os.MessageQueue.next(MessageQueue.java:395)
    at android.os.Looper.loop(Looper.java:160)
    at com.unity3d.player.UnityPlayer$e.run(Unknown Source:32)
     
    Last edited: Jun 11, 2019
  23. Rapty

    Rapty

    Joined:
    Sep 19, 2015
    Posts:
    23
    I've Posted the bug here -> https://forum.unity.com/threads/nat...startactivityindicator-v.546271/#post-4637809

    Still no answer, they gave me a case number "1162118" , but it doesn't appear in fogbugz. I also attached my project. QA said they can't build the project, but i also gave them instructions. The bug also reproduces in unity 2019.1.6.
     
  24. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    Recently I had to upgrade to Unity 2019.1.4 because of the 64 bit support that Google requires.
    Terrible decision.Tons of production crashes. I could only reproduce the issue (hope is this one) on my old galaxy tab 4.
    Here is the trace from log cat:

    Code (CSharp):
    1. 06-26 00:24:23.686 284-284/? E/SMD: DCD OFF
    2. 06-26 00:24:24.146 31177-31177/? E/CRASH: other thread is trapped; signum = 11
    3. 06-26 00:24:24.156 31177-31177/? E/InputEventReceiver: Exception dispatching input event.
    4. 06-26 00:24:24.156 31177-31177/? E/MessageQueue-JNI: Exception in MessageQueue callback: handleReceiveCallback
    5. 06-26 00:24:24.156 31177-31177/? E/MessageQueue-JNI: java.lang.Error: signal 11 (SIGSEGV), code 2 (SEGV_ACCERR), fault addr a5e7b746
    6.                                                      Build fingerprint: 'samsung/matisseltexx/matisselte:5.0.2/LRX22G/T535XXU1BOG3:user/release-keys'
    7.                                                      Revision: '3'
    8.                                                      pid: 31177, tid: 31499, name: Job.Worker 0  >>> air.bg.lan.Monopoli <<<
    9.                                                          r0 aefd7210  r1 a5e7b747  r2 00000000  r3 97b23308
    10.                                                          r4 00000001  r5 97212700  r6 97dd44c0  r7 97b230c0
    11.                                                          r8 97b23110  r9 97b23308  sl 97dd4490  fp 00000000
    12.                                                          ip aef66d40  sp 9d0b8cc0  lr 9c331fa4  pc a5e7b746  cpsr b3c97d10
    13.                                                  
    14.                                                          at Unknown.006a5746(Unknown Source)
    15.                                                          at libunity.00b82fa0(Native Method)
    16.                                                          at libunity.0038cf48(Native Method)
    17.                                                          at libunity.00412210(Native Method)
    18.                                                          at libunity.00412518(Native Method)
    19.                                                          at libunity.00412858(Native Method)
    20.                                                          at libunity.00411b94(Native Method)
    21.                                                          at libunity.003a29c0(Native Method)
    22.                                                          at libc.__pthread_start(void*)(__pthread_start:30)
    23.                                                          at libc.__start_thread(__start_thread:6)
    24. 06-26 00:24:24.186 284-1329/? E/SMD: connect error:13
    25. 06-26 00:24:24.186 2477-2477/? E/audit: type=1400 msg=audit(1561497864.186:3262): avc:  denied  { connectto } for  pid=1329 comm="smdexe" path="/data/.socket_stream" scontext=u:r:smdexe:s0 tcontext=u:r:init:s0 tclass=unix_stream_socket
    26. 06-26 00:24:24.186 2477-2477/? E/audit:  SEPF_SM-T535_5.0.2_0027
    27. 06-26 00:24:24.186 2477-2477/? E/audit: type=1300 msg=audit(1561497864.186:3262): arch=40000028 syscall=283 per=800000 success=no exit=-13 a0=a a1=b69f1cfc a2=6e a3=b6fa4c90 items=1 ppid=1 ppcomm=init pid=1329 auid=4294967295 uid=1000 gid=1000 euid=1000 suid=1000 fsuid=1000 egid=1000 sgid=1000 fsgid=1000 tty=(none) ses=4294967295 comm="smdexe" exe="/system/bin/smdexe" subj=u:r:smdexe:s0 key=(null)
    28. 06-26 00:24:24.186 2477-2477/? E/audit: type=1306 msg=audit(1561497864.186:3262): saddr=01002F646174612F2E736F636B65745F73747265616D00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
    29. 06-26 00:24:24.186 2477-2477/? E/audit: type=1302 msg=audit(1561497864.186:3262): item=0 name=(null) inode=14 dev=b3:1a mode=0140700 ouid=1000 ogid=1000 rdev=00:00 obj=u:object_r:system_data_file:s0
    30. 06-26 00:24:24.186 2477-2477/? E/audit: type=1320 msg=audit(1561497864.186:3262):
    31. 06-26 00:24:24.186 31177-31177/? E/AndroidRuntime: FATAL EXCEPTION: main
    32.                                                    Process: air.bg.lan.Monopoli, PID: 31177
    33.                                                    java.lang.Error: FATAL EXCEPTION [main]
    34.                                                    Unity version     : 2019.1.4f1
    35.                                                    Device model      : samsung SM-T535
    36.                                                    Device fingerprint: samsung/matisseltexx/matisselte:5.0.2/LRX22G/T535XXU1BOG3:user/release-keys
    37.                                                
    38.                                                    Caused by: java.lang.Error: signal 11 (SIGSEGV), code 2 (SEGV_ACCERR), fault addr a5e7b746
    39.                                                    Build fingerprint: 'samsung/matisseltexx/matisselte:5.0.2/LRX22G/T535XXU1BOG3:user/release-keys'
    40.                                                    Revision: '3'
    41.                                                    pid: 31177, tid: 31499, name: Job.Worker 0  >>> air.bg.lan.Monopoli <<<
    42.                                                        r0 aefd7210  r1 a5e7b747  r2 00000000  r3 97b23308
    43.                                                        r4 00000001  r5 97212700  r6 97dd44c0  r7 97b230c0
    44.                                                        r8 97b23110  r9 97b23308  sl 97dd4490  fp 00000000
    45.                                                        ip aef66d40  sp 9d0b8cc0  lr 9c331fa4  pc a5e7b746  cpsr b3c97d10
    46.                                                
    47.                                                        at Unknown.006a5746(Unknown Source)
    48.                                                        at libunity.00b82fa0(Native Method)
    49.                                                        at libunity.0038cf48(Native Method)
    50.                                                        at libunity.00412210(Native Method)
    51.                                                        at libunity.00412518(Native Method)
    52.                                                        at libunity.00412858(Native Method)
    53.                                                        at libunity.00411b94(Native Method)
    54.                                                        at libunity.003a29c0(Native Method)
    55.                                                        at libc.__pthread_start(void*)(__pthread_start:30)
    56.                                                        at libc.__start_thread(__start_thread:6)
     
  25. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    UPDATE: I'm experimenting with latest Unity 2019.2.0b7
    There are crashes again, but I need few more days to get more info and stack traces.
    Do you guys thing if I upload mono build (and not IL2CPP) it will work?

    The main problem could be this:

    upload_2019-6-28_0-49-33.png
     
    Last edited: Jun 27, 2019
  26. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    2,983
    Based on stacktrace I think it should. But could you still report a bug? This crash at il2cpp init is something we'd like to fix and yours looks like a different condition from what we had in the past.
     
  27. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    @Aurimas-Cernius I just submitted a bug report (Case 1166103), uploading the most relevant plugin folders (excluding my game sources). I added a lot of details, but even if building a project with my files/plugins, it may not be reproducible as I can't reproduce the issue with all my phones.
    Around 7-8% of all production users have these crashes happening (and my active users are 900 000).
    I'll be testing beta build with Mono, to see if crashes will go away
     
    Last edited: Jun 28, 2019
  28. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    UPDATE: I had to roll back my apk (using unzip, version change, resign, repack apk) and now the crashes are gone.
    upload_2019-7-6_18-20-12.png
    Now I'm reverting my project (and redoing some things) to get back to Unity 2018.1.1
    Will never ever upgrade Unity!
    (My only concern is that 2018.1.1 has experimental 64bit support..but I hope it is OK)
     
  29. RGAMESR

    RGAMESR

    Joined:
    Feb 10, 2017
    Posts:
    23
    Do I have the same problem?

    Code (CSharp):
    1. java.lang.Error: signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0000000000000058
    2. Build fingerprint: 'HUAWEI/JKM-LX1/HWJKM-H:8.1.0/HUAWEIJKM-LX1/160(C185)R1:user/release-keys'
    3. Revision: '0'
    4. pid: 6317, tid: 6344, name: UnityMain  >>> com.drbaweh.gameraad <<<
    5. x0   0000000000000000  x1   00000000000000cd  x2   0000006fbe79cf50  x3   0000000000000000
    6. x4   0000000000800000  x5   726968545f000000  x6   0000805f54686972  x7   716867535dff7764
    7. x8   0000000000000000  x9   0000000000000001  x10  0000000000000000  x11  0000000000000010
    8. x12  0000000000000000  x13  00000000ffffffff  x14  00000000fffffffe  x15  0000000000000000
    9. x16  0000006fcc6d76c8  x17  000000706bab2d40  x18  0000000000000000  x19  0000000000000000
    10. x20  0000006fbe79cf50  x21  0000006fbe79ccd0  x22  000000000000000b  x23  0000000000000000
    11. x24  0000006fbe79ccd0  x25  0000006fbe79cf50  x26  0000006fc9f19e94  x27  0000006fbe79ccd0
    12. x28  0000006fbe79cf50  x29  0000006fc9f19e90  x30  0000006fcbe38840
    13. sp   0000006fcb784930  pc   0000006fcbb43e08  pstate 0000000020000000
    14. at [vdso].(
    15.   at libunity. (0)
    16.   at libunity. (0)
    17.   at libunity. (0)
    18.   at libunity. (0)
    19.   at libunity. (0)
    20.   at libunity. (0)
    21.   at libunity. (0)
    22.   at libunity. (0)
    23.   at libunity. (0)
    24.   at libunity. (0)
    25.   at libunity. (0)
    26.   at libunity. (0)
    27.   at libunity. (0)
    28.   at base. (0)
    2
    Code (CSharp):
    1.        
    2. [B]java.lang.Error[/B]: FATAL EXCEPTION [main]
    3. Unity version : 2019.1.8f1 Device model : HUAWEI DRA-LX2 Device fingerprint:
    4.  HUAWEI/DRA-LX2/HWDRA-M:8.1.0/HUAWEIDRA-LX2/1.0.0.159(C185)
    5. :user/release-keys Caused by
    6.  
    7. at com.unity3d.player.UnityPlayer.nativeRestartActivityIndicator (Native Method)
    8.  
    9. at com.unity3d.player.UnityPlayer.resume (Unknown Source:23)
    10.  
    11. at com.unity3d.player.UnityPlayerActivity.onResume (Unknown Source:5)
    12.  
    13. at android.app.Instrumentation.callActivityOnResume (Instrumentation.java:1355)
    14.  
    15. at android.app.Activity.performResume (Activity.java:7218)
    16.  
    17. at android.app.ActivityThread.performResumeActivity (ActivityThread.java:3819)
    18.  
    19. at android.app.ActivityThread.handleResumeActivity (ActivityThread.java:3884)
    20.  
    21. at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1826)
    22.  
    23. at android.os.Handler.dispatchMessage (Handler.java:106)
    24.  
    25. at android.os.Looper.loop (Looper.java:166)
    26.  
    27. at android.app.ActivityThread.main (ActivityThread.java:6861)
    28.  
    29. at java.lang.reflect.Method.invoke (Native Method)
    30.  
    31. at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:450)
    32.  
    33. at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:936)
    34.          
     
    Last edited: Jul 6, 2019
  30. Sailendu

    Sailendu

    Joined:
    Jul 23, 2009
    Posts:
    216
    I see this crash is in a HWINE device which is a HUAWEI device, and most of my crashes comes from HUAWEI devices, and the previous post by @RaadGame also contain a crash from HUAWEI devices. I don't know what's the deal with all these HUAWEI devices. Does anyone know why most crashes are happening in HUAWEI devices?
     
    Last edited: Jul 7, 2019
  31. Aurimas-Cernius

    Aurimas-Cernius

    Unity Technologies

    Joined:
    Jul 31, 2013
    Posts:
    2,983
    Guys, please stop spamming forum threads with unrelated issues. Doing so missleads people to wrong solutions for their problems. This thread is about AndroidJavaProxy related crashes, if you don't see it in your callstack, this is not the correct thread.
     
  32. elhispano

    elhispano

    Joined:
    Jan 23, 2012
    Posts:
    52
    I don't think is unrelated, all these developers upgraded Unity to support Android 64 bits and the ARNs have increased a lot. The errors are random and difficult to reproduce, the only thing is related for us is upgrading Unity so we discuss about which versions of Unity reduce the ARNs.
     
    DungDajHjep, setauz and Sailendu like this.
  33. elhispano

    elhispano

    Joined:
    Jan 23, 2012
    Posts:
    52
    Same here, we see lot of crashes in HUAWEI devices, we are trying to rollback but we have tons of changes. We can't reproduce any of those crashes in our Huawei devices in the office.
     
    DungDajHjep, Sailendu and flashmandv like this.
  34. setauz

    setauz

    Joined:
    Jan 19, 2017
    Posts:
    6
    So downgrading to old, working versions is the only option for now? Any news about this issue?
     
    Sailendu and flashmandv like this.
  35. elhispano

    elhispano

    Joined:
    Jan 23, 2012
    Posts:
    52
    Yes. Crashes has decreased. We have done the following:
    • Build with il2cpp, .NET 4.0 in Unity 2018.4
    • We have updated the billing plugin (we saw some crash related). This isn't a package from asset store or the package manager, you have to access through the services tab -> billing -> update plugin
     
    DungDajHjep likes this.
  36. Miteshk7

    Miteshk7

    Joined:
    Sep 12, 2017
    Posts:
    4
    Hello, I just released my app few days ago and i'm getting these crash reports on my google console.I found out that the app stops suddenly while playing.I'm using Unity 2019.1.1f1 with Admob plugin.

    java.lang.Error
    : FATAL EXCEPTION [main] Unity version : 2019.1.1f1 Device model : HMD Global TA-1012 Device fingerprint: Nokia/TA-1012_00WW/NB1:9/PPR1.180610.011/00WW_5_15D:user/release-keys Caused by

    at java.util.ArrayList.get (ArrayList.java:439)

    at android.view.View.layout (View.java:20733)

    at android.view.ViewGroup.layout (ViewGroup.java:6202)

    at android.view.ViewRootImpl.performLayout (ViewRootImpl.java:2812)

    at android.view.ViewRootImpl.performTraversals (ViewRootImpl.java:2339)

    at android.view.ViewRootImpl.doTraversal (ViewRootImpl.java:1479)

    at android.view.ViewRootImpl$TraversalRunnable.run (ViewRootImpl.java:7258)

    at android.view.Choreographer$CallbackRecord.run (Choreographer.java:1050)

    at android.view.Choreographer.doCallbacks (Choreographer.java:862)

    at android.view.Choreographer.doFrame (Choreographer.java:797)

    at android.view.Choreographer$FrameDisplayEventReceiver.run (Choreographer.java:1036)

    at android.os.Handler.handleCallback (Handler.java:874)

    at android.os.Handler.dispatchMessage (Handler.java:100)

    at android.os.Looper.loop (Looper.java:198)

    at android.app.ActivityThread.main (ActivityThread.java:6729)

    at java.lang.reflect.Method.invoke (Native Method)

    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:493)

    at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:876)
     
  37. kilicbatuhan1205

    kilicbatuhan1205

    Joined:
    Dec 20, 2018
    Posts:
    26
    Still getting this error in Unity 2018.4.14f1, Unity Monetization 3.4.1:
    Galaxy S8, Android 9
    Code (csharp):
    1.  
    2. Exception: No such proxy method: UnityEngine.Advertisements.Platform.Android.AndroidPlatform.onUnityAdsError(UnityEngine.AndroidJavaObject,System.String)
    3. UnityEngine.AndroidJavaProxy.Invoke (System.String methodName, System.Object[] args) (at <00000000000000000000000000000000>:0)
    4. UnityEngine._AndroidJNIHelper.InvokeJavaProxyMethod (UnityEngine.AndroidJavaProxy proxy, System.IntPtr jmethodName, System.IntPtr jargs) (at <00000000000000000000000000000000>:0)
    5.  
     
    Last edited: Jan 2, 2020
  38. Munchy2007

    Munchy2007

    Joined:
    Jun 16, 2013
    Posts:
    1,559
    I'd been getting theses crashes to some degree for the past year or so, not enough to take me over the bad behaviour threshold, but in the region of 0.75% crash rate. Also a few ANRs, there again, just below the bad behaviour threshold.

    I had to do an update just before Christmas to fix a problem that occurred because (I assume) of changes made by Google to the Google Play Services platform. Following the update, I noticed that crashes and ANRs were getting very close to the bad behaviour threshold again, so as an experiment I disabled code stripping (which was currently set at the default level).

    Since then, I've had 1 unrelated crash and no ANRs whatsoever in 10s of thousands of game sessions, so for me at least, it seems that the default level of code stripping was the culprit and I'd suggest that anyone suffering the same problems at least try disabling code stripping.

    Although it resulted in a slightly larger build size, that was offset by my changing to from .apk to .aab builds, which brought the actual device download size down by around 30%.

    For further info, I'm using Google Play Game Services, Admob and Unity Ads.

    It seems odd that the default configuration for an Android build is the unsafe option, especially when you consider that it causes crashes that only affect some devices; This does make it rather difficult to release a game with any real certainty of its stability. I was unable to actually reproduce the crash on any of the test devices I tried.
     
    Last edited: Jan 6, 2020
  39. kilicbatuhan1205

    kilicbatuhan1205

    Joined:
    Dec 20, 2018
    Posts:
    26
    IL2CPP doesn't support turning off code stripping completely. And it is needed for Google's 64-bit requirement.
     
  40. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    Has anyone found a stable Unity version? Even my rock solid 2018.1.1f1 crumbles when Android 10 came and OnePlus, Huawei and other manufacturers updated their OS.
     
  41. Munchy2007

    Munchy2007

    Joined:
    Jun 16, 2013
    Posts:
    1,559
    If you don't mind using mono to build for the time being (Google's 64-bit requirement won't be enforced until August 2021), then turning off code stripping certainly seems to work. I'm using Unity 2018 LTS currently.

    My previous release was getting 150 crashes per 1000 devices, and this release is at 0.115 crashes per 1000 devices and the only difference between the two releases is the code stripping.

    I'm going to do some testing with building with IL2CPP, because although it says it doesn't completely disable code stripping even with the 'none' option, it may still be enough to prevent the crashes that happen when it's at the default setting.

    But either way there's still 20 months before it becomes an issue.
     
  42. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    @Munchy2007 Thanks for the suggestion. I will definitely try it. I'm just not sure now that I have released a 64 bit release, will google allow me to go back.

    I also tried to upgrade to the latest Unity 2019.2.17 and our game still crashes on OnePlus 7t Pro.
    Have you tested on this device? OnePlus gaming mode and 90 herz display refresh rate could have anything to do with the crashes.
     
  43. Munchy2007

    Munchy2007

    Joined:
    Jun 16, 2013
    Posts:
    1,559
    As far as I'm aware you should be able to release a 32-bit build to replace the 64 bit build, as long as you give it a higher bundle code as usual.

    I haven't tested on a OnePlus 7t Pro, so there could be a problem specific to that device. In which case, if it were me, I would just add that device to the excluded devices list.
     
  44. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    I just tested in my OnePlus 7t pro and it all seems to work fine. But will be able to finally tell once I release to 100% of users and see not many crashes.

    The IL2CPP 64bit crashes occur on other devices as well - Huawei and even Samsung Galaxy S10 (although I could not reproduce them with my Galaxy S10).
     
  45. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    Bad news..the game crashed on my OnePlus despite using Mono.
    This is the log that was displayed the moment it crashed:


    01-11 14:11:44.516 14092-14482/air.bg.lan.Monopoli W/Adreno-GSL: <gsl_ldd_control:549>: ioctl fd 91 code 0x400c0907 (IOCTL_KGSL_DEVICE_WAITTIMESTAMP_CTXTID) failed: errno 35 Resource deadlock would occur
    01-11 14:11:44.516 14092-14482/air.bg.lan.Monopoli W/Adreno-GSL: <log_gpu_snapshot:458>: panel.gpuSnapshotPath is not set.not generating user snapshot
    01-11 14:11:44.629 14092-14482/air.bg.lan.Monopoli E/chromium: [ERROR:gles2_cmd_decoder.cc(17050)] Offscreen context lost via ARB/EXT_robustness. Reset status = GL_UNKNOWN_CONTEXT_RESET_KHR
    01-11 14:11:44.629 14092-14482/air.bg.lan.Monopoli E/chromium: [ERROR:gles2_cmd_decoder.cc(4831)] GLES2DecoderImpl: Context reset detected after MakeCurrent.
    01-11 14:11:44.630 14092-14482/air.bg.lan.Monopoli W/Adreno-GSL: <gsl_ldd_control:549>: ioctl fd 91 code 0xc040094a (IOCTL_KGSL_GPU_COMMAND) failed: errno 35 Resource deadlock would occur
    01-11 14:11:44.630 14092-14482/air.bg.lan.Monopoli W/Adreno-GSL: <log_gpu_snapshot:458>: panel.gpuSnapshotPath is not set.not generating user snapshot

     
  46. Deleted User

    Deleted User

    Guest

    Just a further bit of info should anyone be interested. Built my latest game with Unity 2019.2.17f1 and its not reporting any crashes as of yet. Not that many downloads as of now, but enough to get a few crash reports going off past experience. The game is running Google Play Game Services and Unity Ads (via the Monetization API), and code stripping is set to low. This implies one of a few things...

    1) Unity (or maybe Google) has/have sorted the problem. Here's hoping this is the case.

    2) Users hate the game and are quitting it before it has a chance to crash. Possible, but my deduction of the root of the problem (at least in my case) is that the proxy class was receiving callbacks from servers after the app had been closed, and then trying to call no-longer-existing handlers, hence the crashes (or something along these lines), so by this logic people immediately quitting would lead to more crashes, not less, since the ad requests go out straight away on startup.

    3) When I published the game (this one requires an unhealthy level of paranoia and conspiratorial thinking), instead of going live as I thought upon release, it went into some kind of sandbox environment, where I get to see simulated reports with enough carrots just out of reach, dangling on the ends of sticks, to get me to keep promoting it, but no-one ever gets to see it, hence since it isn't running on any real devices it isn't crashing. If anyone wants to dispel this ridiculous line of reasoning then it should be available here https://play.google.com/store/apps/details?id=com.kbitretro.superspinfruitcrush (and apologies for slipping in this ever so sly link to my game!). If you do take a look you might of course confirm that my option number 2 is the correct one in this case (I think its good, I wouldn't have released it otherwise, but I'm somewhat detached from the modern games industry so not best placed to pass any real judgement on it).

    4) A strange twist of fate and odd turn of events led to the compiler producing my current build properly, whereas it might not normally do so.

    Aside from this, my general experience (and it does stretch back many years) is that when you start trying workarounds and suchlike and end up using non-standard build solutions to fix problems, especially with a platform like Unity, you generally end up in a bigger pickle than you were in to begin with. However, do make sure you destroy instances of stuff properly when the app is quitting (and know which instances of what might require you to do this), to make sure it exits as cleanly as possible. Beyond that you are left to rely on the integrity of whatever external code you have integrated into it.
     
  47. flashmandv

    flashmandv

    Joined:
    Mar 26, 2015
    Posts:
    139
    RGAMESR and Munchy2007 like this.
  48. KyleAceViral

    KyleAceViral

    Joined:
    Oct 8, 2019
    Posts:
    4
    Was there ever a fix found for the OP error? I'm having the issue atm and the thread kind of ventured off on a tangent by the looks of it haha
     
  49. rgbsafia

    rgbsafia

    Joined:
    Jan 25, 2020
    Posts:
    2
    Hi guys
    Is the issue fixed in Unity 2020.1.6?
     
    Last edited: Sep 25, 2020
  50. unity_2jxHNVY36zr2mg

    unity_2jxHNVY36zr2mg

    Joined:
    Jan 17, 2020
    Posts:
    41
    Unity 2019.3.14f

    ANR

    at com.unity3d.player.ReflectionHelper.nativeProxyInvoke (Native method)
    at com.unity3d.player.ReflectionHelper.a (unavailable)
    at com.unity3d.player.ReflectionHelper$1.invoke (unavailable)
    at java.lang.reflect.Proxy.invoke (Proxy.java:1006)
    at com.android.billingclient.api.BillingClientStateListener.onBillingServiceDisconnected
    at com.android.billingclient.api.BillingClientImpl$zza.onServiceDisconnected
    at android.app.LoadedApk$ServiceDispatcher.doDeath (LoadedApk.java:2086)
    at android.app.LoadedApk$ServiceDispatcher$RunConnection.run (LoadedApk.java:2101)
    at android.os.Handler.handleCallback (Handler.java:883)
    at android.os.Handler.dispatchMessage (Handler.java:100)
    at android.os.Looper.loop (Looper.java:237)
    at android.app.ActivityThread.main (ActivityThread.java:8107)
    at java.lang.reflect.Method.invoke (Native method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:496)
    at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1100)
     
unityunity