cafebazaar / flutter_poolakey Goto Github PK
View Code? Open in Web Editor NEWLicense: Apache License 2.0
License: Apache License 2.0
It happens sometimes and I guess it might be related to the device having internet connection problems. This is what I found on debug console:
E/JavaBinder( 5318): !!! FAILED BINDER TRANSACTION !!! (parcel size = 180)
D/AndroidRuntime( 5318): Shutting down VM
E/AndroidRuntime( 5318): FATAL EXCEPTION: main
E/AndroidRuntime( 5318): Process: com.sppcco.tperacc, PID: 5318
E/AndroidRuntime( 5318): java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
E/AndroidRuntime( 5318): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:558)
E/AndroidRuntime( 5318): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)
E/AndroidRuntime( 5318): Caused by: java.lang.reflect.InvocationTargetException
E/AndroidRuntime( 5318): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime( 5318): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
E/AndroidRuntime( 5318): ... 1 more
E/AndroidRuntime( 5318): Caused by: android.os.DeadObjectException: Transaction failed on small parcel; remote process probably died, but this could also be caused by running out of binder buffe
E/AndroidRuntime( 5318): at android.os.BinderProxy.transactNative(Native Method)
E/AndroidRuntime( 5318): at android.os.BinderProxy.transact(BinderProxy.java:584)
E/AndroidRuntime( 5318): at com.android.vending.billing.IInAppBillingService$Stub$Proxy.isBillingSupported(IInAppBillingService.java:324)
E/AndroidRuntime( 5318): at ir.cafebazaar.poolakey.billing.connection.ServiceBillingConnection.isPurchaseTypeSupported(ServiceBillingConnection.kt:121)
E/AndroidRuntime( 5318): at ir.cafebazaar.poolakey.billing.connection.ServiceBillingConnection.onServiceConnected(ServiceBillingConnection.kt:98)
E/AndroidRuntime( 5318): at android.app.LoadedApk$ServiceDispatcher.doConnected(LoadedApk.java:2188)
E/AndroidRuntime( 5318): at android.app.LoadedApk$ServiceDispatcher$RunConnection.run(LoadedApk.java:2221)
E/AndroidRuntime( 5318): at android.os.Handler.handleCallback(Handler.java:942)
E/AndroidRuntime( 5318): at android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime( 5318): at android.os.Looper.loopOnce(Looper.java:201)
E/AndroidRuntime( 5318): at android.os.Looper.loop(Looper.java:288)
E/AndroidRuntime( 5318): at android.app.ActivityThread.main(ActivityThread.java:7898)
kotlin.UninitializedPropertyAccessException: lateinit property paymentConnection has not been initialized
E/AndroidRuntime(12583): at android.app.ActivityThread.performDestroyActivity(ActivityThread.java:4605)
E/AndroidRuntime(12583): at android.app.ActivityThread.handleDestroyActivity(ActivityThread.java:4623)
E/AndroidRuntime(12583): at android.app.ActivityThread.-wrap5(Unknown Source:0)
E/AndroidRuntime(12583): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1757)
E/AndroidRuntime(12583): at android.os.Handler.dispatchMessage(Handler.java:105)
E/AndroidRuntime(12583): at android.os.Looper.loop(Looper.java:164)
E/AndroidRuntime(12583): at android.app.ActivityThread.main(ActivityThread.java:6944)
E/AndroidRuntime(12583): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(12583): at com.android.internal.os.Zygote$MethodAndArgsCaller.run(Zygote.java:327)
E/AndroidRuntime(12583): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1374)
E/AndroidRuntime(12583): Caused by: kotlin.UninitializedPropertyAccessException: lateinit property paymentConnection has not been initialized
What should I do to fix this error?
FAILURE: Build failed with an exception.
Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
Could not find com.github.cafebazaar.Poolakey:poolakey:2.2.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/com/github/cafebazaar/Poolakey/poolakey/2.2.0/poolakey-2.2.0.pom
- https://repo.maven.apache.org/maven2/com/github/cafebazaar/Poolakey/poolakey/2.2.0/poolakey-2.2.0.pom
- https://storage.googleapis.com/download.flutter.io/com/github/cafebazaar/Poolakey/poolakey/2.2.0/poolakey-2.2.0.pom
Required by:
project :app > project :flutter_poolakey
Run with --stacktrace option to get the stack trace.
Run with --info or --debug option to get more log output.
Run with --scan to get full insights.
BUILD FAILED in 29s
Exception: Gradle task assembleDebug failed with exit code 1
با سلام.
خطای زیر در زمان فراخوانی متد connect مشاهده شد و باعث کرش کردن و بسته شدن اپ شد. اهمیتی ندارد این متد چه زمانی و به چه طریقی فراخوانی شود. فراخوانی متد connect بازار در هر زمانی و شرایطی با این خطا مواجه خواهد شد :
Syncing files to device SM A525F...
D/AndroidRuntime(20899): Shutting down VM
E/AndroidRuntime(20899): FATAL EXCEPTION: main
E/AndroidRuntime(20899): Process:….., PID: ….
E/AndroidRuntime(20899): java.lang.RuntimeException: Unable to start receiver ir.cafebazaar.poolakey.receiver.BillingReceiver: java.lang.IllegalStateException: Reply already submitted
E/AndroidRuntime(20899): at android.app.ActivityThread.handleReceiver(ActivityThread.java:4903)
E/AndroidRuntime(20899): at android.app.ActivityThread.-$$Nest$mhandleReceiver(Unknown Source:0)
E/AndroidRuntime(20899): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2420)
E/AndroidRuntime(20899): at android.os.Handler.dispatchMessage(Handler.java:106)
E/AndroidRuntime(20899): at android.os.Looper.loopOnce(Looper.java:226)
E/AndroidRuntime(20899): at android.os.Looper.loop(Looper.java:313)
E/AndroidRuntime(20899): at android.app.ActivityThread.main(ActivityThread.java:8762)
E/AndroidRuntime(20899): at java.lang.reflect.Method.invoke(Native Method)
E/AndroidRuntime(20899): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:604)
E/AndroidRuntime(20899): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1067)
E/AndroidRuntime(20899): Caused by: java.lang.IllegalStateException: Reply already submitted
E/AndroidRuntime(20899): at io.flutter.embedding.engine.dart.DartMessenger$Reply.reply(DartMessenger.java:431)
E/AndroidRuntime(20899): at io.flutter.plugin.common.MethodChannel$IncomingMethodCallHandler$1.success(MethodChannel.java:272)
E/AndroidRuntime(20899): at ir.cafebazaar.flutter_poolakey.FlutterPoolakeyPlugin$connect$1$1.invoke(FlutterPoolakeyPlugin.kt:114)
E/AndroidRuntime(20899): at ir.cafebazaar.flutter_poolakey.FlutterPoolakeyPlugin$connect$1$1.invoke(FlutterPoolakeyPlugin.kt:113)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.callback.ConnectionCallback$connectionSucceed$2.invoke(ConnectionCallback.kt:19)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.callback.ConnectionCallback$connectionSucceed$2.invoke(ConnectionCallback.kt:6)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.billing.connection.ReceiverBillingConnection.onBillingSupportActionReceived(ReceiverBillingConnection.kt:428)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.billing.connection.ReceiverBillingConnection.onActionReceived(ReceiverBillingConnection.kt:131)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.billing.connection.ReceiverBillingConnection.access$onActionReceived(ReceiverBillingConnection.kt:47)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.billing.connection.ReceiverBillingConnection$createReceiverConnection$1.onNewBroadcastReceived(ReceiverBillingConnection.kt:122)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.receiver.BillingReceiver.notifyObservers(BillingReceiver.kt:23)
E/AndroidRuntime(20899): at ir.cafebazaar.poolakey.receiver.BillingReceiver.onReceive(BillingReceiver.kt:16)
E/AndroidRuntime(20899): at android.app.ActivityThread.handleReceiver(ActivityThread.java:4894)
E/AndroidRuntime(20899): ... 9 more
I/Process (20899): Sending signal. PID: 20899 SIG: 9
Lost connection to device.
این مشکل بر روی دستگاه Samsung A 52 با اندروید ورژن 13 و One UI version 5.1 وجود دارد.
بر روی برخی دستگاه های با ورژن قدیمی اندروید بررسی شد و مشکل فوق وجود نداشت.
ورژن فلاتر : 3.19.0
ورژن پولکی : 2.2.0
درضمن، هشدار زیر هم در ورژن فوق نمایش داده میشود.
AppData\Local\Pub\Cache\hosted\pub.dev\flutter_poolakey-2.2.0\android\src\main\kotlin\ir\cafebazaar\flutter_poolakey\PaymentActivity.kt:41:13: warning: 'when' is exhaustive so 'else' is redundant here
else -> throw InvalidParameterException("Undefined command: $command")
^
این پکیج با ورژن 3 فلاتر ناسازگار است
لطفا پیگیری های لازم را انجام دهید
سلام من وقتی این پکیج رو در فایل pubscpec.yaml قرار می دم و دستور flutter pub get میزنم دریافت میکنه اما بعدش که اجرا می کنم خطای زیر میده:
`
FAILURE: Build failed with an exception.
Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
Could not find com.github.cafebazaar.Poolakey:poolakey:2.2.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/com/github/cafebazaar/Poolakey/poolakey/2.2.0/poolakey-2.2.0.pom
- https://repo.maven.apache.org/maven2/com/github/cafebazaar/Poolakey/poolakey/2.2.0/poolakey-2.2.0.pom
- https://storage.googleapis.com/download.flutter.io/com/github/cafebazaar/Poolakey/poolakey/2.2.0/poolakey-2.2.0.pom
- https://jcenter.bintray.com/com/github/cafebazaar/Poolakey/poolakey/2.2.0/poolakey-2.2.0.pom
Required by:
project :app > project :flutter_poolakey
Run with --stacktrace option to get the stack trace.
Run with --info or --debug option to get more log output.
Run with --scan to get full insights.
BUILD FAILED in 2m 59s
Exception: Gradle task assembleDebug failed with exit code 1
`
Unable to destroy activity {ir.cafebazaar.flutter_poolakey_example/ir.cafebazaar.flutter_poolakey_example.MainActivity}: kotlin.KotlinNullPointerException
I've got this exception in my app and also in example app created by your team.
I want to use both Myket and Cafebazaar plugins for my in-app purchases.
Because both packages contain IInAppBillingService.aidl
flutter build has an error.
Duplicate source file detected
Please fix this issue or give me a clue what to do
من از لایبرری پولکی فلاتر برای پیاده سازی استفاده کردم
کد زیر خطایی ندارد و گویا به بازار متصل می شویم
connected = await FlutterPoolakey.connect(
AppConfig.cafebazaarRSA,
onDisconnected: () => Utility.printLog(["Cafebaazar", "onDisconnected"]),
);
اما کد زیر به خطا دارد
PurchaseInfo? response = await FlutterPoolakey.purchase(productId);
خطا:
PlatformException(FAILED_TO_BEGIN_FLOW, ir.cafebazaar.poolakey.exception.ResultNotOkayException: Failed to receive response from Bazaar, null, null)
موارد زیر همه بررسی شده و درست هستند:
RSA - productId
برنامه هم در کافه بازار منتشر شده یک محصول رایگان هم برای تست تعریف شده.
لطفا راهنمایی بفرمایید
This is the error output of gradle build.
Execution failed for task ':flutter_poolakey:generateReleaseRFile'.
> Could not resolve all files for configuration ':flutter_poolakey:releaseCompileClasspath'
سلام
تخفیف پویا رو در این کتابخانه پیدا نکردم. لطفا اضافه کنید
با تشکر
سلام و خداقوت
طبق فایل راهنما کدها توی برنامه قرار گرفته ولی موقع اجرا خطای زیر رو میده:
flutter\.pub-cache\hosted\pub.dartlang.org\flutter_poolakey-2.0.0\android\src\main\kotlin\ir\cafebazaar\flutter_poolakey\FlutterPoolakeyPlugin.kt: (41, 33): Type mismatch: inferred type is BinaryMessenger? but BinaryMessenger was expected
لطفا راهنمایی بفرمایید.
there is no init method in last version but there is a connect which I think does the same
روی دیباگ مود و ریلیز مود همه چیز درست است و کار می کند اما زمانی که میخواهم روی پروفایل مود برنامه رو اجرا کنم با خطای زیر رو به رو میشم
e: file:///Users/developer/.pub-cache/hosted/pub.dev/flutter_poolakey-2.1.0/android/src/main/kotlin/ir/cafebazaar/flutter_poolakey/FlutterPoolakeyPlugin.kt:102:36 Unresolved reference: POOLAKEY_VERSION
FAILURE: Build failed with an exception.
A failure occurred while executing org.jetbrains.kotlin.compilerRunner.GradleCompilerRunnerWithWorkers$GradleKotlinCompilerWorkAction
plz fix this package for compatible with android Api 31.
in manifest for any activity add export = true or false
thanks
this two weeks i was drowned and frustrated because i thought i missed up
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.