1. 在根目录build.gradle中,把android gradle plugin版本设置为4.0.0 (原始为3.2.1, 报错)
dependencies {
classpath 'com.android.tools.build:gradle:4.0.0'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}