Suddenly I’m having this issue. All my newly created Gradle projects won’t refresh any local dependencies, except from the basic that came with the build.gradle (commons-collections, junit, hamcrest)
My build.gradle is as following:
apply plugin: 'java'
apply plugin: 'eclipse'
sourceCompatibility = 1.8
version = '1.0'
jar {
manifest {
attributes 'Implementation-Title': 'Gradle Quickstart',
'Implementation-Version': version
}
}
repositories {
mavenCentral()
}
dependencies {
compile group: 'commons-collections', name: 'commons-collections', version: '3.2'
//Newly added
compile("org.springframework.boot:spring-boot-starter-data-jpa")
compile("com.h2database:h2")
//Endtag: Newly added
testCompile group: 'junit', name: 'junit', version: '4.+'
}
test {
systemProperties 'property': 'value'
}
uploadArchives {
repositories {
flatDir {
dirs 'repos'
}
}
}
The Eclipse Error description shows the following:
Illegal entry in Gradle Dependencies: C:/Users/.../Eclipse_workspace/unresolved dependency - org.springframework.boot spring-boot-starter-data-jpa org.springsource.ide.eclipse.gradle.core.classpathcontainer
and
Illegal entry in Gradle Dependencies: C:/Users/.../Eclipse_workspace/unresolved dependency - com.h2database h2org.springsource.ide.eclipse.gradle.core.classpathcontainer
The strange thing is that all of my previously created Gradle Projects before this started to happen, refreshes and downloads its dependencies without any problem!
Note: If these new projects needs to download a new dependency, then IT IS ADDED CORRECTLY.
Note2: I’ve already try deleting all the gradle cache and re-downloading every library again.