androidandroid-studiogradle

Android Studio Kotlin not configured on Gradle 7.4 with includeBuild


I have a composite project with one main project and the second included with includeBuild in settings.gradle.

After upgrading to Gradle 7.4 and Android Studio Flamingo, the Gradle sync says it was completed successfully. But all imports in the main projects are red, and the studio shows "Kotlin not configured" hint. At the same time, the included project is also not synced properly and is not available for coding.

How to fix this problem?


Solution

  • Apparently, sending usage statistics to Google may break your Android Studio sync. See the link for details: https://issuetracker.google.com/issues/226095015?pli=1

    So to fix this disable the statistics in settings like this: enter image description here

    Magic :)

    P.s. if you do not have includeBuild in your project, probably you should check this topic for general reasons for "Kotlin not configured": Updated to Android Studio 3.0. Getting a "Kotlin not configured" error