Skip to content
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

Some published artifacts contain module-info.class instead of module-info.java #2003

Closed
rgoldberg opened this issue Sep 7, 2019 · 2 comments

Comments

@rgoldberg
Copy link

junit-platform-commons-1.5.1-sources.jar downloaded from Maven Central has module-info.class instead of module-info.java.

This same problem might occur in other files & other versions.

@sormuras
Copy link
Member

sormuras commented Sep 7, 2019

Thanks for raising this issue. Good catch!

junit-jupiter-5.5.1-sources.jar has it too... others as well. Like junit-jupiter-5.6.0-20190906.085229-49-sources.jar. Same goes for all *-javadoc.jar classified jars, like junit-jupiter-5.5.1-javadoc.jar.

@sormuras
Copy link
Member

sormuras commented Sep 7, 2019

Underlying reason is this block that's applied to all Jar tasks:

from("$buildDir/classes/java/module/$javaModuleName") {
include("module-info.class")
}

@sormuras sormuras modified the milestones: 5.6 M1, 5.5.2 Sep 7, 2019
@sbrannen sbrannen mentioned this issue Sep 7, 2019
3 tasks
sbrannen pushed a commit that referenced this issue Sep 7, 2019
Prior to this commit, all JAR files generated for a published module
included their compiled module descriptor within the root directory
of the artifact.

This commit a) includes the compiled module descriptor only in JAR
files that have no classifier specified and b) stores the source of
each module descriptor within the matching `*-source.jar` file.

Fixes #2003
@sbrannen sbrannen changed the title junit-platform-commons-1.5.1-sources.jar from Maven Central has module-info.class instead of module-info.java Published artifacts contain module-info.class instead of module-info.java Sep 7, 2019
sbrannen added a commit that referenced this issue Sep 7, 2019
@sbrannen sbrannen changed the title Published artifacts contain module-info.class instead of module-info.java Some published artifacts contain module-info.class instead of module-info.java Sep 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants