MXCzkEVM / datadash-wallet

Other
0 stars 2 forks source link

AXS blueberry ring connection error (intermittent) #254

Open reasje opened 3 months ago

reasje commented 3 months ago

According to logs, Sometimes the connection for syncing or transferring data is not hapening: NOTE: the rest of errors are occured because the connection didn't happen.


 2024-07-18 10:58:55   LogLevel.INFO      collectLog   onConsoleMessage: {message: BluetoothRemoteGATTServer:connect  {
  "status": "failed",
  "message": "FlutterBluePlusException | connect | android-code: 133 | ANDROID_SPECIFIC_ERROR",
  "data": null
}, messageLevel: 1}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   onConsoleMessage: {message: BluetoothRemoteGATTServer:getPrimaryService  0000fff0-0000-1000-8000-00805f9b34fb, messageLevel: 1}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   handleBluetoothRemoteGATTServerGetPrimaryService : {service: 0000fff0-0000-1000-8000-00805f9b34fb}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   onConsoleMessage: {message: BluetoothRemoteGATTServer:getPrimaryService  {
  "status": "failed",
  "message": "FlutterBluePlusException | discoverServices | fbp-code: 6 | device is not connected",
  "data": null
}, messageLevel: 1}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   onConsoleMessage: {message: BluetoothRemoteGATTService:getCharacteristic  0000fff6-0000-1000-8000-00805f9b34fb, messageLevel: 1}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   handleBluetoothRemoteGATTServiceGetCharacteristic : {characteristic: 0000fff6-0000-1000-8000-00805f9b34fb}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   onConsoleMessage: {message: BluetoothRemoteGATTService:getCharacteristic  {
  "status": "failed",
  "message": "type 'Null' is not a subtype of type 'String'",
  "data": null
}, messageLevel: 1}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   onConsoleMessage: {message: BluetoothRemoteGATTService:getCharacteristic  0000fff7-0000-1000-8000-00805f9b34fb, messageLevel: 1}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   handleBluetoothRemoteGATTServiceGetCharacteristic : {characteristic: 0000fff7-0000-1000-8000-00805f9b34fb}  
 2024-07-18 10:58:55   LogLevel.INFO      collectLog   onConsoleMessage: {message: BluetoothRemoteGATTService:getCharacteristic  {
  "status": "failed",
  "message": "type 'Null' is not a subtype of type 'String'",
  "data": null
}, messageLevel: 1}  ```
reasje commented 3 months ago

According to my research the issue seems to be of no specific cause, thus there is no firm answer for that, However I made some changes in order to detect connection and disconnection and do some following actions after that. Also I have added the error throwing because previously If the action failed user wouldn't be noticed about that.

reasje commented 3 months ago

Dev log : JS channel has been updated in order to support throwing errors

reasje commented 3 months ago

@SanghamitraBhowmick1993 Plz try again and see If you seet these imrpovements:

  1. You should get proper error message if connection didn't happen
  2. Connection error should happen less than before however there is a possibility that the hapening doesn't change, If that is the case I need the senarios in which this fail happen.
reasje commented 2 months ago

Image

The error seems to have no solutions, I will add a mechanism to retry till to some number If It fails.