Baseline Profiles error with com.google.apps.tiktok.tracing - android

I'm trying to run a BaselineProfileGenerator but I'm getting some errors when I try on two devices (pixel2XL and Pixel 5) both using Android 11.
The macrobenchmark lib version is 1.2.0-alpha09.
The output running the test using Gradle is the next:
./gradlew :libraries:macrobenchmark:connectedGoogleBenchmarkAndroidTest -P android.testInstrumentationRunnerArguments.class=com.me.macrobenchmark.baselineprofile.BaselineProfileGenerator
com.google.testing.platform.api.plugin.PluginException: Exception thrown during onBeforeAll invocation of plugin com.google.testing.platform.plugin.android.AndroidDevicePlugin.
at com.google.testing.platform.plugin.PluginLifecycleKt.invokeOrThrow(PluginLifecycle.kt:216)
at com.google.testing.platform.plugin.PluginLifecycleKt.invokeOrThrow$default(PluginLifecycle.kt:205)
at com.google.testing.platform.plugin.PluginLifecycle$onBeforeAll$1.invoke(PluginLifecycle.kt:92)
at com.google.testing.platform.plugin.PluginLifecycle$onBeforeAll$1.invoke(PluginLifecycle.kt:88)
at com.google.testing.platform.core.telemetry.common.noop.NoopDiagnosticsScope.recordEvent(NoopDiagnosticsScope.kt:35)
at com.google.testing.platform.core.telemetry.TelemetryKt.recordEvent(Telemetry.kt:105)
at com.google.testing.platform.core.telemetry.TelemetryKt.recordEvent$default(Telemetry.kt:98)
at com.google.testing.platform.plugin.PluginLifecycle.onBeforeAll(PluginLifecycle.kt:88)
at com.google.testing.platform.executor.SingleDeviceExecutor$execute$4.invoke(SingleDeviceExecutor.kt:86)
at com.google.testing.platform.executor.SingleDeviceExecutor$execute$4.invoke(SingleDeviceExecutor.kt:86)
at com.google.testing.platform.executor.SingleDeviceExecutor.runUnlessCancelled(SingleDeviceExecutor.kt:105)
at com.google.testing.platform.executor.SingleDeviceExecutor.execute(SingleDeviceExecutor.kt:86)
at com.google.testing.platform.RunnerImpl.run(RunnerImpl.kt:108)
at com.google.testing.platform.server.strategy.NonInteractiveServerStrategy$run$4.invoke(NonInteractiveServerStrategy.kt:80)
at com.google.testing.platform.server.strategy.NonInteractiveServerStrategy$run$4.invoke(NonInteractiveServerStrategy.kt:79)
at com.google.testing.platform.core.telemetry.common.noop.NoopDiagnosticsScope.recordEvent(NoopDiagnosticsScope.kt:35)
at com.google.testing.platform.core.telemetry.TelemetryKt.recordEvent(Telemetry.kt:66)
at com.google.testing.platform.server.strategy.NonInteractiveServerStrategy.run(NonInteractiveServerStrategy.kt:79)
at com.google.testing.platform.main.MainKt$main$4.invokeSuspend(Main.kt:67)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at kotlinx.coroutines.EventLoopImplBase.processNextEvent(EventLoop.common.kt:274)
at kotlinx.coroutines.BlockingCoroutine.joinBlocking(Builders.kt:85)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking(Builders.kt:59)
at kotlinx.coroutines.BuildersKt.runBlocking(Unknown Source)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking$default(Builders.kt:38)
at kotlinx.coroutines.BuildersKt.runBlocking$default(Unknown Source)
at com.google.testing.platform.main.MainKt.main(Main.kt:66)
at com.google.testing.platform.main.MainKt.main$default(Main.kt:34)
at com.google.testing.platform.main.MainKt.main(Main.kt)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:564)
at com.google.testing.platform.launcher.Launcher.main(Launcher.java:149)
Caused by: com.google.testing.platform.core.error.UtpException: ErrorName: UNKNOWN
NameSpace: DdmlibAndroidDeviceController
ErrorCode: 1
I'm also trying to run the test by using the adb shell am instrument command:
adb shell am instrument -w -e class com.me.macrobenchmark.baselineprofile.BaselineProfileGenerator#startup com.me.macrobenchmark/androidx.test.runner.AndroidJUnitRunner
But this error is thrown:
02-15 12:56:03.774 I/ActivityManager( 1518): Start proc 23855:com.me.macrobenchmark/u0a9964 for added application com.me.macrobenchmark
02-15 12:56:03.784 I/.macrobenchmar(23855): Late-enabling -Xcheck:jni
02-15 12:56:03.816 I/.macrobenchmar(23855): Unquickening 12 vdex files!
02-15 12:56:03.816 D/ConnectivityService( 1518): NetReassign [no changes]
02-15 12:56:03.825 I/adbd ( 1153): jdwp connection from 23855
02-15 12:56:03.872 D/ApplicationLoaders(23855): Returning zygote-cached class loader: /system/framework/android.test.base.jar
02-15 12:56:03.873 D/ApplicationLoaders(23855): Returning zygote-cached class loader: /system/framework/android.test.base.jar
02-15 12:56:03.876 I/.macrobenchmar(23855): The ClassLoaderContext is a special shared library.
02-15 12:56:03.879 D/ApplicationLoaders(23855): Returning zygote-cached class loader: /system/framework/android.test.base.jar
02-15 12:56:03.879 D/ApplicationLoaders(23855): Returning zygote-cached class loader: /system/framework/android.test.base.jar
02-15 12:56:03.881 I/.macrobenchmar(23855): The ClassLoaderContext is a special shared library.
02-15 12:56:03.952 D/NetworkSecurityConfig(23855): No Network Security Config specified, using platform default
02-15 12:56:03.954 D/NetworkSecurityConfig(23855): No Network Security Config specified, using platform default
02-15 12:56:03.954 I/MonitoringInstr(23855): newApplication called!
02-15 12:56:03.958 I/MonitoringInstr(23855): Instrumentation started!
02-15 12:56:03.965 V/TestEventClient(23855): No service name argument was given (testDiscoveryService, testRunEventService or orchestratorService)
02-15 12:56:03.967 I/MonitoringInstr(23855): No JSBridge.
02-15 12:56:03.978 D/InfraTrack(23855): Tracking disabled due to lack of internet permissions
02-15 12:56:03.978 I/UsageTrackerFacilitator(23855): Usage tracking disabled
02-15 12:56:04.044 D/TestExecutor(23855): Adding listener androidx.test.internal.runner.listener.LogRunListener
02-15 12:56:04.044 D/TestExecutor(23855): Adding listener androidx.test.internal.runner.listener.InstrumentationResultPrinter
02-15 12:56:04.044 D/TestExecutor(23855): Adding listener androidx.test.internal.runner.listener.ActivityFinisherRunListener
02-15 12:56:04.048 I/TestRunner(23855): run started: 12 tests
02-15 12:56:04.051 I/TestRunner(23855): started: startupNoCompilation[mode=COLD](com.me.macrobenchmark.startup.home.HomeFeedStartupBenchmark)
02-15 12:56:04.073 I/GrantPermissionCallable(23855): Permission: android.permission.READ_EXTERNAL_STORAGE is already granted!
02-15 12:56:04.073 I/GrantPermissionCallable(23855): Permission: android.permission.WRITE_EXTERNAL_STORAGE is already granted!
02-15 12:56:04.079 W/WindowManager( 1518): Cannot find window which accessibility connection is added to
02-15 12:56:04.081 I/A11yListener( 3247): (REDACTED) #onAccessibilityStateChanged enabled: %s
02-15 12:56:04.081 I/A11yListener( 3247): #onChange
02-15 12:56:04.081 E/TraceManager( 3247): Duplicate trace
02-15 12:56:04.081 E/TraceManager( 3247): com.google.apps.tiktok.tracing.w: Starting new trace A11yEventListener_onChange when already associated with a trace: . For more help, see http://go/tiktok-tracing#fixing-duplicate-trace-issues
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.apps.tiktok.tracing.el.f(PG:6)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.apps.tiktok.tracing.el.g(PG:2)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.apps.tiktok.tracing.dv.d(PG:1)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.android.libraries.search.assistant.a.g.a(PG:7)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.android.libraries.search.assistant.a.b.b(PG:2)
02-15 12:56:04.081 E/TraceManager( 3247): at i.c.b.a.a.h(PG:4)
02-15 12:56:04.081 E/TraceManager( 3247): at kotlinx.coroutines.bk.run(PG:14)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.apps.tiktok.coroutines.g.run(PG:1)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.android.libraries.i.z.run(PG:1)
02-15 12:56:04.081 E/TraceManager( 3247): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
02-15 12:56:04.081 E/TraceManager( 3247): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.android.libraries.i.h.run(PG:2)
02-15 12:56:04.081 E/TraceManager( 3247): at java.lang.Thread.run(Thread.java:923)
02-15 12:56:04.081 E/TraceManager( 3247): at com.google.android.libraries.i.ai.run(PG:5)
02-15 12:56:04.081 E/TraceManager( 3247): Suppressed: com.google.apps.tiktok.tracing.fv:
02-15 12:56:04.081 E/TraceManager( 3247): at tk_trace.(Unknown Source:0)
02-15 12:56:04.081 E/TraceManager( 3247): at tk_trace.Missing root trace(Unknown Source:0)
02-15 12:56:04.081 E/TraceManager( 3247): Caused by: com.google.apps.tiktok.tracing.aa

