I\'m in trouble since yesterday. In my internship I faced the following build error, but I couldn\'t understand why :
$ cordova build android
[...]
FAILURE
This is the solution:
cordova plugin rm cordova-plugin-compat --force
Going to add my 2 cents since none of the solutions work for me. Only thing that worked for me:
cordova plugin rm cordova-plugin-compat --force
cordova platform rm android
cordova platform add android@6.3.0
One solution: downgrade cordova android platform @6.2.3
$ cordova platform remove android && cordova platform add android@6.2.3
There may be mismatch of the plugins in the android builds. So better run 2 commands for successful build
cordova platform rm android
cordova platform add android
After wasted 2 days this seems to be only working solutions for me.
I'am using for Ionic 3
Project, I have to do:
ionic cordova plugin rm cordova-plugin-compat --force
ionic cordova plugin add cordova-plugin-compat@1.2
ionic cordova platform rm android
ionic cordova platform add android@6.3.0
it's work for me.
With my Ionic 3 project it was enough to run:
ionic cordova plugin rm cordova-plugin-compat --force
ionic cordova plugin add cordova-plugin-compat@1.2
And then run a build again. No need to remove and add the platform.