Skip to content

Conversation

dkhalanskyjb
Copy link
Contributor

Fixes #496

@dkhalanskyjb dkhalanskyjb added this to the 0.7.0 milestone Mar 31, 2025
@dkhalanskyjb dkhalanskyjb requested a review from ilya-g March 31, 2025 12:29
@dkhalanskyjb dkhalanskyjb changed the title Fix a dependency on kotlinx.serialization.core in JPMS to be truly optional Fix a dependency on kotlinx.serialization.core in JPMS for it to be truly optional Mar 31, 2025
@dkhalanskyjb dkhalanskyjb force-pushed the fix-incorrect-module-info branch from df75736 to 1632f50 Compare April 30, 2025 14:34
kotlin("jvm")
}

java {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAIK, it was required to enable java.modularity.inferModulePath to put compilation dependencies on the module path instead of class path.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or is it now on by default?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like it: https://docs.gradle.org/current/userguide/java_library_plugin.html#sec:java_library_modular

Gradle will automatically put a Jar of your dependencies on the module path, instead of the classpath, if these three things are true

@dkhalanskyjb dkhalanskyjb merged commit 00d5d84 into master May 30, 2025
1 check passed
@dkhalanskyjb dkhalanskyjb deleted the fix-incorrect-module-info branch May 30, 2025 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Module kotlinx.serialization.core not found in module graph
2 participants