Closed wkol closed 2 months ago
Hi, thanks for posting this issue. We’ve reproduced the problem and are actively working on a fix.
Hi @wkol, issue is now fixed in the 3.9.2
release.
Hi @usaimbhayat-stripe , the issue is still reproducible on 3.9.2
com.stripe.stripeterminal.external.models.TerminalException: Bluetooth scan timed out
at com.stripe.stripeterminal.internal.common.adapter.BbposBluetoothAdapter$DiscoverBluetoothReadersOperation.createTimeoutException(BbposBluetoothAdapter.kt:567)
at com.stripe.stripeterminal.internal.common.adapter.BbposAdapter$DiscoverReadersOperation$timeoutFlow$1.invokeSuspend(BbposAdapter.kt:1159)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:104)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644)
at java.lang.Thread.run(Thread.java:1012)
Suppressed: kotlinx.coroutines.flow.internal.AbortFlowException: Flow was aborted, no more elements needed
Suppressed: kotlinx.coroutines.internal.DiagnosticCoroutineContextException: [CoroutineName(Transaction), LazyStandaloneCoroutine{Cancelling}@6f8076c, java.util.concurrent.Executors$FinalizableDelegatedExecutorService@3664135]
Hi @Ekalips -- thanks. It looks like the fix didn't make it into the 3.9.2 release. We're working on fixing this now, and we're planning on releasing a 3.9.3.
Hi @wkol @Ekalips, we have just released 3.9.3
to address this bug. We've done our best to thoroughly test this, please let us know if you still have issues.
Summary
After upgrading the SDK to version 3.9.0 we started observing a large amount of crashes with the following stack trace:
This happens when the discovery process for Bluetooth readers (e.g. M2) results in a timeout. Firstly, the exception is passed to the callback
onFailure
, but later, it is also thrown.Code to reproduce
Android version
12, 13, 14 (but I suppose it is not a version-specific problem)
Impacted devices (Android devices or readers)
Bluetooth readers (e.g M2) Internet readers seems fine
SDK version
3.9.0, but checked on 3.9.1 and it still occurs