단비의 개발블로그

[Android] APK 빌드 오류 : Lint found fatal errors while assembling a release target. 본문

Android

[Android] APK 빌드 오류 : Lint found fatal errors while assembling a release target.

단비냥 2020. 7. 25. 21:47
반응형

APK 빌드를 하다보면 앱 실행시에는 보지 못했던

Lint found fatal errors while assembling a release target.

이라는 오류가 뜨면서 빌드가 되지 않을 때가 있습니다.

 

Android Studio에서 아래와 같은 해결방법을 제시해주기도 하는데

이는 임시 방편이므로 원인이 되는 코드를 찾는 방법에 대해 포스팅해보겠습니다.

Lint found fatal errors while assembling a release target.  

To proceed, either fix the issues identified by lint, or modify your build script as follows:  

android {  
    lintOptions {  
        checkReleaseBuilds false  
        // Or, if you prefer, you can continue to check for errors in release builds,  
        // but continue the build even when errors are found:  
        abortOnError false  
    }  
}  

 

android 프로젝트 폴더 내부의 /app/build/reports 폴더 안의

lint-results-release-fatal.xml 또는 lint-results-release-fatal.html

파일을 보면 어떤 코드에서 오류가 발생했는지 적혀있습니다.

 

저같은 경우 보통 xml 파일의 id 참조값을 없는 id로 적었다거나 같은 이유였습니다.

에러가 발생한 파일을 열어보면 어렵지 않게 오류를 찾으실 수 있습니다!

반응형
Comments