Related

BLE connection error on Android 6 (Marshmallow) - unable to marshal value BluetoothGattCharacteristic

I am developing an Android app that works with Android Bluetooth LE. I was testing mostly on the newer devices with API 27 and above. The connection worked just fine. I was able to scan and connect to advertising devices.
Recently, I got a chance to test on Android 6.0 and Android 6.0.1 and things went south. I got
the runtime exception with BluetoothGattCharacteristic and I am unsure why its not able to amrshal the value just for Android 6.0 and 6.0.1
I am handling some BLE notifications with a BroadcastReceiver which I am registering and unregistering at the right lifecycle callbacks.
mNotificationReceiver = new NotificationReceiver(mContext);
mNotificationReceiver.subscribeForBleManagerNotifications(mBleScannerCallback);
mNotificationReceiver.subscribeForPeripheralNotifications(mPeripheralCallback);
mNotificationReceiver.subscribeForGattNotifications(mGattCallback);
mNotificationReceiver.subscribeForErrorNotifications(mErrorCallback);
Here is the crash log.
--------- beginning of crash
04-14 09:56:56.209 16432-16432/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.mattel.mcpp.unity, PID: 16432
java.lang.Error: FATAL EXCEPTION [main]
Unity version : 2019.2.9f1
Device model : LGE Nexus 5
Device fingerprint: google/hammerhead/hammerhead:6.0.1/M4B30Z/3437181:user/release-keys
Caused by: java.lang.RuntimeException: Parcel: unable to marshal value android.bluetooth.BluetoothGattCharacteristic#c829775
at android.os.Parcel.writeValue(Parcel.java:1418)
at android.os.Parcel.writeArrayMapInternal(Parcel.java:686)
at android.os.BaseBundle.writeToParcelInner(BaseBundle.java:1330)
at android.os.Bundle.writeToParcel(Bundle.java:1079)
at android.os.Parcel.writeBundle(Parcel.java:711)
at android.content.Intent.writeToParcel(Intent.java:7793)
at android.app.ActivityManagerProxy.broadcastIntent(ActivityManagerNative.java:3044)
at android.app.ContextImpl.sendBroadcast(ContextImpl.java:767)
at android.content.ContextWrapper.sendBroadcast(ContextWrapper.java:396)
at com.mcpp.mattel.blekit.notification.Notifier$1.run(Notifier.java:141)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
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)
04-14 09:56:56.211 780-1356/? W/ActivityManager: Force finishing activity com.mattel.mcpp.unity/.UnityPlayerActivity
04-14 09:56:56.234 15784-15826/? W/bt_l2cap: l2cble_set_fixed_channel_tx_data_length, request not supported
04-14 09:56:56.234 15784-15814/? D/BtGatt.GattService: onConfigureMTU() address=03:CC:8F:0F:B3:82, status=0, mtu=247
04-14 09:56:56.235 16432-16442/? D/BluetoothGatt: onConfigureMTU() - Device=03:CC:8F:0F:B3:82 mtu=247 status=0
04-14 09:56:56.353 780-879/? I/OpenGLRenderer: Initialized EGL, version 1.4
04-14 09:56:56.425 780-789/? I/art: Background partial concurrent mark sweep GC freed 35527(2MB) AllocSpace objects, 18(648KB) LOS objects, 33% free, 31MB/47MB, paused 2.107ms total 189.524ms
04-14 09:56:56.444 780-1410/? D/NetlinkSocketObserver: NeighborEvent{elapsedMs=1770229, 192.168.1.1, [3C37868CF82F], RTM_NEWNEIGH, NUD_REACHABLE}
04-14 09:56:56.747 780-793/? W/ActivityManager: Activity pause timeout for ActivityRecord{a047d29 u0 com.mattel.mcpp.unity/.UnityPlayerActivity t116 f}
04-14 09:56:59.128 1575-17219/? W/IcingInternalCorpora: getNumBytesRead when not calculated.
04-14 09:56:59.173 16432-16432/? I/Process: Sending signal. PID: 16432 SIG: 9
04-14 09:56:59.176 1366-1375/? I/art: Background partial concurrent mark sweep GC freed 81016(5MB) AllocSpace objects, 54(1252KB) LOS objects, 39% free, 24MB/40MB, paused 1.778ms total 103.500ms
04-14 09:56:59.199 1575-2165/? I/Icing: Usage reports 0 indexed 0 rejected 0 imm upload false
04-14 09:56:59.205 202-809/? D/audio_hw_primary: out_set_parameters: enter: usecase(1: low-latency-playback) kvpairs: routing=2
04-14 09:56:59.210 2855-2855/? W/Binder_B: type=1400 audit(0.0:550): avc: denied { ioctl } for path="socket:[116533]" dev="sockfs" ino=116533 ioctlcmd=7704 scontext=u:r:system_server:s0 tcontext=u:r:system_server:s0 tclass=unix_stream_socket permissive=0
04-14 09:56:59.210 2855-2855/? W/Binder_B: type=1400 audit(0.0:551): avc: denied { ioctl } for path="socket:[116533]" dev="sockfs" ino=116533 ioctlcmd=7704 scontext=u:r:system_server:s0 tcontext=u:r:system_server:s0 tclass=unix_stream_socket permissive=0
04-14 09:56:59.247 780-874/? W/InputDispatcher: channel 'cdef40d com.mattel.mcpp.unity/com.mattel.mcpp.unity.UnityPlayerActivity (server)' ~ Consumer closed input channel or an error occurred. events=0x9
04-14 09:56:59.247 780-874/? E/InputDispatcher: channel 'cdef40d com.mattel.mcpp.unity/com.mattel.mcpp.unity.UnityPlayerActivity (server)' ~ Channel is unrecoverably broken and will be disposed!
04-14 09:56:59.251 780-3556/? D/ConnectivityService: ConnectivityService NetworkRequestInfo binderDied(NetworkRequest [ id=35, legacyType=-1, [ Capabilities: INTERNET&NOT_RESTRICTED&TRUSTED&NOT_VPN] ], android.os.BinderProxy#b9acccf)
04-14 09:56:59.251 780-1778/? I/WindowState: WIN DEATH: Window{cdef40d u0 com.mattel.mcpp.unity/com.mattel.mcpp.unity.UnityPlayerActivity}
04-14 09:56:59.251 780-1778/? W/InputDispatcher: Attempted to unregister already unregistered input channel 'cdef40d com.mattel.mcpp.unity/com.mattel.mcpp.unity.UnityPlayerActivity (server)'
04-14 09:56:59.251 780-1778/? W/WindowManager: Force-removing child win Window{26a765c u0 SurfaceView} from container Window{cdef40d u0 com.mattel.mcpp.unity/com.mattel.mcpp.unity.UnityPlayerActivity}
04-14 09:56:59.251 15784-15800/? D/BtGatt.GattService: Binder is dead - unregistering client (5)!
04-14 09:56:59.252 780-891/? D/ConnectivityService: releasing NetworkRequest NetworkRequest [ id=35, legacyType=-1, [ Capabilities: INTERNET&NOT_RESTRICTED&TRUSTED&NOT_VPN] ]
04-14 09:56:59.253 780-891/? E/ConnectivityService: RemoteException caught trying to send a callback msg for NetworkRequest [ id=35, legacyType=-1, [ Capabilities: INTERNET&NOT_RESTRICTED&TRUSTED&NOT_VPN] ]
04-14 09:56:59.255 15784-15816/? D/BtGatt.AdvertiseManager: message : 1
04-14 09:56:59.255 15784-15816/? D/BtGatt.AdvertiseManager: stop advertise for client 5
04-14 09:56:59.257 15784-15816/? D/BtGatt.GattService: onAdvertiseInstanceDisabled() - clientIf=5, status=0
04-14 09:56:59.257 15784-15816/? D/BtGatt.GattService: Client app is not null!
04-14 09:56:59.258 15784-15816/? D/BtGatt.AdvertiseManager: failed onAdvertiseInstanceDisabled
android.os.DeadObjectException
at android.os.BinderProxy.transactNative(Native Method)
at android.os.BinderProxy.transact(Binder.java:503)
at android.bluetooth.IBluetoothGattCallback$Stub$Proxy.onMultiAdvertiseCallback(IBluetoothGattCallback.java:882)
at com.android.bluetooth.gatt.GattService.onAdvertiseInstanceDisabled(GattService.java:1298)
at com.android.bluetooth.gatt.AdvertiseManager$AdvertiseNative.stopAdvertising(AdvertiseManager.java:318)
at com.android.bluetooth.gatt.AdvertiseManager$ClientHandler.handleStopAdvertising(AdvertiseManager.java:212)
at com.android.bluetooth.gatt.AdvertiseManager$ClientHandler.handleMessage(AdvertiseManager.java:175)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.os.HandlerThread.run(HandlerThread.java:61)
04-14 09:56:59.258 15784-15816/? D/BtGatt.AdvertiseManager: app died - unregistering client : 5
04-14 09:56:59.259 15784-15816/? D/BtGatt.GattService: unregisterClient() - clientIf=5
04-14 09:56:59.260 15784-15826/? W/bt_btif: bta_gattc_conn_cback() - cif=3 connected=0 conn_id=3 reason=0x0016
04-14 09:56:59.260 15784-15826/? W/bt_btif: bta_gattc_conn_cback() - cif=4 connected=0 conn_id=4 reason=0x0016
04-14 09:56:59.260 15784-15826/? W/bt_btif: bta_gattc_conn_cback() - cif=5 connected=0 conn_id=5 reason=0x0016
04-14 09:56:59.266 780-790/? W/WindowManager: Failed looking up window
java.lang.IllegalArgumentException: Requested window android.os.BinderProxy#92228e6 does not exist
at com.android.server.wm.WindowManagerService.windowForClientLocked(WindowManagerService.java:8743)
at com.android.server.wm.WindowManagerService.windowForClientLocked(WindowManagerService.java:8734)
at com.android.server.wm.WindowState$DeathRecipient.binderDied(WindowState.java:1209)
at android.os.BinderProxy.sendDeathNotice(Binder.java:558)
04-14 09:56:59.266 780-790/? I/WindowState: WIN DEATH: null
Please let me know if you have any possible idea or if you have faced this issue before. Your help is much appreciated. Thank you.
The older versions of Android is not able to marshal BluetoothGattCharacteristic even though it implements Parcelable. I was wrapping it in intent bundle with putExtra(). To support older versions (in my case Android 6.0), we need to pass string value of UUIDs if we are using intent bundles to pass around UUID for scan filters.
Example, intent.putExtra(BleUtils.CHARACTERISTIC, characteristic.getUuid().toString());

Silent APK installation by the device owner doesn't work on MIUI 11

I have a "device owner" Android app which silently installs APK using PackageInstaller (see the code, for example, here).
This code works perfectly on all Android 7+ devices except Xiaomi Redmi 7A (running MIUI 11). The installation fails, here's the related logcat output:
01-16 00:43:21.494 1488 2892 I InstallationStatistic: beginInstallSession: 417086238
01-16 00:43:21.600 1488 1658 D com.android.server.pm.PackageManagerServiceInjector: Package verify start
01-16 00:43:21.601 1488 1538 D CompatibilityInfo: mCompatibilityFlags - 0
01-16 00:43:21.601 1488 1538 D CompatibilityInfo: applicationDensity - 320
01-16 00:43:21.601 1488 1538 D CompatibilityInfo: applicationScale - 1.0
01-16 00:43:21.611 24382 24395 D GuardProvider: start parse apk : /data/app/vmdl417086238.tmp
01-16 00:43:21.618 24382 24395 E i.guardprovide: Invalid ID 0x00000000.
01-16 00:43:21.638 4434 24418 D PackageVerifyedRecevier: verify package /data/app/vmdl417086238.tmp info: PackageInfo{45d0d6b com.hmdm.sendphoto}
01-16 00:43:21.638 4434 24418 D PackageVerifyedRecevier: verify package /data/app/vmdl417086238.tmp finish true
01-16 00:43:21.639 1488 1658 I com.android.server.pm.PackageManagerServiceInjector: MIUILOG- Install Reject uid: 10161 pkg : com.hmdm.launcher
01-16 00:43:21.639 1488 1658 E PackageInstaller: Commit of session 417086238 failed: Permission Denied
Package ID of the installer (device owner) is com.hmdm.launcher. Package ID of the app being installed is com.hmdm.sendphoto.
I tried to add the "Install unknown apps" permission but this didn't help.
Looks like the app must request MIUI OS for some special (undocumented) permissions?
The device owner rights were granted to the application by QR code based enrollment.
Also with MIUI 10.3 some apps are refused to install/update.
For instance, I cannot install a Threema update the usual way (and just get a silly error 'not installed'). logcat shows that com.miui.global.packageinstaller.action.verifypackage called by com.android.server.pm.PackageManagerServiceInjector fails:
02-16 11:29:05.809 1271 1853 D com.android.server.pm.PackageManagerServiceInjector: Package verify start
02-16 11:29:05.810 1271 1317 D CompatibilityInfo: mCompatibilityFlags - 0
02-16 11:29:05.810 1271 1317 D CompatibilityInfo: applicationDensity - 440
02-16 11:29:05.810 1271 1317 D CompatibilityInfo: applicationScale - 1.0
02-16 11:29:05.812 1271 6228 W ActivityManager: Sending non-protected broadcast com.miui.global.packageinstaller.action.verifypackage from system 3440:com.miui.securitycenter.remote/1000 pkg com.miui.securitycenter. Callers=
02-16 11:29:05.816 3440 25765 E ActivityThread: Failed to find provider info for guard
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: parseApk
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: java.lang.IllegalArgumentException: Unknown URI content://guard
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at android.content.ContentResolver.call(Unknown Source:63)
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at com.miui.permcenter.install.q.doInBackground(Unknown Source:17)
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at com.miui.permcenter.install.q.doInBackground(Unknown Source:2)
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at android.os.AsyncTask$2.call(Unknown Source:20)
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at java.util.concurrent.FutureTask.run(FutureTask.java:266)
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
02-16 11:29:05.817 3440 25765 E PackageVerifyedRecevier: at java.lang.Thread.run(Thread.java:764)
02-16 11:29:05.817 3440 25765 D PackageVerifyedRecevier: verify package /data/app/vmdl216836998.tmp info: null
02-16 11:29:05.818 3440 25765 D PackageVerifyedRecevier: verify package /data/app/vmdl216836998.tmp finish false
02-16 11:29:05.818 1271 1853 I com.android.server.pm.PackageManagerServiceInjector: MIUILOG- INSTALL_FAILED_VERIFICATION_FAILURE uid: 10026 pkg : com.google.android.packageinstaller
What worked for me was to move the apk file to /data/local/tmp/
and then call as root
pm install -r file.apk

How to close system Log from telephone

I'm learning android app development and here I find so many logs like below.
I am sure the Logs are Not from my app, it is from wifi driver??
How can I close it?
01-17 22:45:43.007 8755-8952/? E/WifiConfigStore: has d0:c7:c0:11:09:e6 freq=2412 age=1640 ?=true
01-17 22:45:43.007 8755-8952/? E/WifiStateMachine: WifiStateMachine starting scan for "wifi"WPA_PSK with 2412
01-17 22:45:43.007 8755-8952/? E/WifiStateMachine: stopReconnectWifi Wfd=false StopScan=false mDontReconnectAndScan=false
01-17 22:45:43.008 8755-8952/? E/WifiStateMachine: [1,547,736,343,007 ms] noteScanstart no scan source uid -2
01-17 22:45:43.008 8755-18691/? E/WifiMonitor: handleEvent unknown: 15 CTRL-EVENT-SCAN-STARTED
01-17 22:45:43.594 8755-8755/? E/WifiTrafficPoller: TRAFFIC_STATS_POLL true Token 1373 num clients 19
01-17 22:45:43.595 8755-8755/? E/WifiTrafficPoller: packet count Tx=84893 Rx=71940
01-17 22:45:44.295 8755-8952/? E/WifiStateMachine: ConnectedState (when=0 what=147461!SCAN_RESULTS_EVENT 0 0 found=17 known=1 got=17 bcn=0 con=1
01-17 22:45:44.295 8755-8952/? E/WifiStateMachine: L2ConnectedState (when=-1ms what=147461!SCAN_RESULTS_EVENT 0 0 found=17 known=1 got=17 bcn=0 con=1
01-17 22:45:44.296 8755-8952/? E/WifiStateMachine: ConnectModeState (when=-1ms what=147461!SCAN_RESULTS_EVENT 0 0 found=17 known=1 got=17 bcn=0 con=1
01-17 22:45:44.296 8755-8952/? E/WifiStateMachine: DriverStartedState (when=-1ms what=147461!SCAN_RESULTS_EVENT 0 0 found=17 known=1 got=17 bcn=0 con=1
01-17 22:45:44.296 8755-8952/? E/WifiStateMachine: SupplicantStartedState (when=-2ms what=147461!SCAN_RESULTS_EVENT 0 0 found=17 known=1 got=17 bcn=0 con=1
01-17 22:45:44.297 8755-8952/? E/WifiStateMachine: [1,547,736,344,297 ms] noteScanEnd no scan source onTime=0
01-17 22:45:44.304 8755-8952/? E/WifiStateMachine: wifi setScanResults statecom.android.server.wifi.WifiStateMachine$ConnectedState#fefd9d4 sup_state=COMPLETED debouncing=false mConnectionRequests=1 selection=<none>
01-17 22:45:44.305 8755-8952/? E/WifiConfigStore: updateSavedNetworkHistory(): try "wifi"WPA_PSK SSID="wifi" wifi [WPA-PSK-CCMP][WPA2-PSK-CCMP][WPS][ESS] ajst=0
01-17 22:45:44.305 8755-8952/? E/WifiConfigStore: got known scan result d0:c7:c0:11:09:e6 key : "wifi"WPA_PSK num: 1 rssi=-53 freq=2412
01-17 22:45:44.307 8755-8952/? E/WifiAutoJoinController: status: bssid=d0:c7:c0:11:09:e6
If you are using Android Studio, in the Logcat window select "Show only selected application" for only viewing your application logs.
These logs are from android system component for Wi-Fi, which uses these classes and prints their necessary logs.
If you don't want to see it just go to Logcat window below and in the right corner, select Show only selected application from the dropdown menu.
As a new android developer, I think you need to know something more about android Log class. Here is the official documentation.

Android Web View Crash

My app was working fine. I had to format my computer and phone. Now the keep app crashing. I'm using a web view to display youtube everything works fine until I try to switch to full screen then I get the errors. I don't know how to solve with this problem.
08-10 21:41:27.005 31363-31363/? E/Zygote﹕ MountEmulatedStorage()
08-10 21:41:27.005 31363-31363/? E/Zygote﹕ v2
08-10 21:41:27.045 31363-31363/? E/SELinux﹕ [DEBUG] get_category: variable seinfo: default sensitivity: NULL, cateogry: NULL
08-10 21:41:36.865 31363-31959/com.videowebviewtest.unknown.webview_video_test E/ACodec﹕ onConfigureComponent mime.c_str() = audio/mp4a-latm
08-10 21:41:36.915 31363-31977/com.videowebviewtest.unknown.webview_video_test E/ACodec﹕ onConfigureComponent mime.c_str() = video/x-vnd.on2.vp9
08-10 21:41:36.915 31363-31977/com.videowebviewtest.unknown.webview_video_test E/ACodec﹕ [OMX.google.vp9.decoder] storeMetaDataInBuffers failed w/ err -2147483648
08-10 21:41:45.915 31363-31363/com.videowebviewtest.unknown.webview_video_test A/chromium﹕ [FATAL:jni_android.cc(271)] Check failed: false.
08-10 21:41:45.915 31363-31363/com.videowebviewtest.unknown.webview_video_test A/libc﹕ Fatal signal 6 (SIGABRT), code -6 in tid 31363 (view_video_test)

Ionic app crashes on Android emulator and device

I'm building an app using the Ionic framework and AngularJS. It used to run fine, now it crashes as soon as it starts in both the emulator and an Android device. What is weird is that it runs fine in the Ionic View app (http://view.ionic.io/). The logcat says that the error is a NullPointerException.
What really worries me is that I didn't do any big changes, and another app started to fail as well. How can Ionic Cordova fail like that?
The complete logcat for the part of the crash says:
--------- beginning of crash
E/AndroidRuntime( 2227): FATAL EXCEPTION: main
E/AndroidRuntime( 2227): Process: com.ionicframework.notpush921844, PID: 2227
E/AndroidRuntime( 2227): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ionicframework.notpush921844/com.ionicframework.notpush921844.MainActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void org.apache.cordova.CordovaPlugin.privateInitialize(java.lang.String, org.apache.cordova.CordovaInterface, org.apache.cordova.CordovaWebView, org.apache.cordova.CordovaPreferences)' on a null object reference
E/AndroidRuntime( 2227): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2298)
E/AndroidRuntime( 2227): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2360)
E/AndroidRuntime( 2227): at android.app.ActivityThread.access$800(ActivityThread.java:144)
E/AndroidRuntime( 2227): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1278)
E/AndroidRuntime( 2227): at android.os.Handler.dispatchMessage(Handler.java:102)
E/AndroidRuntime( 2227): at android.os.Looper.loop(Looper.java:135)
E/AndroidRuntime( 2227): at android.app.ActivityThread.main(ActivityThread.java:5221)
E/AndroidRuntime( 2227): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime( 2227): at java.lang.reflect.Method.invoke(Method.java:372)
E/AndroidRuntime( 2227): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:899)
E/AndroidRuntime( 2227): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:694)
E/AndroidRuntime( 2227): Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'void org.apache.cordova.CordovaPlugin.privateInitialize(java.lang.String, org.apache.cordova.CordovaInterface, org.apache.cordova.CordovaWebView, org.apache.cordova.CordovaPreferences)' on a null object reference
E/AndroidRuntime( 2227): at org.apache.cordova.PluginManager.getPlugin(PluginManager.java:169)
E/AndroidRuntime( 2227): at org.apache.cordova.PluginManager.startupPlugins(PluginManager.java:95)
E/AndroidRuntime( 2227): at org.apache.cordova.PluginManager.init(PluginManager.java:84)
E/AndroidRuntime( 2227): at org.apache.cordova.CordovaWebViewImpl.init(CordovaWebViewImpl.java:116)
E/AndroidRuntime( 2227): at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:138)
E/AndroidRuntime( 2227): at org.apache.cordova.CordovaActivity.loadUrl(CordovaActivity.java:209)
E/AndroidRuntime( 2227): at com.ionicframework.notpush921844.MainActivity.onCreate(MainActivity.java:32)
E/AndroidRuntime( 2227): at android.app.Activity.performCreate(Activity.java:5937)
E/AndroidRuntime( 2227): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105)
E/AndroidRuntime( 2227): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2251)
E/AndroidRuntime( 2227): ... 10 more
W/ActivityManager( 1219): Force finishing activity com.ionicframework.notpush921844/.MainActivity
I/WindowManager( 1219): Screenshot max retries 4 of Token{f511ccd ActivityRecord{230d3264 u0 com.ionicframework.notpush921844/.MainActivity t61 f}} appWin=Window{1adfb8c9 u0 Starting com.ionicframework.notpush921844} drawState=4
E/ActivityManager( 1219): Invalid thumbnail dimensions: 576x576
D/OpenGLRenderer( 1219): Render dirty regions requested: true
D/Atlas ( 1219): Validating map...
D/ ( 1219): HostConnection::get() New Host Connection established 0x9de19530, tid 2264
I/OpenGLRenderer( 1219): Initialized EGL, version 1.4
D/OpenGLRenderer( 1219): Enabling debug mode 0
W/EGL_emulation( 1219): eglSurfaceAttrib not implemented
W/OpenGLRenderer( 1219): Failed to set EGL_SWAP_BEHAVIOR on surface 0x9de3eb40, error=EGL_SUCCESS
W/ActivityManager( 1219): Activity pause timeout for ActivityRecord{230d3264 u0 com.ionicframework.notpush921844/.MainActivity t61 f}
W/EGL_emulation( 1475): eglSurfaceAttrib not implemented
W/OpenGLRenderer( 1475): Failed to set EGL_SWAP_BEHAVIOR on surface 0xb0a93b40, error=EGL_SUCCESS
W/OpenGLRenderer( 1475): Incorrectly called buildLayer on View: ShortcutAndWidgetContainer, destroying layer...
W/OpenGLRenderer( 1475): Incorrectly called buildLayer on View: ShortcutAndWidgetContainer, destroying layer...
W/OpenGLRenderer( 1475): Incorrectly called buildLayer on View: ShortcutAndWidgetContainer, destroying layer...
I/iu.UploadsManager( 1746): End new media; added: 0, uploading: 0, time: 28 ms
V/ConfigFetchTask( 1746): ConfigFetchTask getDeviceDataVersionInfo(): ABFEt1ViXdAKZc6rqCAOLFv7YJuwVLSY9_n4gaUyYMJPnZLeFSYFobS5FdRKHo-hnBvGnh1pycqXDTZLbzD-k5JtupkV7UW73Ugga_ju-VhYkvWRtl_Jn90jZhoDq_QYlbboOgPzzxDKH54r4FIa2bH3M1p-U8uzShc-PuRzDfha4UOokdUFujGIG2kLo5vTf6UKiU8mrJ_i-n_s1sm2CNkFb7o3Q7f_N1keqlCKSvXmpOQwTd0C7WGOOCYVnk7105hhiah5iLKl_0ZmwnXt9YnD2hVSUAQyDJPeLsFPksOqBpS6WQgtxBQ
I/GoogleURLConnFactory( 1746): Using platform SSLCertificateSocketFactory
W/ActivityThread( 1746): ClassLoader.loadClass: The class loader returned by Thread.getContextClassLoader() may fail for processes that host multiple applications. You should explicitly specify a context class loader. For example: Thread.setContextClassLoader(getClass().getClassLoader());
I/ActivityManager( 1219): Waited long enough for: ServiceRecord{39917cb u0 com.android.calendar/.alerts.InitAlarmsService}
I/ConfigFetchService( 1746): fetch service done; releasing wakelock
I/ConfigFetchService( 1746): stopping self
W/ActivityManager( 1219): Activity destroy timeout for ActivityRecord{230d3264 u0 com.ionicframework.notpush921844/.MainActivity t61 f}
I/CheckinService( 1746): Done disabling old GoogleServicesFramework version
I/ConfigService( 1598): onDestroy
D/TaskPersister( 1219): removeObsoleteFile: deleting file=61_task.xml
D/InitAlarmsService( 2008): Clearing and rescheduling alarms.
I/ActivityManager( 1219): Killing 1538:com.android.printspooler/u0a42 (adj 15): empty #17
W/libprocessgroup( 1219): failed to open /acct/uid_10042/pid_1538/cgroup.procs: No such file or directory
W/AudioTrack( 1219): AUDIO_OUTPUT_FLAG_FAST denied by client
I/Process ( 2227): Sending signal. PID: 2227 SIG: 9
I/ActivityManager( 1219): Process com.ionicframework.notpush921844 (pid 2227) has died
D/OpenGLRenderer( 1219): endAllStagingAnimators on 0xa2fe5880 (RippleDrawable) with handle 0x9deaf750
W/InputMethodManagerService( 1219): Window already focused, ignoring focus gain of: com.android.internal.view.IInputMethodClient$Stub$Proxy#2a47c778 attribute=null, token = android.os.BinderProxy#344958d4
It turns out the problem was caused by adding Phonegap's PushPlugin. I just had to remove android platform with ionic platform rm android and then add it again with ionic platform add android. Works fine now in both emulator and device.

Categories

Resources