Looping Error on Android Emulator

匆匆过客 提交于 2019-11-27 12:18:25

Android is trying to listen on the microphone, which isn't available on the emulator, so it fills logcat with useless stack traces. To stop this, go to the Settings app in Android, and click:

  1. Apps and notifications
  2. App permissions
  3. Microphone

Then disallow microphone use for all the apps.

1nullpointer

Although disabling Microphone removed some of the errors , Disabling Quick Search App worked for me as suggested by OOI .

Settings >> Apps & Notifications >> All Apps >> Google

That com.google.android.googlequicksearchbox is Google app.

Simply disabling it in Settings worked for me.

Here's how to disable the hotword detection ("Ok Google") app in the emulator:

./adb shell "su root pm disable com.google.android.googlequicksearchbox"

In my case I fixed this first time by adding:

<uses-permission android:name="android.permission.RECORD_AUDIO" />

in AndroidManifest.xml

and updating the google.android.gms packages used in the project to the latest version in build.gradle file:

compile('com.google.android.gms:play-services-analytics:11.0.4') {
    force = true;
}
compile('com.google.android.gms:play-services-ads:11.0.4') {
    force = true;
}
compile('com.google.android.gms:play-services-gcm:11.0.4') {
    force = true;
}

UPDATE: Later, after an update of RN from 0.45 RN to 0.53 I found that the RECORD_AUDIO can be removed (if not used) with adding play-services-location and the play-services-base as below:

compile('com.google.android.gms:play-services-analytics:11.0.4') {
    force = true;
}

compile('com.google.android.gms:play-services-ads:11.0.4') {
    force = true;
}

compile('com.google.android.gms:play-services-gcm:11.0.4') {
    force = true;
}

compile('com.google.android.gms:play-services-location:11.0.4') {
    force = true;
}

compile('com.google.android.gms:play-services-base:11.0.4') {
    force = true;
}
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!