Dependency Resolved to Project

Dependencies on previous versions of a project are being resolved to the project itself which doesn’t seem correct. This might be the same issue documented in https://issues.gradle.org/browse/GRADLE-3016 but that discussion specifically mentioned items with the same group, name, and version.

apply plugin: 'base'
   group = 'com.sample'
version = '2.0'
  configurations {
 previousVersion
 }
  dependencies {
 previousVersion 'com.sample:project-dep:1.0'
}
:dependencies
  ------------------------------------------------------------
Root project
------------------------------------------------------------
  archives - Configuration for archive artifacts.
No dependencies
  default - Configuration for default artifacts.
No dependencies
  previousVersion
\--- com.sample:project-dep:1.0 -> project : (*)
  (*) - dependencies omitted (listed previously)

Do you get the same problem with the latest Gradle version (2.2)?

Yes. I get the same result with 1.12 and 2.2. Sorry I didn’t mention that.