Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unstable bluetooth connect workflow #844

Open
SebaDro opened this issue Oct 13, 2021 · 2 comments
Open

Unstable bluetooth connect workflow #844

SebaDro opened this issue Oct 13, 2021 · 2 comments

Comments

@SebaDro
Copy link
Contributor

SebaDro commented Oct 13, 2021

Description
The workflow for connecting to bluetooth devices is unstable, as sometimes the app crashes after re-connecting to a removed device or a device occurs multiple times in the list of paired devices.

How to reproduce
For crashing the app do the following:

  1. Delete a device from the list of paired devices
  2. Click on the back button
  3. Go back to the OBD selection fragment
  4. Try to pair with device you have deleted before
    => app crashed

For multiple occurence of the same device do the steps below:

  1. Pair with a device
  2. Delete the device from the list of paired devices
  3. Rediscover devices
  4. Try to pair with the device you have deleted before
    => device occurs multiple times in the list of paired devices
@SebaDro
Copy link
Contributor Author

SebaDro commented Nov 2, 2021

Fixed in parts by #847

@SebaDro
Copy link
Contributor Author

SebaDro commented Nov 2, 2021

The app still crashes when performing the above described actions. Occuring issue: when resuming to the OBDSelectionFragment the context changes. But inside the BluetoothDevicePairingCallback the context surprisingly is null which leads to a failure when calling getString():

showSnackbar(String.format(
getString(R.string.obd_selection_pairing_success_template),
device.getName()));

Unfortunately, no solution found so far.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant