Skip to content
This repository has been archived by the owner on Jul 25, 2024. It is now read-only.

Port KGL to Kotlin 1.8.21 #39

Open
Laxystem opened this issue May 22, 2023 · 0 comments
Open

Port KGL to Kotlin 1.8.21 #39

Laxystem opened this issue May 22, 2023 · 0 comments

Comments

@Laxystem
Copy link

Laxystem commented May 22, 2023

Originally, I encountered the following error:

Caused by: java.lang.IllegalStateException: Artifacts of dependency io.ktor:ktor-io-metadata:1.4.0 is built by old Kotlin Gradle Plugin and can't be consumed in this way

It happened because KGL uses an absolutely ancient version of Kotlin (1.3.10 iirc)

Here's the exact place where the error was caused:

// build.gradle.kts:21
val ktorIoVersion: String by extra("1.4.0")

Temporary solution: Override the KGL dependency using your own (doesn't work for JS):

dependencies {
    api("io.ktor:ktor-io:2.3.0")
}

One problem with the above: The Kotlin Version. Really, this solution isn't possible to be PRed into KGL - it uses too ancient of a Kotlin version. Porting KGL to Kotlin 1.8.21 (or an older version; really, anything newer could be nice) will also give KGL the ability to use new features, for example, the following feature was implemented:

Platform specific extensions have not been implemented yet. Mostly because of this.

Using a non-ktor class could solve the issue - and a PR exists for this - but more and more issues like this will arrive.

I see no reason to stay on an ancient version of Kotlin - and if there is one, please, let me know. I'm going to heavily use KGL soon - in fact, I'm currently implementing a math library (definitely not because the one I've found calls its vectors Float3). If KGL isn't maintained anymore, I would like to help.

@Laxystem Laxystem changed the title Error while adding KGL as a dependency Port KGL to Kotlin 1.8.21 May 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant