awesome_notifications
awesome_notifications copied to clipboard
Notification channel 'basic_channel' does not exist., n.a.a.k.f.a:
I/flutter ( 5032): PlatformException(createNewNotification, Notification channel 'basic_channel' does not exist., n.a.a.k.f.a: Notification channel 'basic_channel' does not exist. I/flutter ( 5032): at n.a.a.k.i.g.i(:5) I/flutter ( 5032): at n.a.a.k.i.k.i(Unknown Source:4) I/flutter ( 5032): at n.a.a.k.d.b(Unknown Source:10) I/flutter ( 5032): at n.a.a.f.f(:2) I/flutter ( 5032): at n.a.a.f.onMethodCall(:42) I/flutter ( 5032): at l.a.d.a.w.a(Unknown Source:17) I/flutter ( 5032): at io.flutter.embedding.engine.n.g.e(Unknown Source:17) I/flutter ( 5032): at io.flutter.embedding.engine.FlutterJNI.handlePlatformMessage(Unknown Source:4) I/flutter ( 5032): at android.os.MessageQueue.nativePollOnce(Native Method) I/flutter ( 5032): at android.os.MessageQueue.next(MessageQueue.java:335) I/flutter ( 5032): at android.os.Looper.loopOnce(Looper.java:161) I/flutter ( 5032): at android.os.Looper.loop(Looper.java:288) I/flutter ( 5032): at android.app.ActivityThread.main(ActivityThread.java:7839) I/flutter ( 5032): at java.lang.reflect.Method.invoke(Native Method) I/flutter ( 5032): at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548) I/flutter ( 5032): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1003) I/flutter ( 5032): , null) Exited
Flutter awesome notification not worked in release-apk, code works perfect in debug. please help.
Have you modified something in your Android folder? What changes you made?
No , I haven't change anything in android Folder, I made changes in android folder which mention by package. I just keep Code as per package.
Can you send me your build.gradle files from your Android folder?
android/build.gradle
buildscript {
ext.kotlin_version = '1.4.32'
repositories {
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.1.0'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath 'com.google.gms:google-services:4.3.2'
}
}
allprojects {
repositories {
google()
jcenter()
}
}
rootProject.buildDir = '../build'
subprojects {
project.buildDir = "${rootProject.buildDir}/${project.name}"
project.evaluationDependsOn(':app')
}
task clean(type: Delete) {
delete rootProject.buildDir
}
android/app/build.gradle
def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
localPropertiesFile.withReader('UTF-8') { reader ->
localProperties.load(reader)
}
}
def flutterRoot = localProperties.getProperty('flutter.sdk')
if (flutterRoot == null) {
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
}
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
if (flutterVersionCode == null) {
flutterVersionCode = '1'
}
def flutterVersionName = localProperties.getProperty('flutter.versionName')
if (flutterVersionName == null) {
flutterVersionName = '1.0'
}
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
android {
compileSdkVersion 31
sourceSets {
main.java.srcDirs += 'src/main/kotlin'
}
defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "com.bebuzee"
minSdkVersion 24
targetSdkVersion 31
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
}
buildTypes {
release {
// TODO: Add your own signing config for the release build.
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig signingConfigs.debug
// shrinkResources false
// minifyEnabled false
}
}
}
flutter {
source '../..'
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'com.google.firebase:firebase-messaging:20.1.0'
}
apply plugin: 'com.google.gms.google-services'
What I'm suspecting is that the release version minification and obfuscation process is modifying the enumerator's names and values, preventing awesome from retrieving information from previous channels.
I made a development version with SafeEnum
that fixes this problem. Join our community beta testers page on Discord to be able to use this latest development version.
https://discord.com/invite/MP3sEXPTnx
did anyOne get proper solution for this issue
Hi! Sorry for taking so long to respond to your issue on GitHub. I was focused on releasing the new 0.7.0 version of awesome_notifications
and awesome_notifications_fcm
and i didn't had time enough to do both. But now I can answer all your questions.
So now i'm asking you to recreate this topic using the new issue template. There's a lot of missing informations that i need to understand your problem, and all the instructions are already in the new issue template. Also, remember to check beforehand if your issue was posted by another user.
So I will automatically close all previous issues so far. Sorry for the inconvenience and i will be waiting for your new issue request.
Thank you so much for your support!