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

❓ [ERROR]: خطا در کلاس MyApp.kt #41

Open
mraslamiii opened this issue Feb 21, 2023 · 0 comments
Open

❓ [ERROR]: خطا در کلاس MyApp.kt #41

mraslamiii opened this issue Feb 21, 2023 · 0 comments
Labels
question Further information is requested

Comments

@mraslamiii
Copy link

mraslamiii commented Feb 21, 2023

شرح خطا

سلام و وقت بخیر

تو دایکیومنت نوشته بود وقتی که دارید از نسخه جدید استفاده میکنید نیازی ندارین ریسجتر پلاگین رو انجام بدید پس من بدون اینکه ریجستر پلاگین رو ایمپلمنت کنم کلاسم رو به شکل زیر میسازم
`package biz.metanext.metanext_client

import co.pushe.plus.flutter.PusheFlutterPlugin
import co.pushe.plus.flutter.PusheFlutterPlugin.Companion.debugMode
import io.flutter.app.FlutterApplication
import io.flutter.plugin.common.PluginRegistry

class MyApp : FlutterApplication(){


override fun onCreate() {
    super.onCreate()

    debugMode = true // فعال‌سازی دیباگ مد برای چاپ اطلاعات بیشتر در کنسول
}

}
`
ولی با این کار داخل کلاس pusheFlutterPlugin.kt خطا پیش میاد

@JvmStatic fun <T> initialize(initializer: biz.metanext.metanext_client.MyApp) where T : Context, T : PluginRegistrantCallback { PusheNotificationListener.initialize(initializer) }

initializer رو نمیشناسه

به شکل زیر حالا میام و ریجستر پلاگین رو انجام میدم داخل myApp

` class MyApp : FlutterApplication(), PluginRegistry.PluginRegistrantCallback {

override fun onCreate() {
    super.onCreate()

    debugMode = true // فعال‌سازی دیباگ مد برای چاپ اطلاعات بیشتر در کنسول
}


override fun registerWith(registry: PluginRegistry) {
    PusheFlutterPlugin.registerWith(registry)


}

}`

با این کار ارور کلاس پوشه برطرف میشه ولی اپ دیگه اجرا نمیشه و اروری ک پایین گذاشتم رو میده !

لاگ خطا
لاگی که در لاگ‌کت هنگام رخ‌دادن خطا چاپ می‌شود. متن کامل استک‌تریس را چاپ کنید.

Circular dependency between the following tasks:
:pushe_flutter:compileDebugAidl
\--- :pushe_flutter:compileDebugAidl (*)

اگر میشه یه بار دقیق توضیح میدن که داخل کلاس مای اپ با توجه به نسخه های جدید فلاتر چکار کنیم .. چون سورس گیت هابم قدیمیه و جاوا هست همش
چون وقتی مای اپ رو کلا نمیسازم اپ بدون مشکل اجرا میشه

اطلاعات محیط تست

  • pushe 2.6.1
  • Flutter (Channel stable, 3.7.0,
  • TargetSDK : 33
@mraslamiii mraslamiii added the question Further information is requested label Feb 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant