Skip to content

BLUETOOTH permission is listed as optional in docs but seems to be required #424

@agramian

Description

@agramian

The Android setup docs under Step 2 - Add permissions to your AndroidManifest.xml: list the BLUETOOTH permission as optional but I am seeing a consistent crash for at least a Samsung SM-925T. I have not tested enough to determine if this is device specific but either way it should not happen. It causes our app to go into a crash/restart cycle of sometimes more than 10 times.

02-02 10:09:11.688 13384-13405/? E/BluetoothAdapter: Application does not have bluetooth permission, registering is failed
02-02 10:09:11.688 13384-13405/? E/BluetoothAdapter: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 10348 nor current process has android.permission.BLUETOOTH.
                                                         at android.os.Parcel.readException(Parcel.java:1620)
                                                         at android.os.Parcel.readException(Parcel.java:1573)
                                                         at android.bluetooth.IBluetoothManager$Stub$Proxy.registerStateChangeCallback(IBluetoothManager.java:350)
                                                         at android.bluetooth.BluetoothAdapter.<init>(BluetoothAdapter.java:594)
                                                         at android.bluetooth.BluetoothAdapter.getDefaultAdapter(BluetoothAdapter.java:576)
                                                         at com.mixpanel.android.mpmetrics.SystemInformation.isBluetoothEnabled(SystemInformation.java:141)
                                                         at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.getDefaultEventProperties(AnalyticsMessages.java:559)
                                                         at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.prepareEventObject(AnalyticsMessages.java:573)
                                                         at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.handleMessage(AnalyticsMessages.java:251)
                                                         at android.os.Handler.dispatchMessage(Handler.java:102)
                                                         at android.os.Looper.loop(Looper.java:158)
                                                         at android.os.HandlerThread.run(HandlerThread.java:61)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions