This is a really specific issue, so it may be hard to diagnose.
I have an Android app that is working on an Android phone and is emulated correctly on a Windows 8.1 x86 emulator (via Android Studio), but when I run it in an x86 emulator on my Mac (OS X 10.11.1), it runs until I try to inflate the activity with the MapBox map.
To summarize, this is what works / what I've done:
Works on Windows 8.1 Android Studio Emulator
Works on an Android 5.1 Moto X
My Mac has the Intel x86 Emulator Accelerator (HAXM) installed
I am running an x86 Emulator via Android Studio for Mac
This error occurs just when inflating the MapBox activity:
10-30 12:16:03.848 4557-4557/? I/art: Not late-enabling -Xcheck:jni (already on)
10-30 12:16:03.848 4557-4557/? I/art: Late-enabling JIT
10-30 12:16:03.852 4557-4557/? I/art: JIT created with code_cache_capacity=2MB compile_threshold=1000
10-30 12:16:05.276 4557-4611/com.example.example.thisapp I/GMPM: App measurement is starting up
10-30 12:16:05.278 4557-4611/com.example.example.thisapp E/GMPM: getGoogleAppId failed with status: 10
10-30 12:16:05.279 4557-4611/com.example.example.thisapp E/GMPM: Uploading is not possible. App measurement disabled
10-30 12:16:05.336 4557-4573/com.example.example.thisapp W/art: Suspending all threads took: 19.618ms
10-30 12:16:05.522 4557-4626/com.example.example.thisapp D/OpenGLRenderer: Use EGL_SWAP_BEHAVIOR_PRESERVED: true
10-30 12:16:05.528 4557-4557/com.example.example.thisapp D/: HostConnection::get() New Host Connection established 0xb401ca30, tid 4557
10-30 12:16:05.632 4557-4626/com.example.example.thisapp D/: HostConnection::get() New Host Connection established 0xaf8be1e0, tid 4626
10-30 12:16:05.658 4557-4626/com.example.example.thisapp I/OpenGLRenderer: Initialized EGL, version 1.4
10-30 12:16:05.693 4557-4626/com.example.example.thisapp W/EGL_emulation: eglSurfaceAttrib not implemented
10-30 12:16:05.693 4557-4626/com.example.example.thisapp W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xabe3a540, error=EGL_SUCCESS
10-30 12:16:11.189 4557-4557/com.example.example.thisapp D/AndroidRuntime: Shutting down VM
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: FATAL EXCEPTION: main
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: Process: com.example.example.thisapp, PID: 4557
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.example.thisapp/com.example.example.thisapp.MapsActivity}: android.view.InflateException: Binary XML file line #9: Binary XML file line #9: Error inflating class com.mapbox.mapboxsdk.views.MapView
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: Caused by: android.view.InflateException: Binary XML file line #9: Binary XML file line #9: Error inflating class com.mapbox.mapboxsdk.views.MapView
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:539)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.setContentView(Activity.java:2166)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.example.example.thisapp.MapsActivity.onCreate(MapsActivity.java:79)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.performCreate(Activity.java:6237)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: Caused by: android.view.InflateException: Binary XML file line #9: Error inflating class com.mapbox.mapboxsdk.views.MapView
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createView(LayoutInflater.java:645)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:764)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:515)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.setContentView(Activity.java:2166)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.example.example.thisapp.MapsActivity.onCreate(MapsActivity.java:79)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.performCreate(Activity.java:6237)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: Caused by: java.lang.reflect.InvocationTargetException
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.reflect.Constructor.newInstance(Native Method)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createView(LayoutInflater.java:619)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:764)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:515)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.setContentView(Activity.java:2166)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.example.example.thisapp.MapsActivity.onCreate(MapsActivity.java:79)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.performCreate(Activity.java:6237)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: Caused by: java.lang.UnsatisfiedLinkError: dlopen failed: /data/app/com.example.example.thisapp-2/lib/x86/libmapbox-gl.so: has text relocations
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.Runtime.loadLibrary(Runtime.java:372)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.System.loadLibrary(System.java:1076)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.mapbox.mapboxsdk.views.NativeMapView.<clinit>(NativeMapView.java:37)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.mapbox.mapboxsdk.views.MapView.initialize(MapView.java:593)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.mapbox.mapboxsdk.views.MapView.<init>(MapView.java:538)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.reflect.Constructor.newInstance(Native Method)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createView(LayoutInflater.java:619)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:764)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:515)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.setContentView(Activity.java:2166)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.example.example.thisapp.MapsActivity.onCreate(MapsActivity.java:79)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Activity.performCreate(Activity.java:6237)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
10-30 12:16:11.199 4557-4557/com.example.example.thisapp E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
10-30 12:16:11.360 4557-4573/com.example.example.thisapp W/art: Suspending all threads took: 37.146ms
10-30 12:16:11.372 4557-4577/com.example.example.thisapp I/art: Background sticky concurrent mark sweep GC freed 9470(718KB) AllocSpace objects, 4(80KB) LOS objects, 48% free, 1890KB/3MB, paused 4.151ms total 202.120ms
10-30 12:16:11.407 4557-4577/com.example.example.thisapp W/art: Suspending all threads took: 34.815ms
The other InflateException / Binary XML error answers I've seen haven't worked or are not applicable.
Related
I am new to android and want to create drag and drop list view in my project.I am following this link.
This is my XML layout(activity_main.xml) contain com.terlici.dragndroplist.DragNDropListView.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<com.terlici.dragndroplist.DragNDropListView
android:id="#id/android:list"
android:layout_width="match_parent"
android:layout_height="match_parent"
/>
</LinearLayout>
There is my java main activity onCreate method
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
When i run this code i am getting this error.
09-27 09:02:09.266 2465-2465/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.franscc.testlistviewdraganddrop, PID: 2465
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.franscc.testlistviewdraganddrop/com.example.franscc.testlistviewdraganddrop.MainActivity}: android.view.InflateException: Binary XML file line #7: Binary XML file line #7: Error inflating class com.terlici.dragndroplist.DragNDropListView
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: android.view.InflateException: Binary XML file line #7: Binary XML file line #7: Error inflating class com.terlici.dragndroplist.DragNDropListView
at android.view.LayoutInflater.inflate(LayoutInflater.java:539)
at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)
at android.app.Activity.setContentView(Activity.java:2166)
at com.example.franscc.testlistviewdraganddrop.MainActivity.onCreate(MainActivity.java:15)
at android.app.Activity.performCreate(Activity.java:6237)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: android.view.InflateException: Binary XML file line #7: Error inflating class com.terlici.dragndroplist.DragNDropListView
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:776)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)
at android.view.LayoutInflater.inflate(LayoutInflater.java:515)
at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)
at android.app.Activity.setContentView(Activity.java:2166)
at com.example.franscc.testlistviewdraganddrop.MainActivity.onCreate(MainActivity.java:15)
at android.app.Activity.performCreate(Activity.java:6237)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: java.lang.ClassNotFoundException: Didn't find class "com.terlici.dragndroplist.DragNDropListView" on path: DexPathList[[zip file "/data/app/com.example.franscc.testlistviewdraganddrop-1/base.apk"],nativeLibraryDirectories=[/data/app/com.example.franscc.testlistviewdraganddrop-1/lib/x86, /vendor/lib, /system/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
at android.view.LayoutInflater.createView(LayoutInflater.java:583)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:764)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:704)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:835)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:798)
at android.view.LayoutInflater.inflate(LayoutInflater.java:515)
at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
at android.view.LayoutInflater.inflate(LayoutInflater.java:374)
at com.android.internal.policy.PhoneWindow.setContentView(PhoneWindow.java:393)
at android.app.Activity.setContentView(Activity.java:2166)
at com.example.franscc.testlistviewdraganddrop.MainActivity.onCreate(MainActivity.java:15)
at android.app.Activity.performCreate(Activity.java:6237)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Suppressed: java.lang.ClassNotFoundException: com.terlici.dragndroplist.DragNDropListView
at java.lang.Class.classForName(Native Method)
at java.lang.BootClassLoader.findClass(ClassLoader.java:781)
at java.lang.BootClassLoader.loadClass(ClassLoader.java:841)
at java.lang.ClassLoader.loadClass(ClassLoader.java:504)
... 24 more
Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack trace available
09-27 09:02:11.410 2465-2472/com.example.franscc.testlistviewdraganddrop W/art: Suspending all threads took: 9.984ms
Thanks for your rare time
Change
android:id="#id/android:list"
to this
android:id="#android:id/list"
I am learning Android Studio from a book called "Learn Android Studio: Build Android Apps Quickly and Effectively" By: Clifton Craig; Adam Gerber. I am following a tutorial on how to build a Reminders app and can't get the app to load. In the tutorial, I have been instructed to alter the onCreate() method with what is provided in the book, making sure to import what they provided.
The altered code is provided here.
The logcat is provided below:
01-18 06:04:55.460 2212-2212/com.apress.gerber.reminders I/art: Not late-enabling -Xcheck:jni (already on)
01-18 06:04:55.800 2212-2212/com.apress.gerber.reminders W/System: ClassLoader referenced unknown path: /data/app/com.apress.gerber.reminders-2/lib/x86_64
01-18 06:04:55.960 2212-2212/com.apress.gerber.reminders D/AndroidRuntime: Shutting down VM
01-18 06:04:55.960 2212-2212/com.apress.gerber.reminders E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.apress.gerber.reminders, PID: 2212
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.apress.gerber.reminders/com.apress.gerber.reminders.RemindersActivity}: java.lang.ClassCastException: android.widget.RelativeLayout cannot be cast to android.widget.ListView
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: java.lang.ClassCastException: android.widget.RelativeLayout cannot be cast to android.widget.ListView
at com.apress.gerber.reminders.RemindersActivity.onCreate(RemindersActivity.java:22)
at android.app.Activity.performCreate(Activity.java:6237)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
01-18 06:05:00.980 2212-2212/com.apress.gerber.reminders I/Process: Sending signal. PID: 2212 SIG: 9
The app will not load. The emulator gives an error. Any feedback on this would be greatly appreciated.
I am new to android and stuck at point. Please help!
I have created a dummy Hello world program (with project name testneha) in android studio. I created a new package "AppTest" folder inside the "com.example.ospune.testneha" folder. Inside the package, have created a JAVA class file with name AppTest1.
Folder Structure
com.example.ospune.test
AppTest(package folder)
AppTest1(java file)
MainActivity(file)
In AppTest1 file, onCreate folder I am calling "apptest layout file".
Now In the mainActivity file, I have added a button; which on being clicked calls startActivity mentioned in the AppTest1 class.
public void sendMessage(View view)
{
Intent intent = new Intent(this, com.example.ospune.test.neha.AppTest.AppTest1.class");
startActivity(intent);
}
My problem is when I click the button, I get a pop up saying "unfortunately, Test has stopped."
AndroidManifest.xml was also updated with the AppTest1.class activity
<activity
android:name=".AppTest.AppTest1"
android:parentActivityName=".MainActivity"
</activity>
I am clueless as what is the reason for this :(
LogCat error -
11-03 04:34:43.409 2055-2055/com.example.ospunelap_130.testneha I/art: Not late-enabling -Xcheck:jni (already on)
11-03 04:34:43.410 2055-2055/com.example.ospunelap_130.testneha I/art: Late-enabling JIT
11-03 04:34:43.419 2055-2055/com.example.ospunelap_130.testneha I/art: JIT created with code_cache_capacity=2MB compile_threshold=1000
11-03 04:34:43.507 2055-2055/com.example.ospunelap_130.testneha W/System: ClassLoader referenced unknown path: /data/app/com.example.ospunelap_130.testneha-2/lib/x86
11-03 04:34:43.914 2055-2083/com.example.ospunelap_130.testneha D/OpenGLRenderer: Use EGL_SWAP_BEHAVIOR_PRESERVED: true
11-03 04:34:43.918 2055-2055/com.example.ospunelap_130.testneha D/: HostConnection::get() New Host Connection established 0xad7f0110, tid 2055
11-03 04:34:44.008 2055-2083/com.example.ospunelap_130.testneha D/: HostConnection::get() New Host Connection established 0xad7f0420, tid 2083
11-03 04:34:44.033 2055-2083/com.example.ospunelap_130.testneha I/OpenGLRenderer: Initialized EGL, version 1.4
11-03 04:34:44.145 2055-2083/com.example.ospunelap_130.testneha W/EGL_emulation: eglSurfaceAttrib not implemented
11-03 04:34:44.145 2055-2083/com.example.ospunelap_130.testneha W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xabebf2c0, error=EGL_SUCCESS
11-03 04:34:45.360 2055-2055/com.example.ospunelap_130.testneha I/Choreographer: Skipped 66 frames! The application may be doing too much work on its main thread.
11-03 04:35:03.158 2055-2055/com.example.ospunelap_130.testneha D/AndroidRuntime: Shutting down VM
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: FATAL EXCEPTION: main
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: Process: com.example.ospunelap_130.testneha, PID: 2055
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.ospunelap_130.testneha/com.example.ospunelap_130.testneha.AppTest.AppTest1}: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.CharSequence android.support.v7.widget.Toolbar.getTitle()' on a null object reference
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.CharSequence android.support.v7.widget.Toolbar.getTitle()' on a null object reference
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.support.v7.internal.widget.ToolbarWidgetWrapper.<init>(ToolbarWidgetWrapper.java:100)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.support.v7.internal.widget.ToolbarWidgetWrapper.<init>(ToolbarWidgetWrapper.java:93)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.support.v7.internal.app.ToolbarActionBar.<init>(ToolbarActionBar.java:78)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.support.v7.app.AppCompatDelegateImplV7.setSupportActionBar(AppCompatDelegateImplV7.java:206)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.support.v7.app.AppCompatActivity.setSupportActionBar(AppCompatActivity.java:99)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at com.example.ospunelap_130.testneha.AppTest.AppTest1.onCreate(AppTest1.java:22)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.Activity.performCreate(Activity.java:6237)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.-wrap11(ActivityThread.java)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
11-03 04:35:03.159 2055-2055/com.example.ospunelap_130.testneha E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
11-03 04:35:07.335 2055-2055/com.example.ospunelap_130.testneha I/Process: Sending signal. PID: 2055 SIG: 9
EDIT:
The error is due to invoking toolbar.getTitle() method. The toolbar object is returning null. Try this:
Toolbar toolbar = (Toolbar) findviewById(R.id.toolbar);
to initialize the toolbar. The error is at line no. 22 according to logcat.
i have try to set the dropdown color for the autocomplete text view it works fine in all other api but when ever i run it with the nexus 5 marshmallows i got the following error
my log cat is
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: FATAL EXCEPTION: main
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: Process: test.text.com, PID: 29058
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: java.lang.NullPointerException: Attempt to invoke virtual method 'android.graphics.drawable.Drawable android.support.v7.internal.widget.TintManager.getDrawable(int)' on a null object reference
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.support.v7.widget.AppCompatAutoCompleteTextView.setDropDownBackgroundResource(AppCompatAutoCompleteTextView.java:96)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at test.text.com.activity.CreateRideActivity.onWindowFocusChanged(CreateRideActivity.java:369)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.support.v7.internal.view.WindowCallbackWrapper.onWindowFocusChanged(WindowCallbackWrapper.java:114)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.support.v7.internal.view.WindowCallbackWrapper.onWindowFocusChanged(WindowCallbackWrapper.java:114)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at com.android.internal.policy.PhoneWindow$DecorView.onWindowFocusChanged(PhoneWindow.java:3237)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.view.View.dispatchWindowFocusChanged(View.java:9528)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.view.ViewGroup.dispatchWindowFocusChanged(ViewGroup.java:1200)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.view.ViewRootImpl$ViewRootHandler.handleMessage(ViewRootImpl.java:3378)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.os.Handler.dispatchMessage(Handler.java:102)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.os.Looper.loop(Looper.java:148)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at android.app.ActivityThread.main(ActivityThread.java:5417)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at java.lang.reflect.Method.invoke(Native Method)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
11-02 17:36:23.815 29058-29058/test.text.com E/AndroidRuntime: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
My code is
AutoSuggestView.setDropDownBackgroundResource(R.drawable.bg_rectangle_white_curve_border_right);
Try to update your appcompat libraries. In the current (23.1.1) version of appcompat-v7 the code in AppCompatAutoCompleteTextView was changed to resolve this like so
public void setDropDownBackgroundResource(#DrawableRes int resId) {
if (mTintManager != null) {
setDropDownBackgroundDrawable(mTintManager.getDrawable(resId));
} else {
super.setDropDownBackgroundResource(resId);
}
}
As you can tell I am a newbie to Android :) and struggling with retrieving contacts list. I did add android.permission.READ_CONTACTS in AndroidManifest.xml but still it is not working. I am running it on Windows 10, in case if that makes any difference. Thanks in advance.
09-07 17:27:15.819 5272-5272/? I/art﹕ Not late-enabling -Xcheck:jni (already on)
09-07 17:27:15.819 5272-5272/? I/art﹕ Late-enabling JIT
09-07 17:27:15.821 5272-5272/? I/art﹕ JIT created with code_cache_capacity=2MB compile_threshold=1000
09-07 17:27:15.871 5272-5272/com.sr.phonecontactslist W/System﹕ ClassLoader referenced unknown path: /data/app/com.sr.phonecontactslist-1/lib/x86
09-07 17:27:15.879 5272-5272/com.sr.phonecontactslist D/AndroidRuntime﹕ Shutting down VM
09-07 17:27:15.879 5272-5272/com.sr.phonecontactslist E/AndroidRuntime﹕ FATAL EXCEPTION: main
Process: com.sr.phonecontactslist, PID: 5272
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.sr.phonecontactslist/com.sr.phonecontactslist.MainActivity}: java.lang.SecurityException: Permission Denial: opening provider com.android.providers.contacts.ContactsProvider2 from ProcessRecord{15540fd 5272:com.sr.phonecontactslist/u0a59} (pid=5272, uid=10059) requires android.permission.READ_CONTACTS or android.permission.WRITE_CONTACTS
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2416)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
Caused by: java.lang.SecurityException: Permission Denial: opening provider com.android.providers.contacts.ContactsProvider2 from ProcessRecord{15540fd 5272:com.sr.phonecontactslist/u0a59} (pid=5272, uid=10059) requires android.permission.READ_CONTACTS or android.permission.WRITE_CONTACTS
at android.os.Parcel.readException(Parcel.java:1599)
at android.os.Parcel.readException(Parcel.java:1552)
at android.app.ActivityManagerProxy.getContentProvider(ActivityManagerNative.java:3550)
at android.app.ActivityThread.acquireProvider(ActivityThread.java:4778)
at android.app.ContextImpl$ApplicationContentResolver.acquireUnstableProvider(ContextImpl.java:2018)
at android.content.ContentResolver.acquireUnstableProvider(ContentResolver.java:1468)
at android.content.ContentResolver.query(ContentResolver.java:475)
at android.content.ContentResolver.query(ContentResolver.java:434)
at com.sr.phonecontactslist.MainActivity.onCreate(MainActivity.java:20)
at android.app.Activity.performCreate(Activity.java:6237)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1107)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2369)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2476)
at android.app.ActivityThread.-wrap11(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1344)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)