Kapt: Be less strict when it's impossible to add a generated Kotlin source directory for Android project (KT-22056, EA-114271)
This commit is contained in:
+3
-2
@@ -116,8 +116,9 @@ class KaptProjectResolverExtension : AbstractProjectResolverExtension() {
|
||||
try {
|
||||
sourceSet.generatedKotlinSourcesDirFile?.let { variant.mainArtifact.generatedSourceFolders += it }
|
||||
} catch (e: Throwable) {
|
||||
LOG.error(RuntimeException(
|
||||
"Kapt importer for generated source roots failed, source root name: ${sourceSet.sourceSetName}", e))
|
||||
// There was an error being thrown here, but the code above doesn't work for the newer versions of Android Studio 3
|
||||
// (generatedSourceFolders returns a wrapped unmodifiable list), and the thrown exception breaks the import.
|
||||
// The error will be moved back when I find a work-around for AS3.
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user