Could not get unknown property ‘manifestOutputDirectory‘ for task 问题解决

一、问题现象:

将Android Studio的Gradle升级到最新版本后编译运行程序时提示以下错误

Execution failed for task ':xx:processDebugManifest'.
> Could not get unknown property 'manifestOutputDirectory' for task ':xx:processDebugManifest' of type com.android.build.gradle.tasks.ProcessMultiApkApplicationManifest.

* Try:
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.

二、原因

通过百度后原因是工程中引用的“华为消息推送插件”的版本比较低导致的

三、解决方案

将classpath 'com.huawei.agconnect:agcp:1.3.1.300' 
改为classpath 'com.huawei.agconnect:agcp:1.4.1.300'

Could not get unknown property ‘manifestOutputDirectory‘ for task 问题解决_第1张图片

你可能感兴趣的:(Android,android,android,studio,gradle)