Exception in readStorage callback


#1

Hi, i’m getting an exception when I try to read my beacon storage and I don’t understand why. It fail with Android but work well on iOS. My output :
D/EstimoteSDK: DeviceConnectionInternal.changeState:193 Changing internal connection state from DISCONNECTED to CONNECTING
D/EstimoteSDK: BasicConnectionStrategy.connect:50 Connecting to bluetooth device
D/EstimoteSDK: BlueRock.connectInternal:155 Trying to connect to GATT
D/BluetoothGatt: connect() - device: D9:76:65:4A:0C:A1, auto: false
registerApp()
registerApp() - UUID=2d0f94bf-437d-4c2c-ac62-9ae5875fadf0
D/BluetoothGatt: onClientRegistered() - status=0 clientIf=7
V/EstimoteSDK: BeaconService.stopConfigurableDevicesScanning:282 Stopping Configurable Devices scanning
D/BluetoothGatt: onClientConnectionState() - status=0 clientIf=7 device=D9:76:65:4A:0C:A1
V/EstimoteSDK: BlueRock$2.onConnectionStateChange:162 onConnectionStateChange status=0 newState=2 (BlueRock:CONNECTING)
D/BluetoothGatt: discoverServices() - device: D9:76:65:4A:0C:A1
D/EstimoteSDK: BlueRock$2.onConnectionStateChange:164 Connected to GATT server after 1541ms, discovering services: true
D/BluetoothGatt: onSearchComplete() = Device=D9:76:65:4A:0C:A1 Status=0
V/EstimoteSDK: BlueRock$2.onServicesDiscovered:186 Services discovered
V/EstimoteSDK: BlueRock.notifiedConnected:418 Connected to device
D/EstimoteSDK: BasicConnectionStrategy.discoverProtocol:83 Discovering protocol
D/BluetoothGatt: setCharacteristicNotification() - uuid: 6c371002-d2cc-11e4-9a1f-0002a5d5c51b enable: false
D/BluetoothGatt: setCharacteristicNotification() - uuid: 6c371002-d2cc-11e4-9a1f-0002a5d5c51b enable: true
D/EstimoteSDK: DeviceConnectionInternal.changeState:193 Changing internal connection state from CONNECTING to CONNECTED
D/EstimoteSDK: NoAuthorisationConnectionStrategy.checkDeviceVersion:35 Checking device version and available settings
I/MainActivity: Connected to device
D/EstimoteSDK: BeaconService.onStartCommand:102 Got wakeup intent. Let’s Application#onCreate do its job
W/BluetoothGatt: Unhandled exception in callback
com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected STRING but was BEGIN_OBJECT
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.Gson.fromJson(Gson.java:822)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.Gson.fromJson(Gson.java:875)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl.convertBytesToMap(StorageManagerImpl.java:139)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl.access$000(StorageManagerImpl.java:28)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl$1$1.onSuccess(StorageManagerImpl.java:63)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl$4.onSuccess(StorageManagerImpl.java:181)
at com.estimote.mgmtsdk.connection.strategy.DeviceConnectionInternal$9$1.onSuccess(DeviceConnectionInternal.java:599)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProtocol$5.onPacketReceived(PacketProtocol.java:158)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProcessor$AggregatedPacketListeners.onPacketReceived(PacketProcessor.java:253)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProcessor.processPacketBuffer(PacketProcessor.java:230)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProcessor.dataReceived(PacketProcessor.java:161)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProtocol$1.onSuccess(PacketProtocol.java:72)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProtocol$1.onSuccess(PacketProtocol.java:70)
at com.estimote.coresdk.connection.bluerock.BlueRock$2.onCharacteristicChanged(BlueRock.java:240)
at android.bluetooth.BluetoothGatt$1.onNotify(BluetoothGatt.java:360)
at android.bluetooth.IBluetoothGattCallback$Stub.onTransact(IBluetoothGattCallback.java:177)
at android.os.Binder.execTransact(Binder.java:565)
Caused by: java.lang.IllegalStateException: Expected STRING but was BEGIN_OBJECT
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.internal.bind.JsonTreeReader.nextString(JsonTreeReader.java:154)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.internal.bind.TypeAdapters$13.read(TypeAdapters.java:358)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.internal.bind.TypeAdapters$13.read(TypeAdapters.java:346)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.internal.bind.TypeAdapterRuntimeTypeWrapper.read(TypeAdapterRuntimeTypeWrapper.java:40)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.internal.bind.MapTypeAdapterFactory$Adapter.read(MapTypeAdapterFactory.java:187)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.internal.bind.MapTypeAdapterFactory$Adapter.read(MapTypeAdapterFactory.java:145)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.Gson.fromJson(Gson.java:810)
at com.estimote.coresdk.repackaged.gson_v2_3_1.com.google.gson.Gson.fromJson(Gson.java:875)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl.convertBytesToMap(StorageManagerImpl.java:139)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl.access$000(StorageManagerImpl.java:28)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl$1$1.onSuccess(StorageManagerImpl.java:63)
at com.estimote.mgmtsdk.feature.settings.StorageManagerImpl$4.onSuccess(StorageManagerImpl.java:181)
at com.estimote.mgmtsdk.connection.strategy.DeviceConnectionInternal$9$1.onSuccess(DeviceConnectionInternal.java:599)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProtocol$5.onPacketReceived(PacketProtocol.java:158)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProcessor$AggregatedPacketListeners.onPacketReceived(PacketProcessor.java:253)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProcessor.processPacketBuffer(PacketProcessor.java:230)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProcessor.dataReceived(PacketProcessor.java:161)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProtocol$1.onSuccess(PacketProtocol.java:72)
at com.estimote.mgmtsdk.connection.protocol.packet.PacketProtocol$1.onSuccess(PacketProtocol.java:70)
at com.estimote.coresdk.connection.bluerock.BlueRock$2.onCharacteristicChanged(BlueRock.java:240)
at android.bluetooth.BluetoothGatt$1.onNotify(BluetoothGatt.java:360)
at android.bluetooth.IBluetoothGattCallback$Stub.onTransact(IBluetoothGattCallback.java:177)
at android.os.Binder.execTransact(Binder.java:565)
D/BluetoothGatt: onClientConnectionState() - status=19 clientIf=7 device=D9:76:65:4A:0C:A1
V/EstimoteSDK: BlueRock$2.onConnectionStateChange:162 onConnectionStateChange status=19 newState=0 (BlueRock:CONNECTED)
W/EstimoteSDK: BlueRock$2.onConnectionStateChange:167 Disconnected from GATT (we were connected)
D/BluetoothGatt: close()
unregisterApp() - mClientIf=7
D/EstimoteSDK: DeviceConnectionInternal.changeState:193 Changing internal connection state from CONNECTED to DISCONNECTED

It work on Iphone 8 and fail on Oneplus One. Any idea ?
Thanks you to read me !