paytabscom/paytabs-android-library-sample

Getting Error in Crashlytics as well as not working on some devices.

Closed this issue · 7 comments

Fatal Exception: android.view.ViewRootImpl$CalledFromWrongThreadException
Only the original thread that created a view hierarchy can touch its views.
android.view.ViewRootImpl.checkThread (ViewRootImpl.java:9082)
androidx.appcompat.widget.AppCompatImageView.setImageBitmap (AppCompatImageView.java:112)
com.payment.paymentsdk.f.d.b$d.invokeSuspend (Unknown Source:50)
kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith (ContinuationImpl.kt:33)
kotlinx.coroutines.DispatchedTask.run (DispatchedTask.kt:106)
kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely (CoroutineScheduler.kt:571)
kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask (CoroutineScheduler.kt:750)
kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker (CoroutineScheduler.kt:678)
kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run (CoroutineScheduler.kt:665)

Hello Mohsin,
Pleas share below details with us:
Scenario to produce
Sdk version
And the input data passed to the sdk but no need to send the sensitive data like keys and ids.

Hi,

I checked on 2 different Android OS , at S8+ ,OS Android 9 its working fine but on Note 20 ulter with OS Android 11 crash happen. I also attached a video.. on both devices i tried with same data. Please find the attached recorde video.

I checked with Paytabs SDK version 6.1.8 and 6.1.9 as well

Error Log :

android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views.
at android.view.ViewRootImpl.checkThread(ViewRootImpl.java:10750)
at android.view.ViewRootImpl.requestLayout(ViewRootImpl.java:2209)
at android.view.View.requestLayout(View.java:27055)
at android.view.View.requestLayout(View.java:27055)
at android.view.View.requestLayout(View.java:27055)
at android.view.View.requestLayout(View.java:27055)
at android.view.View.requestLayout(View.java:27055)
at android.view.View.requestLayout(View.java:27055)
at android.widget.ScrollView.requestLayout(ScrollView.java:2594)
at android.view.View.requestLayout(View.java:27055)
at androidx.constraintlayout.widget.ConstraintLayout.requestLayout(ConstraintLayout.java:3593)
at android.view.View.requestLayout(View.java:27055)
at androidx.constraintlayout.widget.ConstraintLayout.requestLayout(ConstraintLayout.java:3593)
at android.view.View.requestLayout(View.java:27055)
at androidx.constraintlayout.widget.ConstraintLayout.requestLayout(ConstraintLayout.java:3593)
at android.view.View.requestLayout(View.java:27055)
at android.widget.ImageView.setImageDrawable(ImageView.java:600)
at androidx.appcompat.widget.AppCompatImageView.setImageDrawable(AppCompatImageView.java:104)
at android.widget.ImageView.setImageBitmap(ImageView.java:764)
at androidx.appcompat.widget.AppCompatImageView.setImageBitmap(AppCompatImageView.java:112)
at com.payment.paymentsdk.f.d.b$d.invokeSuspend(Unknown Source:50)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:106)
at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:571)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:750)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:678)
at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:665)

Untitled.mp4
Untitled.mp4

Yeah i'm passing but it seems not working ..Logo not appeared there in the sdk..
I upgraded SDk 6.1.9 to 6.2.2.. now its working...

Ok. Thanks...