Forum Xamarin Xamarin.Forms

Java.Lang.NullPointerException: 'activityToken error in xamarin forms

REJAHREJAH Member ✭✭✭

In some devices when focused entry or editor application crashed.

Tagged:

Answers

  • REJAHREJAH Member ✭✭✭

    Below logs has come. I can't able to find why its occured.
    targeted framework= 29Q,
    xamarin form=4.7.0.1080

    09-14 16:41:13.573 D/Mono ( 2375): DllImport searching in: 'Internal' ('(null)').
    09-14 16:41:13.573 D/Mono ( 2375): Searching for 'java_interop_jnienv_new_char_array'.
    09-14 16:41:13.573 D/Mono ( 2375): Probing 'java_interop_jnienv_new_char_array'.
    09-14 16:41:13.573 D/Mono ( 2375): Found as 'java_interop_jnienv_new_char_array'.
    09-14 16:41:13.574 D/Mono ( 2375): DllImport searching in: '__Internal' ('(null)').
    09-14 16:41:13.574 D/Mono ( 2375): Searching for 'java_interop_jnienv_set_char_array_region'.
    09-14 16:41:13.574 D/Mono ( 2375): Probing 'java_interop_jnienv_set_char_array_region'.
    09-14 16:41:13.574 D/Mono ( 2375): Found as 'java_interop_jnienv_set_char_array_region'.
    09-14 16:41:13.577 D/Mono ( 2375): DllImport searching in: '__Internal' ('(null)').
    09-14 16:41:13.577 D/Mono ( 2375): Searching for 'java_interop_jnienv_get_char_array_region'.
    09-14 16:41:13.577 D/Mono ( 2375): Probing 'java_interop_jnienv_get_char_array_region'.
    09-14 16:41:13.577 D/Mono ( 2375): Found as 'java_interop_jnienv_get_char_array_region'.
    09-14 16:41:13.764 I/Choreographer( 2375): Skipped 125 frames! The application may be doing too much work on its main thread.
    09-14 16:41:14.411 W/zygote ( 2375): JNI RegisterNativeMethods: attempt to register 0 native methods for crc643f46942d9dd1fff9.EntryRenderer
    09-14 16:41:14.411 W/zygote ( 2375): JNI RegisterNativeMethods: attempt to register 0 native methods for crc64f7df2ec102606a23.MyEntryRenderer
    09-14 16:41:14.618 D/Mono ( 2375): DllImport searching in: '__Internal' ('(null)').
    09-14 16:41:14.618 D/Mono ( 2375): Searching for 'java_interop_jnienv_call_char_method_a'.
    09-14 16:41:14.618 D/Mono ( 2375): Probing 'java_interop_jnienv_call_char_method_a'.
    09-14 16:41:14.619 D/Mono ( 2375): Found as 'java_interop_jnienv_call_char_method_a'.
    09-14 16:41:14.945 D/Mono ( 2375): Loading reference 4 of /storage/emulated/0/Android/data/me.localwire.localwire/files/.__override
    /Xamarin.AndroidX.CoordinatorLayout.dll asmctx DEFAULT, looking for Xamarin.AndroidX.CustomView, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
    09-14 16:41:14.945 D/Mono ( 2375): Assembly Ref addref Xamarin.AndroidX.CoordinatorLayout[0xa8d38fe0] -> Xamarin.AndroidX.CustomView[0xa8d39100]: 5
    09-14 16:41:15.121 I/Choreographer( 2375): Skipped 80 frames! The application may be doing too much work on its main thread.
    09-14 16:41:15.222 W/View ( 2375): requestLayout() improperly called by crc643f46942d9dd1fff9.ScrollViewContainer{417ad63 V.E...... ......ID 0,0-1080,1704} during layout: running second layout pass
    Java.Lang.NullPointerException: 'activityToken'

  • REJAHREJAH Member ✭✭✭

    This is the device bug report. Go through this line !

    09-14 17:06:51.422 1000 2838 2858 W ActivityManager: Background start not allowed: service Intent { act=Orca.START cmp=com.facebook.katana/com.facebook.mqttlite.MqttService } to com.facebook.katana/com.facebook.mqttlite.MqttService from pid=18454 uid=10270 pkg=com.facebook.katana
    09-14 17:06:51.734 1000 2838 2905 W BroadcastQueue: Permission Denial: broadcasting Intent { act=android.net.conn.CONNECTIVITY_CHANGE flg=0x4000010 (has extras) } from null (pid=-1, uid=-1) requires com.facebook.permission.prod.FB_APP_COMMUNICATION due to registered receiver BroadcastFilter{bc7dd1e u0 ReceiverList{8fa6d59 18454 com.facebook.katana/10270/u0 remote:cf67da0}}
    09-14 17:06:51.734 1000 2838 2905 W BroadcastQueue: Permission Denial: broadcasting Intent { act=android.net.conn.INET_CONDITION_ACTION flg=0x4000010 (has extras) } from null (pid=-1, uid=-1) requires com.facebook.permission.prod.FB_APP_COMMUNICATION due to registered receiver BroadcastFilter{bc7dd1e u0 ReceiverList{8fa6d59 18454 com.facebook.katana/10270/u0 remote:cf67da0}}
    09-14 17:06:51.770 1000 2838 2905 W BroadcastQueue: Permission Denial: broadcasting Intent { act=android.net.conn.CONNECTIVITY_CHANGE flg=0x4000010 (has extras) } from null (pid=-1, uid=-1) requires com.facebook.permission.prod.FB_APP_COMMUNICATION due to registered receiver BroadcastFilter{810ad2a u0 ReceiverList{95b8615 18454 com.facebook.katana/10270/u0 remote:cd5d3cc}}
    --------- beginning of crash
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: FATAL EXCEPTION: main
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: Process: me.localwire.localwire, PID: 18304
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: java.lang.NullPointerException: activityToken
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.os.Parcel.readException(Parcel.java:2019)
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.os.Parcel.readException(Parcel.java:1959)
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.view.autofill.IAutoFillManager$Stub$Proxy.startSession(IAutoFillManager.java:397)
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.view.autofill.AutofillManager.startSessionLocked(AutofillManager.java:1012)
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.view.autofill.AutofillManager.notifyViewEntered(AutofillManager.java:604)
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.view.autofill.AutofillManager.notifyViewEntered(AutofillManager.java:575)
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.view.View.notifyEnterOrExitForAutoFillIfNeeded(View.java:6983)
    09-14 17:06:52.829 10146 18304 18304 E AndroidRuntime: at android.view.View.onFocusChanged(View.java:6969)

  • LeonLuLeonLu Member, Xamarin Team Xamurai

    Can you share some related code or a demo about this issue?

    And which device have this issue?I adivce you to test your code in the Google device or emulator. If Google device or emulator could reproduce this issue. Your log cannot found some useful information.

  • REJAHREJAH Member ✭✭✭

    Issues occurred on moto g, samsung s6 like devices.

    When clicked on usernameEntry it crashed. Exception occured everywhere in the project where entry and editor exist. In Google pixel Emulator its work perfectly no error occurred.Please help me in this regards

  • REJAHREJAH Member ✭✭✭

    can't able to resolve the issues. Any idea how to resolved this .Any help will be appreciated.

  • LeonLuLeonLu Member, Xamarin Team Xamurai

    I do not have devices(moto g, samsung s6 ) to reproduce this issue, you can open a paid support ticket for this issue.

    https://support.microsoft.com/en-us/supportforbusiness/productselection?sapId=211dd84f-3474-c3c5-79bf-66db630c92a6

Sign In or Register to comment.