'Problem with firebase auth kotlin library version 21.0.4

When I update the com.google.firebase:firebase-auth-ktx library to a version higher than 21.0.1 I get the following warning:

Kotlin library {0} was compiled with a newer Kotlin compiler and can't be read. Please update Kotlin plugin.

I already tried to update the Kotlin plugin in tools->Kotlin->Configure Kotlin Plugin Updates, but it didn't work. I have the latest version of Kotlin plugin and Android Studio installed. How can I solve this problem, or just hide the warning?



Solution 1:[1]

You can try to update the Kotlin version in your build.gradle Project level file, you will find a "plugins" ids, try to set it to 1.6.21 (I have it on 1.6.10):

plugins {
    id 'com.android.application' version '7.1.1' apply false
    id 'com.android.library' version '7.1.1' apply false
    id 'org.jetbrains.kotlin.android' version '1.6.10' apply false
}

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 MACROSystems