Closed odifek closed 3 years ago
I've tried importing it that way and also separately cloning and then opening project and haven't been able to reproduce yet (with same version of AS). Not sure if anyone else reading this has tried this on Linux (in case somehow that's a factor?)
@VeryRoadTrip Just to also confirm you are using 4.2 Canary version as well? Lastly, have you been able to open other Kotlin Multiplatform project successfully?
@odifek @VeryRoadTrip if you haven't already, can you also try to open another Kotlin Multiplatform project and see if you're having same issue (e.g. https://github.com/touchlab/KaMPKit)
I asked in slack and @arkivanov mentioned he had seen same issue during migration to Kotlin 1.4 due to
js {
browser {
}
}
Following is his fix.... @odifek @VeryRoadTrip could one of you check if this fixes issue for you (and perhaps open PR with fix :) )
I think we should just need "browser"()
@joreilly Just tried by myself. The error is there, the suggested fix does not help.
I found this issue opened by Zac Swears. But I am not yet able to make sense of the discussion. https://github.com/gradle/gradle/issues/12126
@arkivanov believes issue might be related to cocoapods plugin. @odifek @VeryRoadTrip could you try opening https://github.com/touchlab/KaMPKit and see if you see same issue (it also uses that plugin)
@joreilly KaMPKit opens fine. But it uses another plugin: co.touchlab.native.cocoapods
That's correct. KaMPKit runs fine on my system also
alpha11 just out....just in case this somehow resolves this issue?
For what it's worth, I can synchronize correctly with AGP 4.2.0-alpha12
I am having the same issue on canary - i can build the web browser target using gradle, but the android build.gradle.kts is not being recognized.
@darran-kelinske-fivestars is this also on linux?
yes sir - on the latest ubuntu - tried java 8 and 11 as the project sdk
Unfortunately I don't have a linux setup to test this on....if anyone here is able to diagnose and create PR that would be great
what OS are you running?
On Thu, Nov 19, 2020 at 1:29 PM joreilly notifications@github.com wrote:
Unfortunately I don't have a linux setup to test this on....if anyone here is able to diagnose and create PR that would be great
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/joreilly/PeopleInSpace/issues/8#issuecomment-730588412, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALY6HJ6LRY6W6YDXPP74IU3SQVWYDANCNFSM4QQ64NTA .
macOS
This fixed it for me on Ubuntu https://github.com/joreilly/PeopleInSpace/pull/14
Curious if other folks that reported issues here using linux are seeing this resolved using canary 16 version?
@odifek - any luck for you?
@darran-kelinske-fivestars yea. Works fine now on latest canary versions
ok, going to close this for now and we can reopen if the issue resurfaces
Project import fails with error
Please initialize at least one Kotlin target in 'common (:common)'.
OS: Ubuntu Linux 20.04
Android Studio Version: 4.2 Canary 8. (No multiplatform project has been done before now)
Clicking Run with --debug option returns this error.
Caused by: org.gradle.internal.component.AmbiguousConfigurationSelectionException: The consumer was configured to find a runtime of a library compatible with Java 14, packaged as a jar, and its dependencies declared externally, as well as attribute 'org.jetbrains.kotlin.platform.type' with value 'jvm'. However we cannot choose between the following variants of project :common:
Changing the default system jdk to java 8 prints the same message but now Java 8 instead of Java 14.