-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
3.4.0 module name problems #1306
Comments
As a workaround I recommend excluding the non-JVM artifact from your module path. |
* Force upgrade of okio common to 3.4.0 * Suppress graalvm-sdk false positive * Work-around modularity issues with okio (square/okio#1306)
I ran in to this problem in a modular Java application that uses OkHttp. I suggest this simple solution to the okio developers: Add an "Automatic-Module-Name" entry to the manifest of |
That would not be enough. Not only do those two jars have the same inferred module name, they both have classes in the This requires a deeper fix. |
In 3.4.0:
okio-3.4.0.jar
has noAutomatic-Module-Name
specified. Therefore its derived module name isokio
okio-jvm-3.4.0.jar
hasAutomatic-Module-Name: okio
. Therefore its module name is alsookio
When you try to run an application with both of those jar's on the module path (
java --module-path
) you get an error:java.lang.module.FindException: Two versions of module okio found in target/libs (okio-3.4.0.jar and okio-jvm-3.4.0.jar)
In 1.17.5 there is no
okio-jvm-*.jar
andokio-*.jar
hasAutomatic-Module-Name: okio
and this problem did not exist.The text was updated successfully, but these errors were encountered: