1.运行时遇到 Error:Uncaught translation error: java.util.concurrent.ExecutionException: java.lang.OutOfMemoryError: GC overhead limit exceeded错误和 To run dex in process, the Gradle daemon needs a larger heap. 警告 在build.gragle中加入下面方法,测试ok
dexOptions {
javaMaxHeapSize"4g"
}
lintOptions {
checkReleaseBuildsfalse
abortOnErrorfalse
}
2. 用firebas 遇到 Default FirebaseApp is not initialized in this process com.shidaiyinuo.YNHospitalUser:QALSERVICE. Make sure to call FirebaseApp.initializeApp(Context) first 问题 需要在调用前 调用FirebaseApp.initializeApp(this)方法