Local notifications plugin is not working in ionic 3.8
The problem begins when we try to build an app and it shows an error ,as soon as i remove plugin it works fine.
I am having the same issue
if u find any sol. plzz forwrd it.
What is your ionic info
output?
What error are you getting?
What “local notifications” are you referring to? A Cordova plugin? Ionic Native plugin?
Which Error???
When sombody ask you “I have problem with my computer”, can you tell him the sollution?
Spoiler : No you can’t, because you don’t know WHAT the problem is.
:compileDebugJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:24: error: cannot find symbol
import android.app.NotificationChannel;
^
symbol: class NotificationChannel
location: package android.app
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:41: error: cannot find symbol
import static android.os.Build.VERSION_CODES.O;
^
symbol: static O
location: class
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:109: error: cannot find symbol
if (SDK_INT < O)
^
symbol: variable O
location: class Manager
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:112: error: cannot find symbol
NotificationChannel channel = mgr.getNotificationChannel(CHANNEL_ID);
^
symbol: class NotificationChannel
location: class Manager
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:112: error: cannot find symbol
NotificationChannel channel = mgr.getNotificationChannel(CHANNEL_ID);
^
symbol: method getNotificationChannel(String)
location: variable mgr of type NotificationManager
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:117: error: cannot find symbol
channel = new NotificationChannel(
^
symbol: class NotificationChannel
location: class Manager
Note: Some input files use or override a deprecated API.
:compileDebugJavaWithJavac FAILED
Note: Recompile with -Xlint:deprecation for details.
6 errors
BUILD FAILED
Total time: 33.709 secs
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
Error: cmd: Command failed with exit code 1 Error output:
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:24: error: cannot find symbol
import android.app.NotificationChannel;
^
symbol: class NotificationChannel
location: package android.app
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:41: error: cannot find symbol
import static android.os.Build.VERSION_CODES.O;
^
symbol: static O
location: class
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:109: error: cannot find symbol
if (SDK_INT < O)
^
symbol: variable O
location: class Manager
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:112: error: cannot find symbol
NotificationChannel channel = mgr.getNotificationChannel(CHANNEL_ID);
^
symbol: class NotificationChannel
location: class Manager
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:112: error: cannot find symbol
NotificationChannel channel = mgr.getNotificationChannel(CHANNEL_ID);
^
symbol: method getNotificationChannel(String)
location: variable mgr of type NotificationManager
G:\ionic\dexterio\platforms\android\src\de\appplant\cordova\plugin\notification\Manager.java:117: error: cannot find symbol
channel = new NotificationChannel(
^
symbol: class NotificationChannel
location: class Manager
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
6 errors
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
[ERROR] An error occurred while running cordova build android (exit code 1)
Yes same problem.
Even on a blank project as soon as i install the plugin and try to build , same error appears.
And yes user5555 i apologize for not listing the error.
It seems like there is an error in the plugin - the compiler encounters errors while compiling.
That could also help to pinpoint the error more easierly. (because it shows the modt important versions and information)