0

I am trying to update an older project, from:gradle 5.6.4, kotlin 1.3.30, android build tools 3.6.3 to: gradle 7.3.3, kotlin 1.6.21, android build tools 7.2.2.

The project compiles and runs after this update, but Android Studio Chimpmunk (2021.2.1 Patch1) is not recognizing the 'android' keyword, so whole Android section looks RED. Before the update to kotlin and build tools - there is no such error.

What is the cause of this error? How can it be fixed?

build.gradle.kts

Jonas
  • 2,096
  • 20
  • 17
  • Is this a problem with IntelliJ code highlighting, or do you get errors when you try and build from the command line? – aSemy Oct 26 '22 at 14:43
  • This seems to be intellij (android studio) code highlight issue. Build works fine. – Jonas Oct 27 '22 at 11:29
  • Clear the project caches, IntelliJ caches, unload and reload the Gradle project in IntelliJ, and cross your fingers. Or, instead of `android {}`, you can try using `extensions.configure() { }` (this isn't the correct class! I don't know what the actual package and class name of the Android Gradle extension is!) – aSemy Oct 27 '22 at 14:33

0 Answers0