Could not find spek:spek-runtime:2.0.16
I started getting this error message after an update from 2.0.15 -> 2.0.16, which is weird as I see that that the latest available version of spek-runtime here is 2.0.0.
Could not resolve all files for configuration ':app:developDebugUnitTestRuntimeClasspath'.
> Could not find spek:spek-runtime:2.0.16.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/spek/spek-runtime/2.0.16/spek-runtime-2.0.16.pom
- https://repo.maven.apache.org/maven2/spek/spek-runtime/2.0.16/spek-runtime-2.0.16.pom
- https://jitpack.io/spek/spek-runtime/2.0.16/spek-runtime-2.0.16.pom
- https://jcenter.bintray.com/spek/spek-runtime/2.0.16/spek-runtime-2.0.16.pom
Required by:
project :app > org.spekframework.spek2:spek-runner-junit5:2.0.16
In 2.0.16 publishing was moved to Maven Central due to bintray being shutdown. Do you have mavenCentral() in your repositories block?
Yes, I have. I see on Maven that all spek modules have the latest version 2.0.16 except spek-runtime which is 2.0.0.
Ahh wait, spek-runner-junit5 shouldn't need spek-runtime but that should be spek-runtime-jvm. The POM file for spek-runner-junit5 is correct: https://repo1.maven.org/maven2/org/spekframework/spek2/spek-runner-junit5/2.0.16/spek-runner-junit5-2.0.16.pom. I wondder why is it asking for spek-runtime. 🤔
My declared dependencies.
val spekVersion = "2.0.15"
testImplementation("org.spekframework.spek2:spek-dsl-jvm:$spekVersion")
testImplementation("org.spekframework.spek2:spek-runner-junit5:$spekVersion")
Works perfectly until the change to 2.0.16
Can you setup a sample project that replicates the issue?
Unfortunately, no, sorry.
But maybe you'll find helpful this output from $ ./gradlew app:dependencies
+--- org.spekframework.spek2:spek-runner-junit5:2.0.16
| +--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.61 -> 1.4.31 (*)
| +--- spek:spek-runtime:2.0.16 FAILED
| \--- org.junit.platform:junit-platform-engine:1.6.0
| +--- org.junit:junit-bom:5.6.0
| | +--- org.junit.platform:junit-platform-commons:1.6.0 (c)
| | \--- org.junit.platform:junit-platform-engine:1.6.0 (c)
| +--- org.apiguardian:apiguardian-api:1.1.0
| +--- org.opentest4j:opentest4j:1.2.0
| \--- org.junit.platform:junit-platform-commons:1.6.0
| +--- org.junit:junit-bom:5.6.0 (*)
| \--- org.apiguardian:apiguardian-api:1.1.0
The dependency really comes from spek-runner-junit5 ¯\_(ツ)_/¯
What gradle version are you using?
Btw, for 2.0.15 you're right, it depends on spek-runtime-jvm
+--- org.spekframework.spek2:spek-runner-junit5:2.0.15
| +--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.61 -> 1.4.31 (*)
| +--- org.spekframework.spek2:spek-runtime-jvm:2.0.15
| | +--- org.spekframework.spek2:spek-dsl-jvm:2.0.15 (*)
| | +--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.61 -> 1.4.31 (*)
| | +--- org.jetbrains.kotlin:kotlin-reflect:1.3.61 -> 1.4.31
| | | \--- org.jetbrains.kotlin:kotlin-stdlib:1.4.31 -> 1.4.32 (*)
I use Gradle v7.0-rc-2
I have the same or a similar problem with atrium (using gradle 6.7)
* What went wrong:
Could not determine the dependencies of task ':spek:test'.
> Could not resolve all task dependencies for configuration ':spek:testRuntimeClasspath'.
> Could not find spek:spek-runtime:2.0.16.
Searched in the following locations:
- https://repo.maven.apache.org/maven2/spek/spek-runtime/2.0.16/spek-runtime-2.0.16.pom
If the artifact you are trying to retrieve can be found in the repository but without metadata in 'Maven POM' format, you need to adjust the 'metadataSources { ... }' of the repository declaration.
Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/6.7/userguide/command_line_interface.html#sec:command_line_warnings
Required by:
project :spek > org.spekframework.spek2:spek-runner-junit5:2.0.16
https://github.com/robstoll/atrium/pull/869/checks?check_run_id=2355507816
My guess it has something to do with not publishing the kotlinMultiplatform publication. Weirdly enough I didn't do any changes publications from 2.0.15 -> 2.0.16.
Interesting, bintray's publish plugin ignored gradle's module metadata files when publishing so it wasn't present in 2.0.15 but now present in 2.0.16 due to the move to central. I think I just need to publish kotlinMultiplatform publication to fix this.
@DmitriyZaitsev @robstoll I suggest to use 2.0.15 for now. #965 will be included in 2.0.17.
Good, I am actually still on 2.0.12 because of https://github.com/spekframework/spek/issues/927. Any chance you fix this as well? Can I help somehow?
Ahh, totally forgot about that issue. @sh-soltanpour is going to look at it.
when will 2.0.17 be released?
@rburgst it is out already.
Hm, its not listed on the github releases
https://search.maven.org/search?q=g:org.spekframework.spek2