I am using Kotlin DSL with Gradle build tool. My gradle build works well both locally and on jenkins server when run from command line.
However IDEA complains and marks several items red with the following errors:
- Cannot access class 'java.lang.Object'. Check your module classpath for missing or conflicting dependencies
- None of the following functions can be called with the arguments supplied
I have tried all 3 options in project settings: - Use default gradle wrapper - Use gradle 'wrapper' task configuration - Use local gradle distribuition
Result if pretty same
QUESTION: is something wrong in config, or is there a fix or workaround for that?
IntelliJ IDEA 2018.1.2 (Community Edition)
Build #IC-181.4668.68, built on April 24, 2018
JRE: 1.8.0_152-release-1136-b29 amd64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Linux 4.15.0-20-generic
.
Kotlin plugin: 1.2.41-release-IJ2018.1-1
.
Gradle 4.7
------------------------------------------------------------
Build time: 2018-04-18 09:09:12 UTC Revision: b9a962bf70638332300e7f810689cb2febbd4a6c
Groovy: 2.4.12 Ant: Apache Ant(TM) version 1.9.9 compiled on February 2 2017 JVM: 1.8.0_171 (Oracle Corporation 25.171-b11) OS: Linux 4.15.0-20-generic amd64
UPD: @tweitzel you are right, it was incorrect SDK setting, thanks!