Lint found fatal errors while assembling a release target Android

I recently found that people are struggling while generating a release APK from Android studio with the error, “Lint found fatal errors while assembling a release target”. Although their App is running successfully in Debug mode. This error happens when we have some issues in some XML files or some other issue not allowing the APK to build. We have the following ways to solve this error.

Solution to Lint found fatal errors

Android studio shows all build errors in html & xml file present at the following link. The best way to solve this error is, just open that file in your browser, check the error and fix it.

For that navigate to the following file & open it in the browser.

/YOUR_APPLICATION/app/build/reports/lint-results-release-fatal.html
Path to lint-results-release-fatal file

When I opened the file in my browser I have seen the following error report. In my scenario, we can see I have an error in my XML file. In your scenario, the error can be different. Just trace your error and try to fix it.

Lint found fatal errors while assembling a release target

In Android Studio, you can also use Analyze > Inspect Code menu option to manually run inspections. Inspection Results window. Here you find the official Android documentation.

Alternative Solution but not Recommended

There is another way to suppress the lint warnings by adding below code into your build.gradle file as Android Studio suggested. But it’s not recommended.

android {
  lintOptions {
    checkReleaseBuilds false
    abortOnError false
  }
}

For other helping solutions, have a look at our Android Articles.

Please share this post:
Native Mobile Application Developer (Android + IOS) having experience in Java, Swift, Kotlin, Objective C, Unity, C#, C/C++, NODE JS & PHP.

Ask a Question

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Related Posts

Begin typing your search term above and press enter to search. Press ESC to cancel.

%d bloggers like this: