#21757·checkstyle

Compilation warning due to required filename-based automodules

Author: romaniCreated Sep 27, 2026Updated Sep 28, 2026
Labelsapproved

we merged and released https://github.com/checkstyle/checkstyle/issues/14120

now we have:

...
[INFO] --- compiler:3.16.0:compile (default-compile) @ checkstyle ---
[WARNING] ***********************************************************************************************************************************************************************************************************
[WARNING] * Required filename-based automodules detected: [commons-collections-3.2.2.jar, ant-1.10.18.jar, jsr305-3.0.2.jar, Saxon-HE-12.9.jar]. Please don't publish this project to a public artifact repository! *
[WARNING] ***********************************************************************************************************************************************************************************************************
[INFO] Recompiling the module because of changed source code.
[INFO] Compiling 499 source files with javac [debug release 21 module-path] to target/classes
[WARNING] /home/roman/github/checkstyle/checkstyle/src/main/java/module-info.java:[39,41] requires transitive directive for an automatic module
[WARNING] /home/roman/github/checkstyle/checkstyle/src/main/java/module-info.java:[54,30] requires transitive directive for an automatic module
...

https://github.com/checkstyle/checkstyle/blob/ec5e9c96b14b9acf714d65602957c2117a3c65a8/src/main/java/module-info.java#L39

https://github.com/checkstyle/checkstyle/blob/ec5e9c96b14b9acf714d65602957c2117a3c65a8/src/main/java/module-info.java#L54

WE need to find way to avoid such warnings. We need to send PRs to such projects, adding it as an Automatic-Module-Name: <module name> entry to the library's MANIFEST.MF. https://dzone.com/articles/automatic-module-name-calling-all-java-library-maintainers

Saxon.HE already updated, we wait for next release of it.