Related
I have just build a project with android kotlin but when I run the app it got crash, and in the logcat I found this error
java.lang.NullPointerException: DataBindingUtil.setConte….layout.activity_chapter) must not be null
ChapterActivity.kt
import android.os.Bundle
import androidx.appcompat.app.AppCompatActivity
import androidx.databinding.DataBindingUtil
import androidx.recyclerview.widget.DividerItemDecoration
import androidx.recyclerview.widget.LinearLayoutManager
import com.tutorial.kotlinfirebasecomicreader.Common.Common
import com.tutorial.kotlinfirebasecomicreader.Model.Comic
import com.tutorial.kotlinfirebasecomicreader.databinding.ActivityChapterBinding
class ChapterActivity : AppCompatActivity() {
private lateinit var binding: ActivityChapterBinding
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
binding = DataBindingUtil.setContentView(this, R.layout.activity_chapter)
binding.toolbar.title = Common.selected_comic!!.Name
binding.toolbar.setNavigationIcon(R.drawable.ic_baseline_chevron_left_24)
binding.toolbar.setNavigationOnClickListener {
finish() //GO BACK
}
binding.recyclerChapter.setHasFixedSize(true)
val layoutManager = LinearLayoutManager(this#ChapterActivity)
binding.recyclerChapter.layoutManager = layoutManager
binding.recyclerChapter.addItemDecoration(DividerItemDecoration(this, layoutManager.orientation))
fetchChapter (Common.selected_comic!!)
}
private fun fetchChapter(comic: Comic) {
Common.chapterList = comic.Chapters!!
binding.txtChapterName.text = StringBuilder("Chapter (")
.append(comic.Chapters!!.size)
.append(")")
}
}
I don't really know how to fix it and I need some help
Edited =>
activity_chapter.xml
<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools">
<data>
</data>
<LinearLayout
android:orientation="vertical"
android:background="#android:color/white"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".ChapterActivity">
<androidx.appcompat.widget.Toolbar
android:id="#+id/toolbar"
android:minHeight="?attr/actionBarSize"
app:titleTextColor="#color/textColor"
android:background="#color/columnColor"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<LinearLayout
android:orientation="horizontal"
android:padding="16dp"
android:weightSum="4"
android:background="#color/black"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<TextView
android:id="#+id/txt_chapter_name"
android:text="Chapter (10)"
android:textColor="#color/textColor"
android:textSize="20sp"
android:textStyle="bold"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
<androidx.recyclerview.widget.RecyclerView
android:id="#+id/recycler_chapter"
android:padding="8dp"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</LinearLayout>
</layout>
Stack Trace =>
2021-03-04 11:55:23.033 11911-11911/? I/basecomicreade: Not late-enabling -Xcheck:jni (already on)
2021-03-04 11:55:23.106 11911-11911/? I/basecomicreade: Unquickening 13 vdex files!
2021-03-04 11:55:23.108 11911-11911/? W/basecomicreade: Unexpected CPU variant for X86 using defaults: x86_64
2021-03-04 11:55:23.913 11911-11911/com.tutorial.kotlinfirebasecomicreader W/ComponentDiscovery: Class com.google.firebase.dynamicloading.DynamicLoadingRegistrar is not an found.
2021-03-04 11:55:23.933 11911-11911/com.tutorial.kotlinfirebasecomicreader I/FirebaseApp: Device unlocked: initializing all Firebase APIs for app [DEFAULT]
2021-03-04 11:55:23.957 11911-11911/com.tutorial.kotlinfirebasecomicreader I/FirebaseInitProvider: FirebaseApp initialization successful
2021-03-04 11:55:24.001 11911-11932/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Unsupported class loader
2021-03-04 11:55:24.010 11911-11932/com.tutorial.kotlinfirebasecomicreader I/DynamiteModule: Considering local module com.google.android.gms.measurement.dynamite:46 and remote module com.google.android.gms.measurement.dynamite:45
2021-03-04 11:55:24.010 11911-11932/com.tutorial.kotlinfirebasecomicreader I/DynamiteModule: Selected local version of com.google.android.gms.measurement.dynamite
2021-03-04 11:55:24.053 11911-11937/com.tutorial.kotlinfirebasecomicreader D/libEGL: loaded /vendor/lib64/egl/libEGL_emulation.so
2021-03-04 11:55:24.055 11911-11937/com.tutorial.kotlinfirebasecomicreader D/libEGL: loaded /vendor/lib64/egl/libGLESv1_CM_emulation.so
2021-03-04 11:55:24.062 11911-11937/com.tutorial.kotlinfirebasecomicreader D/libEGL: loaded /vendor/lib64/egl/libGLESv2_emulation.so
2021-03-04 11:55:24.160 11911-11911/com.tutorial.kotlinfirebasecomicreader D/skia: Warning: an opaque image should be decoded as opaque - it is being decoded as non-opaque, which will draw slower
2021-03-04 11:55:24.200 11911-11932/com.tutorial.kotlinfirebasecomicreader V/FA: onActivityCreated
2021-03-04 11:55:24.250 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: App measurement collection enabled
2021-03-04 11:55:24.254 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: App measurement enabled for app package, google app id: com.tutorial.kotlinfirebasecomicreader, 1:705167416733:android:e2429adee28166ea782374
2021-03-04 11:55:24.256 11911-11938/com.tutorial.kotlinfirebasecomicreader I/FA: App measurement initialized, version: 39000
2021-03-04 11:55:24.256 11911-11938/com.tutorial.kotlinfirebasecomicreader I/FA: To enable debug logging run: adb shell setprop log.tag.FA VERBOSE
2021-03-04 11:55:24.257 11911-11938/com.tutorial.kotlinfirebasecomicreader I/FA: To enable faster debug mode event logging run:
adb shell setprop debug.firebase.analytics.app com.tutorial.kotlinfirebasecomicreader
2021-03-04 11:55:24.257 11911-11938/com.tutorial.kotlinfirebasecomicreader D/FA: Debug-level message logging enabled
2021-03-04 11:55:24.287 11911-11911/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Accessing hidden method Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z (greylist, reflection, allowed)
2021-03-04 11:55:24.288 11911-11911/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Accessing hidden method Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (greylist, reflection, allowed)
2021-03-04 11:55:24.354 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Connecting to remote service
2021-03-04 11:55:24.420 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Connection attempt already in progress
2021-03-04 11:55:24.476 11911-11935/com.tutorial.kotlinfirebasecomicreader D/HostConnection: HostConnection::get() New Host Connection established 0x7d323924d620, tid 11935
2021-03-04 11:55:24.490 11911-11935/com.tutorial.kotlinfirebasecomicreader D/HostConnection: HostComposition ext ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_native_sync_v2 ANDROID_EMU_dma_v1 ANDROID_EMU_direct_mem ANDROID_EMU_host_composition_v1 ANDROID_EMU_host_composition_v2 ANDROID_EMU_YUV_Cache ANDROID_EMU_async_unmap_buffer GL_OES_EGL_image_external_essl3 GL_OES_vertex_array_object GL_KHR_texture_compression_astc_ldr ANDROID_EMU_host_side_tracing ANDROID_EMU_async_frame_commands ANDROID_EMU_gles_max_version_3_0
2021-03-04 11:55:24.507 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Connection attempt already in progress
2021-03-04 11:55:24.509 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Activity resumed, time: 57788511
2021-03-04 11:55:24.600 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglCreateContext: 0x7d323924e840: maj 3 min 0 rcv 3
2021-03-04 11:55:24.680 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:24.690 11911-11938/com.tutorial.kotlinfirebasecomicreader I/FA: Tag Manager is not found and thus will not be used
2021-03-04 11:55:24.706 11911-11935/com.tutorial.kotlinfirebasecomicreader I/Gralloc4: mapper 4.x is not supported
2021-03-04 11:55:24.707 11911-11935/com.tutorial.kotlinfirebasecomicreader W/Gralloc3: mapper 3.x is not supported
2021-03-04 11:55:24.712 11911-11935/com.tutorial.kotlinfirebasecomicreader D/HostConnection: createUnique: call
2021-03-04 11:55:24.712 11911-11935/com.tutorial.kotlinfirebasecomicreader D/HostConnection: HostConnection::get() New Host Connection established 0x7d323924eac0, tid 11935
2021-03-04 11:55:24.713 11911-11935/com.tutorial.kotlinfirebasecomicreader D/eglCodecCommon: allocate: Ask for block of size 0x100
2021-03-04 11:55:24.713 11911-11935/com.tutorial.kotlinfirebasecomicreader D/eglCodecCommon: allocate: ioctl allocate returned offset 0x3fe042000 size 0x2000
2021-03-04 11:55:24.716 11911-11935/com.tutorial.kotlinfirebasecomicreader D/HostConnection: HostComposition ext ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_native_sync_v2 ANDROID_EMU_dma_v1 ANDROID_EMU_direct_mem ANDROID_EMU_host_composition_v1 ANDROID_EMU_host_composition_v2 ANDROID_EMU_YUV_Cache ANDROID_EMU_async_unmap_buffer GL_OES_EGL_image_external_essl3 GL_OES_vertex_array_object GL_KHR_texture_compression_astc_ldr ANDROID_EMU_host_side_tracing ANDROID_EMU_async_frame_commands ANDROID_EMU_gles_max_version_3_0
2021-03-04 11:55:24.730 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:24.795 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Connection attempt already in progress
2021-03-04 11:55:24.797 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Connection attempt already in progress
2021-03-04 11:55:25.306 11911-11935/com.tutorial.kotlinfirebasecomicreader I/OpenGLRenderer: Davey! duration=900ms; Flags=1, IntendedVsync=57788545708266, Vsync=57788579041598, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=57788595779340, AnimationStart=57788595852830, PerformTraversalsStart=57788595904150, DrawStart=57788869782150, SyncQueued=57788872423620, SyncStart=57788883887770, IssueDrawCommandsStart=57788884972440, SwapBuffers=57789368117580, FrameCompleted=57789457618760, DequeueBufferDuration=307500, QueueBufferDuration=1103560, GpuCompleted=0,
2021-03-04 11:55:25.576 11911-11938/com.tutorial.kotlinfirebasecomicreader D/FA: Connected to remote service
2021-03-04 11:55:25.577 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Processing queued up service tasks: 5
2021-03-04 11:55:27.569 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Recording user engagement, ms: 3024
2021-03-04 11:55:27.599 11911-11932/com.tutorial.kotlinfirebasecomicreader V/FA: onActivityCreated
2021-03-04 11:55:27.787 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Activity paused, time: 57791583
2021-03-04 11:55:27.924 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Activity resumed, time: 57792074
2021-03-04 11:55:27.986 11911-11946/com.tutorial.kotlinfirebasecomicreader D/NetworkSecurityConfig: No Network Security Config specified, using platform default
2021-03-04 11:55:27.994 11911-11911/com.tutorial.kotlinfirebasecomicreader E/RecyclerView: No adapter attached; skipping layout
2021-03-04 11:55:28.090 11911-11946/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Verification of java.util.Set com.android.org.conscrypt.SSLUtils.getSupportedClientKeyTypes(byte[], int[]) took 100.226ms (648.53 bytecodes/s) (3304B approximate peak alloc)
2021-03-04 11:55:28.260 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:28.732 11911-11946/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Verification of boolean com.android.org.conscrypt.CertBlacklistImpl.isHex(java.lang.String) took 124.689ms (288.72 bytecodes/s) (2168B approximate peak alloc)
2021-03-04 11:55:28.836 11911-11911/com.tutorial.kotlinfirebasecomicreader I/Choreographer: Skipped 51 frames! The application may be doing too much work on its main thread.
2021-03-04 11:55:28.880 11911-11930/com.tutorial.kotlinfirebasecomicreader I/basecomicreade: Waiting for a blocking GC ProfileSaver
2021-03-04 11:55:28.887 11911-11930/com.tutorial.kotlinfirebasecomicreader I/basecomicreade: WaitForGcToComplete blocked ProfileSaver on RunEmptyCheckpoint for 7.720ms
2021-03-04 11:55:29.270 11911-11935/com.tutorial.kotlinfirebasecomicreader I/OpenGLRenderer: Davey! duration=1239ms; Flags=0, IntendedVsync=57792137367431, Vsync=57792987367397, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=57792988665860, AnimationStart=57792988801340, PerformTraversalsStart=57792989546070, DrawStart=57792989762430, SyncQueued=57792990250570, SyncStart=57792999374600, IssueDrawCommandsStart=57792999429610, SwapBuffers=57793072211200, FrameCompleted=57793385836850, DequeueBufferDuration=20442430, QueueBufferDuration=76115660, GpuCompleted=77309411328,
2021-03-04 11:55:29.691 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:29.792 11911-11935/com.tutorial.kotlinfirebasecomicreader I/OpenGLRenderer: Davey! duration=1803ms; Flags=1, IntendedVsync=57792137367431, Vsync=57792987367397, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=57792988665860, AnimationStart=57792988801340, PerformTraversalsStart=57792989546070, DrawStart=57793838734440, SyncQueued=57793840519500, SyncStart=57793843650750, IssueDrawCommandsStart=57793843800190, SwapBuffers=57793936524990, FrameCompleted=57793943762960, DequeueBufferDuration=82930, QueueBufferDuration=274660, GpuCompleted=8810055295132672,
2021-03-04 11:55:29.797 11911-11911/com.tutorial.kotlinfirebasecomicreader I/Choreographer: Skipped 57 frames! The application may be doing too much work on its main thread.
2021-03-04 11:55:29.887 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:30.096 11911-11935/com.tutorial.kotlinfirebasecomicreader I/OpenGLRenderer: Davey! duration=1062ms; Flags=0, IntendedVsync=57792995727619, Vsync=57793945727581, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=57793949431810, AnimationStart=57793949481480, PerformTraversalsStart=57793952149640, DrawStart=57793952476430, SyncQueued=57793953226090, SyncStart=57794142461760, IssueDrawCommandsStart=57794149759670, SwapBuffers=57794236027780, FrameCompleted=57794247497260, DequeueBufferDuration=296420, QueueBufferDuration=1234510, GpuCompleted=137654660947320,
2021-03-04 11:55:30.221 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:30.455 11911-11935/com.tutorial.kotlinfirebasecomicreader I/OpenGLRenderer: Davey! duration=1270ms; Flags=0, IntendedVsync=57792995727619, Vsync=57793945727581, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=57793949431810, AnimationStart=57793949481480, PerformTraversalsStart=57793952149640, DrawStart=57794142711790, SyncQueued=57794142809910, SyncStart=57794483167180, IssueDrawCommandsStart=57794483392980, SwapBuffers=57794595122060, FrameCompleted=57794606716760, DequeueBufferDuration=131380, QueueBufferDuration=409730, GpuCompleted=137657109016869,
2021-03-04 11:55:30.456 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:30.511 11911-11911/com.tutorial.kotlinfirebasecomicreader D/Slider: onImageSlideChange() called with: position = [0]
2021-03-04 11:55:30.511 11911-11911/com.tutorial.kotlinfirebasecomicreader I/SlideIndicatorsGroup: onSlideChange: 0
2021-03-04 11:55:30.515 11911-11911/com.tutorial.kotlinfirebasecomicreader I/SlideIndicatorsGroup: onSlideChange: 0
2021-03-04 11:55:30.525 11911-11911/com.tutorial.kotlinfirebasecomicreader I/Choreographer: Skipped 42 frames! The application may be doing too much work on its main thread.
2021-03-04 11:55:30.608 11911-11911/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Accessing hidden method Ldalvik/system/CloseGuard;->get()Ldalvik/system/CloseGuard; (greylist,core-platform-api, reflection, allowed)
2021-03-04 11:55:30.608 11911-11911/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Accessing hidden method Ldalvik/system/CloseGuard;->open(Ljava/lang/String;)V (greylist,core-platform-api, reflection, allowed)
2021-03-04 11:55:30.608 11911-11911/com.tutorial.kotlinfirebasecomicreader W/basecomicreade: Accessing hidden method Ldalvik/system/CloseGuard;->warnIfOpen()V (greylist,core-platform-api, reflection, allowed)
2021-03-04 11:55:30.718 11911-11935/com.tutorial.kotlinfirebasecomicreader D/EGL_emulation: eglMakeCurrent: 0x7d323924e840: ver 3 0 (tinfo 0x7d32392d78c0)
2021-03-04 11:55:31.073 11911-11935/com.tutorial.kotlinfirebasecomicreader I/OpenGLRenderer: Davey! duration=1118ms; Flags=1, IntendedVsync=57793962375754, Vsync=57794662375726, OldestInputEvent=9223372036854775807, NewestInputEvent=0, HandleInputStart=57794676994830, AnimationStart=57794677072830, PerformTraversalsStart=57794677609830, DrawStart=57794835905760, SyncQueued=57794837936740, SyncStart=57794982254730, IssueDrawCommandsStart=57794985287860, SwapBuffers=57795092878620, FrameCompleted=57795224849780, DequeueBufferDuration=215540, QueueBufferDuration=11529020, GpuCompleted=0,
2021-03-04 11:55:33.429 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Inactivity, disconnecting from the service
2021-03-04 11:55:35.432 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Recording user engagement, ms: 7288
2021-03-04 11:55:35.455 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Connecting to remote service
2021-03-04 11:55:35.460 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Activity paused, time: 57799379
2021-03-04 11:55:35.589 11911-11932/com.tutorial.kotlinfirebasecomicreader V/FA: onActivityCreated
2021-03-04 11:55:35.668 11911-11911/com.tutorial.kotlinfirebasecomicreader D/AndroidRuntime: Shutting down VM
2021-03-04 11:55:35.669 11911-11911/com.tutorial.kotlinfirebasecomicreader E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.tutorial.kotlinfirebasecomicreader, PID: 11911
java.lang.RuntimeException: Unable to start activity ComponentInfo{com.tutorial.kotlinfirebasecomicreader/com.tutorial.kotlinfirebasecomicreader.ChapterActivity}: java.lang.NullPointerException
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3344)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3488)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:83)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2049)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:216)
at android.app.ActivityThread.main(ActivityThread.java:7506)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.intern
2021-03-04 11:55:35.782 11911-11938/com.tutorial.kotlinfirebasecomicreader V/FA: Connection attempt already in progress
The documentation says that DataBindingUtil.setContentView returns:
The binding associated with the inflated content view or null if the layoutId is not a data binding layout.
So I would have to assume that your layout is not a valid data binding layout, so the issue lies in your XML.
I would recommend reading: Binding expressions which shows you the syntax of a valid binding layout and also this: Data Binding Library fully to help get a comprehensive understanding.
Also the answer by #Teo does point out the recommended way to use data binding so unless you have a specific reason for using the generic version I would switch to that.
Can try to avoid using DataBindingUtil as it keeps return null in my case.
You can try using its own databinding.inflate, as it will always get the correct binding.
binding = ActivityChapterBinding.inflate(layoutInflater)
setContentView(binding.root)
This might sound dumb, but in my case, this happened after renaming a package
and I forgot to clean the project, if databinding refuses to detect the new package name, according to this answer try to disable databinding in Build.gradle (Module), sync then re-enable it
And if you're using google-services, you'll need to adjust the naming part for the google-services.json as well.
I have an android studio project where I am using a map view fragment. In my old project, it worked well and displayed a map, but in my new one, the map is just blank (grey). Even the google logo is missing on the map.
Here is my logcat error log:
2018-11-16 13:14:20.286 1627-5883/system_process I/ActivityManager: START u0 {act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=mls.client/.clientviews.MapActivity (has extras)} from uid 10020 on display 0
--------- beginning of main
2018-11-16 13:14:20.290 1372-1392/? W/audio_hw_generic: Not supplying enough data to HAL, expected position 4547748 , only wrote 4547520
2018-11-16 13:14:20.303 6528-6528/? I/art: Not late-enabling -Xcheck:jni (already on)
2018-11-16 13:14:20.303 6528-6528/? W/art: Unexpected CPU variant for X86 using defaults: x86
2018-11-16 13:14:20.310 1627-1639/system_process I/ActivityManager: Start proc 6528:mls.client/u0a83 for activity mls.client/.clientviews.MapActivity
2018-11-16 13:14:20.330 1307-1323/? D/gralloc_ranchu: gralloc_alloc: Creating ashmem region of size 1536000
2018-11-16 13:14:20.363 2148-2359/com.android.launcher3 D/EGL_emulation: eglMakeCurrent: 0x9fae0980: ver 3 0 (tinfo 0xa0d57ee0)
2018-11-16 13:14:20.500 6528-6528/mls.client W/System: ClassLoader referenced unknown path: /data/app/mls.client-1/lib/x86
2018-11-16 13:14:20.532 6528-6528/mls.client I/InstantRun: starting instant run server: is main process
2018-11-16 13:14:20.540 6528-6544/mls.client I/GMPM: App measurement is starting up
2018-11-16 13:14:20.545 6528-6544/mls.client E/GMPM: getGoogleAppId failed with status: 10
2018-11-16 13:14:20.546 6528-6544/mls.client E/GMPM: Uploading is not possible. App measurement disabled
2018-11-16 13:14:20.609 6528-6528/mls.client I/zzy: Making Creator dynamically
2018-11-16 13:14:20.614 6528-6528/mls.client W/System: ClassLoader referenced unknown path: /system/priv-app/PrebuiltGmsCore/lib/x86
2018-11-16 13:14:20.621 6528-6528/mls.client W/System: ClassLoader referenced unknown path:
2018-11-16 13:14:20.621 6528-6528/mls.client W/System: ClassLoader referenced unknown path: /system/priv-app/PrebuiltGmsCore/lib/x86
2018-11-16 13:14:20.664 6528-6528/mls.client I/Google Maps Android API: Google Play services client version: 8298000
2018-11-16 13:14:20.667 6528-6528/mls.client I/Google Maps Android API: Google Play services package version: 12874026
2018-11-16 13:14:20.706 6528-6528/mls.client E/art: The String#value field is not present on Android versions >= 6.0
2018-11-16 13:14:20.832 6528-6557/mls.client D/NetworkSecurityConfig: No Network Security Config specified, using platform default
2018-11-16 13:14:20.899 1627-1741/system_process I/ActivityManager: START u0 {act=android.content.pm.action.REQUEST_PERMISSIONS pkg=com.google.android.packageinstaller cmp=com.google.android.packageinstaller/com.android.packageinstaller.permission.ui.GrantPermissionsActivity (has extras)} from uid 10083 on display 0
2018-11-16 13:14:20.910 1307-1355/? E/SurfaceFlinger: ro.sf.lcd_density must be defined as a build property
2018-11-16 13:14:20.982 6528-6584/mls.client I/OpenGLRenderer: Initialized EGL, version 1.4
2018-11-16 13:14:20.982 6528-6584/mls.client D/OpenGLRenderer: Swap behavior 1
2018-11-16 13:14:20.982 6528-6584/mls.client W/OpenGLRenderer: Failed to choose config with EGL_SWAP_BEHAVIOR_PRESERVED, retrying without...
2018-11-16 13:14:20.982 6528-6584/mls.client D/OpenGLRenderer: Swap behavior 0
2018-11-16 13:14:20.986 6528-6584/mls.client D/EGL_emulation: eglCreateContext: 0xa3586320: maj 3 min 0 rcv 3
2018-11-16 13:14:20.989 6528-6584/mls.client D/EGL_emulation: eglMakeCurrent: 0xa3586320: ver 3 0 (tinfo 0xa3583ae0)
2018-11-16 13:14:20.990 6528-6584/mls.client E/eglCodecCommon: glUtilsParamSize: unknow param 0x00008cdf
2018-11-16 13:14:20.991 6528-6584/mls.client E/eglCodecCommon: glUtilsParamSize: unknow param 0x00008824
2018-11-16 13:14:21.015 6528-6528/mls.client W/art: Before Android 4.1, method int android.support.v7.internal.widget.ListViewCompat.lookForSelectablePosition(int, boolean) would have incorrectly overridden the package-private method in android.widget.ListView
2018-11-16 13:14:21.024 6528-6584/mls.client D/EGL_emulation: eglMakeCurrent: 0xa3586320: ver 3 0 (tinfo 0xa3583ae0)
2018-11-16 13:14:21.099 1627-1813/system_process I/WindowManager: Destroying surface Surface(name=com.android.launcher3/com.android.launcher3.Launcher) called by com.android.server.wm.WindowStateAnimator.destroySurface:2016 com.android.server.wm.WindowStateAnimator.destroySurfaceLocked:882 com.android.server.wm.WindowState.destroyOrSaveSurface:2100 com.android.server.wm.AppWindowToken.destroySurfaces:363 com.android.server.wm.AppWindowToken.notifyAppStopped:389 com.android.server.wm.WindowManagerService.notifyAppStopped:4463 com.android.server.am.ActivityStack.activityStoppedLocked:1252 com.android.server.am.ActivityManagerService.activityStopped:6903
2018-11-16 13:14:21.109 1627-5883/system_process I/GnssLocationProvider: WakeLock acquired by sendMessage(3, 0, com.android.server.location.GnssLocationProvider$GpsRequest#88ac655)
2018-11-16 13:14:21.109 1627-1640/system_process I/GnssLocationProvider: WakeLock released by handleMessage(3, 0, com.android.server.location.GnssLocationProvider$GpsRequest#88ac655)
2018-11-16 13:14:21.111 1715-1906/com.android.systemui D/EGL_emulation: eglMakeCurrent: 0xa3585780: ver 3 0 (tinfo 0xa3583730)
2018-11-16 13:14:21.297 1627-1648/system_process I/WindowManager: Destroying surface Surface(name=Starting mls.client) called by com.android.server.wm.WindowStateAnimator.destroySurface:2016 com.android.server.wm.WindowStateAnimator.destroySurfaceLocked:882 com.android.server.wm.WindowState.destroyOrSaveSurface:2100 com.android.server.wm.AppWindowToken.destroySurfaces:363 com.android.server.wm.WindowStateAnimator.finishExit:565 com.android.server.wm.WindowStateAnimator.stepAnimationLocked:491 com.android.server.wm.WindowAnimator.updateWindowsLocked:303 com.android.server.wm.WindowAnimator.animateLocked:704
2018-11-16 13:14:22.871 6528-6581/mls.client W/DynamiteModule: Local module descriptor class for com.google.android.gms.googlecertificates not found.
2018-11-16 13:14:22.871 6528-6581/mls.client W/DynamiteModule: Failed to load module via V2: java.lang.ClassNotFoundException: Didn't find class "com.google.android.gms.dynamite.DynamiteModule$DynamiteLoaderClassLoader" on path: DexPathList[[zip file "/data/app/mls.client-1/base.apk", zip file "/data/app/mls.client-1/split_lib_dependencies_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_0_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_1_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_2_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_3_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_4_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_5_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_6_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_7_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_8_apk.apk", zip file "/data/app/mls.client-1/split_lib_slice_9_apk.apk"],nativeLibraryDirectories=[/data/app/mls.client-1/lib/x86, /system/lib, /vendor/lib]]
2018-11-16 13:14:22.875 6528-6581/mls.client I/DynamiteModule: Considering local module com.google.android.gms.googlecertificates:0 and remote module com.google.android.gms.googlecertificates:4
2018-11-16 13:14:22.875 6528-6581/mls.client I/DynamiteModule: Selected remote version of com.google.android.gms.googlecertificates, version >= 4
2018-11-16 13:14:23.516 1372-1393/? W/audio_hw_generic: Not supplying enough data to HAL, expected position 4855373 , only wrote 4702320
Any idea what is going wrong with my MapView?
if you need more info or code, please write me.
Thanks.
You need to check if the Google Maps Android API is enabled in your Developer's Console. If it is, check if you put the Android API Key in the google_maps_api.xml
go to https://console.cloud.google.com/apis/credentials
update Application restrictions with used domains and API restrictions with used API.
the changes takes more than 5 mins to reflect
I faced infinite run when I am trying using ListView with retrieving data from firebase, and I don't know how can I solve it.
My main goal is retrieving from firebase with a dynamic number of clients who have a status of "Not approved".
This my RUN
10/03 21:30:58: Launching app $ adb shell am start -n
"com.example.atheer.booklyv1/com.example.atheer.booklyv1.MainActivity"
-a android.intent.action.MAIN -c android.intent.category.LAUNCHER Client not ready yet..Waiting for process to come online Connected to
process 8309 on device emulator-5554 Capturing and displaying logcat
messages from application. This behavior can be disabled in the
"Logcat output" section of the "Debugger" settings page.
W/atheer.booklyv: JIT profile information will not be recorded:
profile file does not exits. I/chatty:
uid=10086(com.example.atheer.booklyv1) identical 10 lines
W/atheer.booklyv: JIT profile information will not be recorded:
profile file does not exits. W/atheer.booklyv: Unsupported class
loader W/atheer.booklyv: Skipping duplicate class check due to
unsupported classloader W/DynamiteModule: Local module descriptor
class for com.google.firebase.auth not found. W/DynamiteModule: Local
module descriptor class for com.google.firebase.auth not found.
W/atheer.booklyv: Verification of android.content.Intent
com.google.android.gms.common.zzf.zza(android.content.Context, int,
java.lang.String) took 130.356ms I/BiChannelGoogleApi: [FirebaseAuth:
] No Fallback module; NOT setting up for lazy initialization
D/FirebaseAuth: Notifying id token listeners about user (
N72Vpxaf6dao4pSf5cvBJ1jwzGo2 ). D/FirebaseApp:
com.google.firebase.crash.FirebaseCrash is not linked. Skipping
initialization. V/FA: Cancelling job. JobID: -1422956107 V/FA:
Registered activity lifecycle callback I/FirebaseInitProvider:
FirebaseApp initialization successful I/InstantRun: starting instant
run server: is main process V/FA: Collection enabled V/FA: App
package, google app id: com.example.atheer.booklyv1,
1:666514046827:android:60ad4570c33e1aec I/FA: App measurement is
starting up, version: 11910
To enable debug logging run: adb shell setprop log.tag.FA VERBOSE
To enable faster debug mode event logging run:
adb shell setprop debug.firebase.analytics.app com.example.atheer.booklyv1 D/FA: Debug-level message logging enabled
W/DynamiteModule: Local module descriptor class for
com.google.firebase.auth not found. V/FA: onActivityCreated V/FA:
Connecting to remote service I/FirebaseAuth: [FirebaseAuth:] Loading
module via FirebaseOptions.
[FirebaseAuth:] Preparing to create service connection to gms implementation V/FA: Connection attempt already in progress
W/atheer.booklyv: Accessing hidden method
Landroid/view/View;->computeFitSystemWindows(Landroid/graphics/Rect;Landroid/graphics/Rect;)Z
(light greylist, reflection) W/atheer.booklyv: Accessing hidden method
Landroid/view/ViewGroup;->makeOptionalFitsSystemWindows()V (light
greylist, reflection) D/OpenGLRenderer: Skia GL Pipeline V/FA:
Connection attempt already in progress
Activity resumed, time: 1574868 I/FA: Tag Manager is not found and thus will not be used D/FirebaseApp: Notifying auth state
listeners. D/FirebaseApp: Notified 0 auth state listeners. D/FA:
Logging event (FE): screen_view(_vs),
Bundle[{firebase_event_origin(_o)=auto,
firebase_screen_class(_sc)=MainActivity,
firebase_screen_id(_si)=5185910341027462403}] D/:
HostConnection::get() New Host Connection established 0xdeffec40, tid
8354 I/ConfigStore:
android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasWideColorDisplay
retrieved: 0
android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay
retrieved: 0 I/OpenGLRenderer: Initialized EGL, version 1.4
D/OpenGLRenderer: Swap behavior 1 W/OpenGLRenderer: Failed to choose
config with EGL_SWAP_BEHAVIOR_PRESERVED, retrying without...
D/OpenGLRenderer: Swap behavior 0 D/EGL_emulation: eglCreateContext:
0xcc20f240: maj 3 min 0 rcv 3 D/EGL_emulation: eglMakeCurrent:
0xcc20f240: ver 3 0 (tinfo 0xe2730c60) D/EGL_emulation:
eglMakeCurrent: 0xcc20f240: ver 3 0 (tinfo 0xe2730c60) V/FA:
Connection attempt already in progress D/FA: Connected to remote
service V/FA: Processing queued up service tasks: 4 V/StudioProfiler:
StudioProfilers agent attached. V/StudioProfiler: Acquiring
Application for Events V/StudioProfiler: Transformed class:
java/net/URL W/atheer.booklyv: Current dex file has more than one
class in it. Calling RetransformClasses on this class might fail if no
transformations are applied to it! V/StudioProfiler: Memory control
stream started. V/StudioProfiler: Live memory tracking disabled.
V/StudioProfiler: Live memory tracking enabled.
JNIEnv not attached V/StudioProfiler: Loaded classes: 11553 V/StudioProfiler: Tracking initialization took:
410566000ns W/ActivityThread: handleWindowVisibility: no activity for
token android.os.BinderProxy#f188cbd V/FA: Recording user engagement,
ms: 4164 V/FA: Activity paused, time: 1579010 V/FA: onActivityCreated
I/atheer.booklyv: Background concurrent copying GC freed 662(4MB)
AllocSpace objects, 0(0B) LOS objects, 49% free, 3MB/6MB, paused
1.122ms total 328.178ms D/FA: Logging event (FE): user_engagement(_e), Bundle[{firebase_event_origin(_o)=auto,
engagement_time_msec(_et)=4164,
firebase_screen_class(_sc)=MainActivity,
firebase_screen_id(_si)=5185910341027462403}] V/FA: Activity resumed,
time: 1580197 D/FA: Logging event (FE): screen_view(_vs),
Bundle[{firebase_event_origin(_o)=auto,
firebase_previous_class(_pc)=MainActivity,
firebase_previous_id(_pi)=5185910341027462403,
firebase_screen_class(_sc)=mHomePage,
firebase_screen_id(_si)=5185910341027462404}] D/EGL_emulation:
eglMakeCurrent: 0xcc20f240: ver 3 0 (tinfo 0xe2730c60)
W/ActivityThread: handleWindowVisibility: no activity for token
android.os.BinderProxy#877a26c V/FA: Recording user engagement, ms:
4828 V/FA: Activity paused, time: 1585022 V/FA: onActivityCreated
D/FA: Logging event (FE): user_engagement(_e),
Bundle[{firebase_event_origin(_o)=auto,
engagement_time_msec(_et)=4828, firebase_screen_class(_sc)=mHomePage,
firebase_screen_id(_si)=5185910341027462404}] I/DynamiteModule:
Considering local module com.google.android.gms.firebase_database:4
and remote module com.google.android.gms.firebase_database:6
Selected remote version of com.google.android.gms.firebase_database, version >= 6 V/FA: Activity
resumed, time: 1585685 I/Choreographer: Skipped 37 frames! The
application may be doing too much work on its main thread.
W/atheer.booklyv: Unsupported class loader W/atheer.booklyv: Skipping
duplicate class check due to unsupported classloader D/FA: Logging
event (FE): screen_view(_vs), Bundle[{firebase_event_origin(_o)=auto,
firebase_previous_class(_pc)=mHomePage,
firebase_previous_id(_pi)=5185910341027462404,
firebase_screen_class(_sc)=loginActivity,
firebase_screen_id(_si)=5185910341027462405}] I/OpenGLRenderer: Davey!
duration=916ms; Flags=1, IntendedVsync=1585088907737,
Vsync=1585705574379, OldestInputEvent=9223372036854775807,
NewestInputEvent=0, HandleInputStart=1585721516670,
AnimationStart=1585721565670, PerformTraversalsStart=1585722412670,
DrawStart=1586003516670, SyncQueued=1586003568670,
SyncStart=1586003659670, IssueDrawCommandsStart=1586003710670,
SwapBuffers=1586004070670, FrameCompleted=1586005330670,
DequeueBufferDuration=162000, QueueBufferDuration=300000,
D/EGL_emulation: eglMakeCurrent: 0xcc20f240: ver 3 0 (tinfo
0xe2730c60) D/NetworkSecurityConfig: No Network Security Config
specified, using platform default I/AssistStructure: Flattened final
assist data: 3404 bytes, containing 1 windows, 11 views V/FA:
Inactivity, disconnecting from the service I/AssistStructure:
Flattened final assist data: 3428 bytes, containing 1 windows, 11
views W/BiChannelGoogleApi: [FirebaseAuth: ] getGoogleApiForMethod()
returned Gms D/FirebaseAuth: Notifying id token listeners about user (
N72Vpxaf6dao4pSf5cvBJ1jwzGo2 ). D/FirebaseApp: Notifying auth state
listeners. D/FirebaseApp: Notified 1 auth state listeners. V/FA:
Recording user engagement, ms: 21363 V/FA: Connecting to remote
service W/ActivityThread: handleWindowVisibility: no activity for
token android.os.BinderProxy#48f31b0 V/FA: Activity paused, time:
1607047 D/FA: Logging event (FE): user_engagement(_e),
Bundle[{firebase_event_origin(_o)=auto,
engagement_time_msec(_et)=21363,
firebase_screen_class(_sc)=loginActivity,
firebase_screen_id(_si)=5185910341027462405}] V/FA: onActivityCreated
V/FA: Connection attempt already in progress I/atheer.booklyv:
NativeAlloc concurrent copying GC freed 25494(1649KB) AllocSpace
objects, 19(632KB) LOS objects, 50% free, 3MB/7MB, paused 580us total
742.771ms V/FA: Connection attempt already in progress V/FA: Activity resumed, time: 1608103 D/FA: Logging event (FE): screen_view(_vs),
Bundle[{firebase_event_origin(_o)=auto,
firebase_previous_class(_pc)=loginActivity,
firebase_previous_id(_pi)=5185910341027462405,
firebase_screen_class(_sc)=dashboardAdmin,
firebase_screen_id(_si)=5185910341027462406}] D/EGL_emulation:
eglMakeCurrent: 0xcc20f240: ver 3 0 (tinfo 0xe2730c60) V/FA:
Connection attempt already in progress D/FA: Connected to remote
service V/FA: Processing queued up service tasks: 4 W/ActivityThread:
handleWindowVisibility: no activity for token
android.os.BinderProxy#7f475a4 V/FA: Recording user engagement, ms:
5136 V/FA: Activity paused, time: 1613235 D/FA: Logging event (FE):
user_engagement(_e), Bundle[{firebase_event_origin(_o)=auto,
engagement_time_msec(_et)=5136,
firebase_screen_class(_sc)=dashboardAdmin,
firebase_screen_id(_si)=5185910341027462406}] V/FA: onActivityCreated
V/FA: Activity resumed, time: 1613594 D/FA: Logging event (FE):
screen_view(_vs), Bundle[{firebase_event_origin(_o)=auto,
firebase_previous_class(_pc)=dashboardAdmin,
firebase_previous_id(_pi)=5185910341027462406,
firebase_screen_class(_sc)=approvedAdmin,
firebase_screen_id(_si)=5185910341027462407}] D/EGL_emulation:
eglMakeCurrent: 0xcc20f240: ver 3 0 (tinfo 0xe2730c60)
D/EGL_emulation: eglMakeCurrent: 0xcc20f240: ver 3 0 (tinfo
0xe2730c60) W/atheer.booklyv: Long wait of 5.943ms for
Thread[1,tid=8309,Native,Thread*=0xe6674000,peer=0x738f9ec8,"main"]
suspension! D/EGL_emulation: eglMakeCurrent: 0xcc20f240: ver 3 0
(tinfo 0xe2730c60) D/EGL_emulation: eglMakeCurrent: 0xcc20f240: ver 3
0 (tinfo 0xe2730c60) D/EGL_emulation: eglMakeCurrent: 0xcc20f240: ver
3 0 (tinfo 0xe2730c60) V/FA: Inactivity, disconnecting from the
service E/StudioProfiler: JVMTI error:
15(JVMTI_ERROR_THREAD_NOT_ALIVE) I/chatty:
uid=10086(com.example.atheer.booklyv1) Binder:8309_5 identical 3 lines
E/StudioProfiler: JVMTI error: 15(JVMTI_ERROR_THREAD_NOT_ALIVE)
I/FirebaseAuth: [FirebaseAuth:] Loading module via FirebaseOptions.
I/FirebaseAuth: [FirebaseAuth:] Preparing to create service connection
to gms implementation
And this is my java code
package com.example.atheer.booklyv1;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;
import android.widget.ArrayAdapter;
import android.widget.ListView;
import android.widget.TextView;
import android.widget.Toast;
import com.google.firebase.database.ChildEventListener;
import com.google.firebase.database.DataSnapshot;
import com.google.firebase.database.DatabaseError;
import com.google.firebase.database.DatabaseReference;
import com.google.firebase.database.FirebaseDatabase;
import com.google.firebase.database.ValueEventListener;
import java.util.ArrayList;
import java.util.Map;
public class approvedAdmin extends AppCompatActivity implements View.OnClickListener{
DatabaseReference dref;
ListView listview;
ArrayList<String> list=new ArrayList<>();
ArrayAdapter<String> adapter;
public approvedAdmin() {
}
#Override
protected void onCreate(Bundle savedInstanceState){
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_approved_admin);
listview=(ListView)findViewById(R.id.list);
dref= FirebaseDatabase.getInstance().getReference("client");
// adapter.notifyDataSetChanged();
dref.addChildEventListener(new ChildEventListener() {
#Override
public void onChildAdded(DataSnapshot dataSnapshot, String s) {
String status;
String name;
String email;
Toast.makeText(approvedAdmin.this, "ok", Toast.LENGTH_SHORT).show();
for(DataSnapshot ds: dataSnapshot.getChildren() ){
if (ds.hasChild("Status")){
status=ds.child("Status").getValue(String.class);
if (status.equalsIgnoreCase("Not approved")){
name= ds.child("name").getValue(String.class);
list.add(name);
adapter= new ArrayAdapter<String>(approvedAdmin.this, android.R.layout.simple_list_item_1, list);
listview.setAdapter(adapter);
}}
}}
#Override
public void onChildChanged(DataSnapshot dataSnapshot, String s) {
}
#Override
public void onChildRemoved(DataSnapshot dataSnapshot) {
}
#Override
public void onChildMoved(DataSnapshot dataSnapshot, String s) {
}
#Override
public void onCancelled(DatabaseError databaseError) {
}
});
}
#Override
public void onClick(View v) {
}
}
And this is my xml code
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".approvedAdmin">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:orientation="vertical"
android:paddingLeft="15dp"
android:paddingRight="15dp">
<ListView
android:id="#android:id/list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
/>
</LinearLayout>
</android.support.constraint.ConstraintLayout>
You need to move out setting up adapter code out from for loop, like below
for(DataSnapshot ds: dataSnapshot.getChildren() ){
if (ds.hasChild("Status")){
status=ds.child("Status").getValue(String.class);
if (status.equalsIgnoreCase("Not approved")){
name= ds.child("name").getValue(String.class);
list.add(name);
}
}
}
adapter= new ArrayAdapter<String>(approvedAdmin.this, android.R.layout.simple_list_item_1, list);
listview.setAdapter(adapter);
You also need to change the listview id from android:id="#android:id/list" to android:id="#+id/list"
This question already has answers here:
What is a NullPointerException, and how do I fix it?
(12 answers)
Closed 5 years ago.
I just finished a project in android studio and I have a problem here. When generating the application and installing on the smartphone (android nougat 7.1.1 oneplus3) it simply aborts. In the emulator it gives the message that the application stops and aborts. I need the help of you more experienced. I'm a beginner. Here's the LOGCAT lines below when you try to open the application:
08-16 13:51:44.610 13313-13313/agdesenvolvimentoweb.projetopiloto I/art: Not late-enabling -Xcheck:jni (already on)
08-16 13:51:44.610 13313-13313/agdesenvolvimentoweb.projetopiloto W/art: Unexpected CPU variant for X86 using defaults: x86_64
08-16 13:51:45.249 13313-13313/agdesenvolvimentoweb.projetopiloto W/System: ClassLoader referenced unknown path: /data/app/agdesenvolvimentoweb.projetopiloto-1/lib/x86_64
08-16 13:51:45.281 13313-13313/agdesenvolvimentoweb.projetopiloto I/InstantRun: starting instant run server: is main process
08-16 13:51:45.576 13313-13313/agdesenvolvimentoweb.projetopiloto W/art: Before Android 4.1, method android.graphics.PorterDuffColorFilter android.support.graphics.drawable.VectorDrawableCompat.updateTintFilter(android.graphics.PorterDuffColorFilter, android.content.res.ColorStateList, android.graphics.PorterDuff$Mode) would have incorrectly overridden the package-private method in android.graphics.drawable.Drawable
08-16 13:51:45.647 13313-13313/agdesenvolvimentoweb.projetopiloto W/System: ClassLoader referenced unknown path: /system/app/Chrome/lib/x86_64
08-16 13:51:45.648 13313-13313/agdesenvolvimentoweb.projetopiloto D/ApplicationLoaders: ignored Vulkan layer search path /system/app/Chrome/lib/x86_64:/system/app/Chrome/Chrome.apk!/lib/x86_64:/system/lib64:/vendor/lib64 for namespace 0x7fcbeb8400f0
08-16 13:51:45.650 13313-13313/agdesenvolvimentoweb.projetopiloto I/WebViewFactory: Loading com.android.chrome version 55.0.2883.91 (code 288309162)
08-16 13:51:45.670 13313-13313/agdesenvolvimentoweb.projetopiloto I/cr_LibraryLoader: Time to load native libraries: 2 ms (timestamps 9774-9776)
08-16 13:51:45.670 13313-13313/agdesenvolvimentoweb.projetopiloto I/cr_LibraryLoader: Expected native library version number "55.0.2883.91", actual native library version number "55.0.2883.91"
08-16 13:51:45.678 13313-13313/agdesenvolvimentoweb.projetopiloto I/cr_LibraryLoader: Expected native library version number "55.0.2883.91", actual native library version number "55.0.2883.91"
08-16 13:51:45.678 13313-13313/agdesenvolvimentoweb.projetopiloto I/chromium: [INFO:library_loader_hooks.cc(163)] Chromium logging enabled: level = 0, default verbosity = 0
08-16 13:51:45.683 13313-13313/agdesenvolvimentoweb.projetopiloto I/cr_BrowserStartup: Initializing chromium process, singleProcess=true
[ 08-16 13:51:45.692 13313:13313 D/ ]
HostConnection::get() New Host Connection established 0x7fcbd18d6000, tid 13313
[ 08-16 13:51:45.694 13313:13313 W/ ]
Unrecognized GLES max version string in extensions: ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_dma_v1
08-16 13:51:45.696 13313-13313/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglCreateContext: 0x7fcbde5c12a0: maj 2 min 0 rcv 2
08-16 13:51:45.697 13313-13313/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglMakeCurrent: 0x7fcbde5c12a0: ver 2 0 (tinfo 0x7fcbd18f1c20)
08-16 13:51:45.798 13313-13359/agdesenvolvimentoweb.projetopiloto W/cr_media: Requires BLUETOOTH permission
08-16 13:51:45.807 13313-13313/agdesenvolvimentoweb.projetopiloto I/cr_Ime: ImeThread is enabled.
08-16 13:51:45.885 13313-13368/agdesenvolvimentoweb.projetopiloto I/OpenGLRenderer: Initialized EGL, version 1.4
08-16 13:51:45.885 13313-13368/agdesenvolvimentoweb.projetopiloto D/OpenGLRenderer: Swap behavior 1
[ 08-16 13:51:45.885 13313:13368 D/ ]
HostConnection::get() New Host Connection established 0x7fcbcdea13c0, tid 13368
[ 08-16 13:51:45.888 13313:13368 W/ ]
Unrecognized GLES max version string in extensions: ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_dma_v1
08-16 13:51:45.892 13313-13368/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglCreateContext: 0x7fcbcdf532c0: maj 2 min 0 rcv 2
08-16 13:51:45.904 13313-13368/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglMakeCurrent: 0x7fcbcdf532c0: ver 2 0 (tinfo 0x7fcbcdfb3920)
08-16 13:51:45.979 13313-13374/agdesenvolvimentoweb.projetopiloto E/libEGL: validate_display:99 error 3008 (EGL_BAD_DISPLAY)
[ 08-16 13:51:45.980 13313:13374 D/ ]
HostConnection::get() New Host Connection established 0x7fcbcd52f2e0, tid 13374
[ 08-16 13:51:45.982 13313:13374 W/ ]
Unrecognized GLES max version string in extensions: ANDROID_EMU_CHECKSUM_HELPER_v1 ANDROID_EMU_dma_v1
08-16 13:51:45.995 13313-13374/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglCreateContext: 0x7fcbcdf55ca0: maj 2 min 0 rcv 2
08-16 13:51:45.998 13313-13374/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglMakeCurrent: 0x7fcbcdf55ca0: ver 2 0 (tinfo 0x7fcbcd54d900)
08-16 13:51:46.018 13313-13313/agdesenvolvimentoweb.projetopiloto W/art: Before Android 4.1, method int android.support.v7.widget.ListViewCompat.lookForSelectablePosition(int, boolean) would have incorrectly overridden the package-private method in android.widget.ListView
08-16 13:51:46.050 13313-13313/agdesenvolvimentoweb.projetopiloto W/art: Attempt to remove non-JNI local reference, dumping thread
08-16 13:51:46.054 13313-13368/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglMakeCurrent: 0x7fcbcdf532c0: ver 2 0 (tinfo 0x7fcbcdfb3920)
08-16 13:51:46.067 13313-13374/agdesenvolvimentoweb.projetopiloto I/VideoCapabilities: Unsupported profile 4 for video/mp4v-es
08-16 13:51:46.088 13313-13324/agdesenvolvimentoweb.projetopiloto W/art: Suspending all threads took: 12.371ms
08-16 13:51:46.167 13313-13374/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglCreateContext: 0x7fcbcdf569c0: maj 2 min 0 rcv 2
08-16 13:51:46.169 13313-13374/agdesenvolvimentoweb.projetopiloto D/EGL_emulation: eglMakeCurrent: 0x7fcbcdf569c0: ver 2 0 (tinfo 0x7fcbcd54d900)
08-16 13:51:46.175 13313-13374/agdesenvolvimentoweb.projetopiloto E/eglCodecCommon: glUtilsParamSize: unknow param 0x00008cdf
08-16 13:51:46.176 13313-13374/agdesenvolvimentoweb.projetopiloto E/eglCodecCommon: glUtilsParamSize: unknow param 0x00008824
08-16 13:51:46.176 13313-13374/agdesenvolvimentoweb.projetopiloto E/eglCodecCommon: glUtilsParamSize: unknow param 0x00008cdf
08-16 13:51:46.176 13313-13374/agdesenvolvimentoweb.projetopiloto E/eglCodecCommon: glUtilsParamSize: unknow param 0x00008824
08-16 13:51:46.180 13313-13374/agdesenvolvimentoweb.projetopiloto E/libEGL: called unimplemented OpenGL ES API
08-16 13:51:46.707 13313-13313/agdesenvolvimentoweb.projetopiloto W/cr_BindingManager: Cannot call determinedVisibility() - never saw a connection for the pid: 13313
08-16 13:51:46.709 13313-13313/agdesenvolvimentoweb.projetopiloto I/Choreographer: Skipped 40 frames! The application may be doing too much work on its main thread.
08-16 13:51:46.716 13313-13313/agdesenvolvimentoweb.projetopiloto W/art: Attempt to remove non-JNI local reference, dumping thread
08-16 13:51:46.752 13313-13313/agdesenvolvimentoweb.projetopiloto E/chromium: [ERROR:interface_registry.cc(104)] Failed to locate a binder for interface: autofill::mojom::PasswordManagerDriver
08-16 13:51:46.753 13313-13313/agdesenvolvimentoweb.projetopiloto D/AndroidRuntime: Shutting down VM
--------- beginning of crash
08-16 13:51:46.753 13313-13313/agdesenvolvimentoweb.projetopiloto E/AndroidRuntime: FATAL EXCEPTION: main
Process: agdesenvolvimentoweb.projetopiloto, PID: 13313
java.lang.NullPointerException: Attempt to invoke virtual method 'void android.app.ProgressDialog.dismiss()' on a null object reference
at agdesenvolvimentoweb.projetopiloto.MainActivity$MyWebViewClient.onPageFinished(MainActivity.java:161)
at com.android.webview.chromium.WebViewContentsClientAdapter.onPageFinished(WebViewContentsClientAdapter.java:545)
at org.chromium.android_webview.AwContentsClientCallbackHelper$MyHandler.handleMessage(AwContentsClientCallbackHelper.java:201)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6119)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)
Your setting dismiss() on your progress bar somewhere in your code with out having initialised it.
do
if(progress!= null)
progress.dismiss()
First, put only your application's log.
Second, you are trying to dismiss a progress dialog when its not initialized.
java.lang.NullPointerException: Attempt to invoke virtual
method 'void android.app.ProgressDialog.dismiss()' on a null object reference
I'd start my inspections with MainActivity.java:161
I am developing an app using Android Studio.
The problem is that app gets crashed twice within few minutes of running it and besides Application terminated. and normal logs no error is shown in the logcat.
Here's complete logcat:
02/12 22:31:34: Launching app
Cold swapped changes.
$ adb shell am start -n "com.abc.xxx/com.abc.xxx.MainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
Connected to process 13399 on device micromax-micromax_aq4502-2864004C04884I2
I/art: Late-enabling -Xcheck:jni
W/System: ClassLoader referenced unknown path: /data/app/com.abc.xxx-2/lib/arm
I/InstantRun: Instant Run Runtime started. Android package is com.abc.xxx, real application class is null.
W/System: ClassLoader referenced unknown path: /data/app/com.abc.xxx-2/lib/arm
W/DynamiteModule: Local module descriptor class for com.google.firebase.auth not found.
W/DynamiteModule: Local module descriptor class for com.google.firebase.auth not found.
I/art: Background sticky concurrent mark sweep GC freed 11281(1218KB) AllocSpace objects, 22(696KB) LOS objects, 15% free, 5MB/6MB, paused 13.077ms total 70.659ms
I/DynamiteModule: Considering local module com.google.android.gms.flags:2 and remote module com.google.android.gms.flags:0
I/DynamiteModule: Selected local version of com.google.android.gms.flags
W/DynamiteModule: Local module descriptor class for com.google.android.gms.crash not found.
I/DynamiteModule: Considering local module com.google.android.gms.crash:0 and remote module com.google.android.gms.crash:4
I/DynamiteModule: Selected remote version of com.google.android.gms.crash, version >= 4
W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_chimera/m/00000012/n/armeabi-v7a
W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_chimera/m/00000012/n/armeabi
I/FirebaseCrashApiImpl: FirebaseCrashApiImpl created by ClassLoader p[DexPathList[[zip file "/data/data/com.google.android.gms/app_chimera/m/00000012/DynamiteModulesC_GmsCore_prodmnc_hdpi_release.apk"],nativeLibraryDirectories=[/data/user/0/com.google.android.gms/app_chimera/m/00000012/n/armeabi-v7a, /data/user/0/com.google.android.gms/app_chimera/m/00000012/n/armeabi, /vendor/lib, /system/lib]]]
I/DynamiteModule: Considering local module com.google.android.gms.flags:2 and remote module com.google.android.gms.flags:0
I/DynamiteModule: Selected local version of com.google.android.gms.flags
W/DynamiteModule: Local module descriptor class for com.google.android.gms.crash not found.
I/FA: App measurement is starting up, version: 10084
I/FA: To enable debug logging run: adb shell setprop log.tag.FA VERBOSE
D/FA: Debug-level message logging enabled
D/FA: AppMeasurement singleton hash: 198168520
V/FA: Collection enabled
V/FA: App package, google app id: com.abc.xxx, 1:987905869088:android:e7f50263e7b8aa58
I/FA: To enable faster debug mode event logging run:
adb shell setprop debug.firebase.analytics.app com.getsportalapp.sportal
V/FA: Registered activity lifecycle callback
I/FirebaseCrash: FirebaseCrash reporting initialized com.google.android.gms.internal.zzbks#e551d72
I/FirebaseInitProvider: FirebaseApp initialization successful
V/FA: Using measurement service
V/FA: Connecting to remote service
W/art: Before Android 4.1, method android.graphics.PorterDuffColorFilter android.support.graphics.drawable.VectorDrawableCompat.updateTintFilter(android.graphics.PorterDuffColorFilter, android.content.res.ColorStateList, android.graphics.PorterDuff$Mode) would have incorrectly overridden the package-private method in android.graphics.drawable.Drawable
W/com.facebook.appevents.AppEventsLogger: activateApp events are being logged automatically. There's no need to call activateApp explicitly, this is safe to remove.
I/GAC: Building GoogleApiClient
I/CrashlyticsCore: Initializing Crashlytics 2.3.15.167
V/FA: Connection attempt already in progress
V/FA: Activity resumed, time: 824779068
D/OpenGLRenderer: Use EGL_SWAP_BEHAVIOR_PRESERVED: false
D/signedIn: onAuthStateChanged:signed_in:ShXMXdc5kHUQZWG3lGudJtt2
I/DynamiteModule: Considering local module com.google.android.gms.firebase_database:4 and remote module com.google.android.gms.firebase_database:5
I/DynamiteModule: Selected remote version of com.google.android.gms.firebase_database, version >= 5
I/OpenGLRenderer: Initialized EGL, version 1.4
I/MaliEGL: [Mali]window_type=1, is_framebuffer=0, errnum = 0
I/MaliEGL: [Mali]surface->num_buffers=4, surface->num_frames=3, win_min_undequeued=1
I/MaliEGL: [Mali]max_allowed_dequeued_buffers=3
E/RecyclerView: No adapter attached; skipping layout
D/FA: Connected to remote service
V/FA: Processing queued up service tasks: 2
E/RecyclerView: No adapter attached; skipping layout
D/getInvitation: getInvitation: no deep link found.
D/called: again
D/cLat: 2.8418744
D/cLng: 8.7791019
I/MaliEGL: [Mali]window_type=1, is_framebuffer=0, errnum = 0
I/MaliEGL: [Mali]surface->num_buffers=4, surface->num_frames=3, win_min_undequeued=1
I/MaliEGL: [Mali]max_allowed_dequeued_buffers=3
W/PersistentConnection: pc_0 - Using an unspecified index. Consider adding '".indexOn": "g"' at geofire to your security and Firebase Database rules for better performance
W/PersistentConnection: pc_0 - Using an unspecified index. Consider adding '".indexOn": "g"' at geofire to your security and Firebase Database rules for better performance
W/PersistentConnection: pc_0 - Using an unspecified index. Consider adding '".indexOn": "g"' at geofire to your security and Firebase Database rules for better performance
W/PersistentConnection: pc_0 - Using an unspecified index. Consider adding '".indexOn": "g"' at geofire to your security and Firebase Database rules for better performance
W/Settings: Setting airplane_mode_on has moved from android.provider.Settings.System to android.provider.Settings.Global, returning read-only value.
W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_chimera/m/00000010/n/armeabi
D/DynamitePackage: Instantiated singleton DynamitePackage.
D/DynamitePackage: Instantiating com.google.android.gms.ads.ChimeraAdManagerCreatorImpl
I/DynamiteModule: Considering local module com.google.android.gms.piccard.dynamite:0 and remote module com.google.android.gms.piccard.dynamite:12
I/DynamiteModule: Selected remote version of com.google.android.gms.piccard.dynamite, version >= 12
W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_chimera/m/00000010/n/armeabi
W/VideoCapabilities: Unrecognized profile/level 32768/2 for video/mp4v-es
I/VideoCapabilities: Unsupported profile 8 for video/mp4v-es
I/VideoCapabilities: Unsupported profile 8 for video/mp4v-es
I/VideoCapabilities: Unsupported profile 8 for video/mp4v-es
I/VideoCapabilities: Unsupported profile 8 for video/mp4v-es
I/VideoCapabilities: Unsupported profile 8 for video/mp4v-es
I/VideoCapabilities: Unsupported profile 8 for video/mp4v-es
I/VideoCapabilities: Unsupported profile 4 for video/mp4v-es
I/Ads: Starting ad request.
I/WebViewFactory: Loading com.google.android.webview version 53.0.2785.124 (code 278512400)
D/diffAnother: -6283000
I/art: Rejecting re-init on previously-failed class java.lang.Class<com.android.webview.chromium.ServiceWorkerControllerAdapter>
I/art: Rejecting re-init on previously-failed class java.lang.Class<com.android.webview.chromium.ServiceWorkerControllerAdapter>
I/art: Rejecting re-init on previously-failed class java.lang.Class<com.android.webview.chromium.TokenBindingManagerAdapter>
I/art: Rejecting re-init on previously-failed class java.lang.Class<com.android.webview.chromium.TokenBindingManagerAdapter>
I/cr_LibraryLoader: Time to load native libraries: 6 ms (timestamps 5738-5744)
I/cr_LibraryLoader: Expected native library version number "53.0.2785.124", actual native library version number "53.0.2785.124"
V/WebViewChromiumFactoryProvider: Binding Chromium to main looper Looper (main, tid 1) {611ead6}
I/cr_LibraryLoader: Expected native library version number "53.0.2785.124", actual native library version number "53.0.2785.124"
I/chromium: [INFO:library_loader_hooks.cc(151)] Chromium logging enabled: level = 0, default verbosity = 0
I/cr_BrowserStartup: Initializing chromium process, singleProcess=true
W/cr_media: Requires BLUETOOTH permission
W/cr_AwContents: onDetachedFromWindow called when already detached. Ignoring
I/cr_Ime: ImeThread is not enabled.
E/libEGL: validate_display:255 error 3008 (EGL_BAD_DISPLAY)
W/cr_BindingManager: Cannot call determinedVisibility() - never saw a connection for the pid: 13399
I/DynamiteModule: Considering local module com.google.android.gms.tagmanager:8 and remote module com.google.android.gms.tagmanager:9
I/DynamiteModule: Selected remote version of com.google.android.gms.tagmanager, version >= 9
W/DynamiteModule: Local module descriptor class for com.google.firebase.auth not found.
W/GoogleTagManager: No container asset found in /assets/containers. Checking top level /assets directory for container assets.
W/GoogleTagManager: Tag Manager's event handler WILL NOT be installed (no container loaded)
I/GoogleTagManager: Tag Manager initilization took 213ms
V/FA: Using measurement service
V/FA: Connecting to remote service
D/FA: Connected to remote service
V/FA: Processing queued up service tasks: 1
I/Ads: Scheduling ad refresh 45000 milliseconds from now.
W/cr_AwContents: onDetachedFromWindow called when already detached. Ignoring
I/cr_Ime: ImeThread is not enabled.
I/Ads: Ad finished loading.
W/cr_BindingManager: Cannot call determinedVisibility() - never saw a connection for the pid: 13399
I/chromium: [INFO:CONSOLE(0)] "Document was loaded from Application Cache with manifest https://googleads.g.doubleclick.net/mads/static/mad/sdk/native/sdk-core-v40-loader.appcache", source: https://googleads.g.doubleclick.net/mads/static/mad/sdk/native/sdk-core-v40-loader.html (0)
I/chromium: [INFO:CONSOLE(0)] "Application Cache Checking event", source: https://googleads.g.doubleclick.net/mads/static/mad/sdk/native/sdk-core-v40-loader.html (0)
I/chromium: [INFO:CONSOLE(0)] "Application Cache NoUpdate event", source: https://googleads.g.doubleclick.net/mads/static/mad/sdk/native/sdk-core-v40-loader.html (0)
D/diffAnother: 1129000
D/DynamitePackage: Instantiating com.google.android.gms.ads.ChimeraAdManagerCreatorImpl
I/Ads: Starting ad request.
D/diffAnother: -6300000
W/cr_AwContents: onDetachedFromWindow called when already detached. Ignoring
I/cr_Ime: ImeThread is not enabled.
W/cr_BindingManager: Cannot call determinedVisibility() - never saw a connection for the pid: 13399
I/Ads: Scheduling ad refresh 45000 milliseconds from now.
I/Ads: Ad finished loading.
V/FA: Using measurement service
V/FA: Connecting to remote service
D/FA: Logging event (FE): _e, Bundle[{_o=auto, _et=29568, _sc=MainActivity, _si=-6311178554893906199}]
V/FA: Using measurement service
V/FA: Connection attempt already in progress
V/FA: Activity paused, time: 824808635
D/FA: Connected to remote service
V/FA: Processing queued up service tasks: 2
W/com.facebook.appevents.AppEventsLogger: activateApp events are being logged automatically. There's no need to call activateApp explicitly, this is safe to remove.
I/MaliEGL: [Mali]window_type=1, is_framebuffer=0, errnum = 0
I/MaliEGL: [Mali]surface->num_buffers=4, surface->num_frames=3, win_min_undequeued=1
I/MaliEGL: [Mali]max_allowed_dequeued_buffers=3
D/call1: called
D/call2: called
D/call1: called
D/call2: called
D/error1: ERROR1
D/error1: ERROR1
I/MaliEGL: [Mali]window_type=1, is_framebuffer=0, errnum = 0
I/MaliEGL: [Mali]surface->num_buffers=4, surface->num_frames=3, win_min_undequeued=1
I/MaliEGL: [Mali]max_allowed_dequeued_buffers=3
V/RenderScript: 0xb8457a88 Launching thread(s), CPUs 4
I/MaliEGL: [Mali]window_type=1, is_framebuffer=0, errnum = 0
I/MaliEGL: [Mali]surface->num_buffers=4, surface->num_frames=3, win_min_undequeued=1
I/MaliEGL: [Mali]max_allowed_dequeued_buffers=3
V/FA: Inactivity, disconnecting from the service
I/MaliEGL: [Mali]window_type=1, is_framebuffer=0, errnum = 0
I/MaliEGL: [Mali]surface->num_buffers=4, surface->num_frames=3, win_min_undequeued=1
I/MaliEGL: [Mali]max_allowed_dequeued_buffers=3
I/MaliEGL: [Mali]window_type=1, is_framebuffer=0, errnum = 0
I/MaliEGL: [Mali]surface->num_buffers=4, surface->num_frames=3, win_min_undequeued=1
I/MaliEGL: [Mali]max_allowed_dequeued_buffers=3
I/Ads: Ad is not visible. Not refreshing ad.
I/Ads: Scheduling ad refresh 60000 milliseconds from now.
I/Ads: Ad is not visible. Not refreshing ad.
I/Ads: Scheduling ad refresh 60000 milliseconds from now.
Application terminated.
I tried integrating crashlytics but even it doesn't show any error when the app crashes in this manner.
The question is how will I be able to fix the error if I don't even know what the error is?
Please help me with this.
I think the issue is related to your ad view.
In last line it is showing that ad is not visible.