I'm trying to use `1.4-M1` and I'm getting this wa...
# announcements
r
I'm trying to use
1.4-M1
and I'm getting this warning from gradle:
Copy code
w: Runtime JAR files in the classpath should have the same version. These files were found in the classpath:
    /opt/rjaros/.gradle/wrapper/dists/gradle-6.3-all/b4awcolw9l59x95tu1obfh9i8/gradle-6.3/lib/kotlin-stdlib-1.3.70.jar (version 1.3)
...
    /opt/rjaros/.gradle/caches/modules-2/files-2.1/org.jetbrains.kotlin/kotlin-stdlib/1.4-M1/1bd127486717887634cc406a5651bd6090f11678/kotlin-stdlib-1.4-M1.jar (version 1.4)
w: Consider providing an explicit dependency on kotlin-reflect 1.4 to prevent strange errors
w: Some runtime JAR files in the classpath have an incompatible version. Consider removing them from the classpath
Should I ignore this or somehow fix this?
c
you can force all the kotlin libs on the same version with something like this: `
Copy code
implementation(enforcedPlatform("org.jetbrains.kotlin:kotlin-bom:$kotlinVersion"))
or run
./gradlew dependencies
to see what dependency pulls in the old version
m
Use
dependencyInsight
to quickly see what is bringing in a dependency. Very powerful tool that many don't seem to be aware of.
./gradlew dI --dependency kotlin-reflection
will show you what is bringing in kotlin-reflection as a dependency on the 'main' configuration.
dI
is short for
dependencyInsight
. Yes, Gradle supports 'aliasing' out of the box. If you want a different configuration, there's another parameter called
--configuration
. And what you put for the dependency is a
dependency contains x
.
🤩 1
c
you can also combine it with
--scan
to get a web view