Hi, when I add this : ```implementation("io.kotest...
# kotest
w
Hi, when I add this :
Copy code
implementation("io.kotest:kotest-property:4.2.5")
to my commonTest sourceSet, I get this error when I gradle sync : Could not resolve io.kotestkotest property4.2.5. the goal is to add Kotest to my multi-platform common module (commonTest)
a
Looks like gradle is not able to resolve the dependency. It is present in maven central though. https://search.maven.org/artifact/io.kotest/kotest-property/4.2.5/pom can you please verify you have mavenCentral() in repositories {} block and there is no firewall in between which is blocking this.
w
yes I have mavenCentral() and there is no firewall blocking
Ok if you can try this : create a new mp library (Choosing kotlin template, Gradle Kotlin, and Library in project template) then add
Copy code
val commonTest by getting {
    dependencies {
        implementation(kotlin("test-common"))
        implementation(kotlin("test-annotations-common"))
        implementation("io.kotest:kotest-property:4.2.5")
    }
}
Intellij here btw -latest
Copy code
No matching variant of io.kotest:kotest-property:4.2.5 was found. The consumer was configured to find a usage of 'kotlin-api' of a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'native', attribute 'org.jetbrains.kotlin.native.target' with value 'ios_x64' but:
          - Variant 'js-api' capability io.kotest:kotest-property:4.2.5 declares a usage of 'kotlin-api' of a component:
              - Incompatible because this component declares a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'js' and the consumer needed a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'native'
              - Other compatible attribute:
                  - Doesn't say anything about org.jetbrains.kotlin.native.target (required 'ios_x64')
          - Variant 'js-runtime' capability io.kotest:kotest-property:4.2.5:
              - Incompatible because this component declares a usage of 'kotlin-runtime' of a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'js' and the consumer needed a usage of 'kotlin-api' of a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'native'
              - Other compatible attribute:
                  - Doesn't say anything about org.jetbrains.kotlin.native.target (required 'ios_x64')
          - Variant 'jvm-api' capability io.kotest:kotest-property:4.2.5 declares an API of a component:
              - Incompatible because this component declares a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'jvm' and the consumer needed a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'native'
              - Other compatible attribute:
                  - Doesn't say anything about org.jetbrains.kotlin.native.target (required 'ios_x64')
          - Variant 'jvm-runtime' capability io.kotest:kotest-property:4.2.5 declares a runtime of a component:
              - Incompatible because this component declares a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'jvm' and the consumer needed a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'native'
              - Other compatible attribute:
                  - Doesn't say anything about org.jetbrains.kotlin.native.target (required 'ios_x64')
          - Variant 'metadata-api' capability io.kotest:kotest-property:4.2.5:
              - Incompatible because this component declares a usage of 'kotlin-metadata' of a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'common' and the consumer needed a usage of 'kotlin-api' of a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'native'
              - Other compatible attribute:
                  - Doesn't say anything about org.jetbrains.kotlin.native.target (required 'ios_x64')
          - Variant 'metadata-commonMainMetadataElements' capability io.kotest:kotest-property:4.2.5 declares a usage of 'kotlin-api' of a component:
              - Incompatible because this component declares a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'common' and the consumer needed a component, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'native'
              - Other compatible attribute:
                  - Doesn't say anything about org.jetbrains.kotlin.native.target (required 'ios_x64')
based on this error I think the artifact is only available for JVM targets, after I removed all my targets -except jvm-, the build succeeded. but now I'm a bit confused .-.??
s
Property is js and jvm only. Not native. It looks like its trying to find a native dep
👍 1