Bug 65183

Summary: Dependency on batik-all causes JPMS errors with OOXML artifact
Product: POI Reporter: Marius Volkhart <marius>
Component: XWPFAssignee: POI Developers List <dev>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P2    
Version: 5.0.x-dev   
Target Milestone: ---   
Hardware: PC   
OS: Mac OS X 10.1   

Description Marius Volkhart 2021-03-13 15:31:47 UTC
Using a build of the 5.+ OOXML artifact in an application built with the Gradle modularity plugin, build-time errors report "error: the unnamed module reads package org.apache.batik.transcoder from both batik.transcoder and batik.all
"

Batik-all is a strange artifact. It's POM declares dependencies on all the sub-JARs, but its JAR has all of the sub-jars repackaged. This results in two JARs with the package "org.apache.batik.transcoder". And since Batik doesn't do any module naming, a conflict occurs.

I think the right answer here is to change the POI OOXML POM to use more specific Batik dependencies, not batik-all. The Ant build already specifies all of the individual JARs and doesn't use batik-all, so it likely doesn't exhibit this behavior.
Comment 1 Marius Volkhart 2021-03-13 15:33:14 UTC
Fix at https://github.com/apache/poi/pull/230

Just checking for all tests to run.
Comment 2 Marius Volkhart 2021-03-13 15:45:57 UTC
Additional user reports in https://issues.apache.org/jira/browse/BATIK-1299
Comment 3 Marius Volkhart 2021-03-14 18:52:19 UTC
Fixed in r1887642
Comment 4 Mark Woon 2021-04-27 00:04:53 UTC
Any chance of a release to get this out sooner rather than later?  This has become a showstopper in one of my projects.
Comment 5 Andreas Beeker 2021-04-27 05:44:31 UTC
If you're using JPMS, you might want to have a look into [1] and fixBatik.
Regarding the release, I'm ok with releasing it soon - have you test drived the nightly?


[1] https://svn.apache.org/viewvc/poi/trunk/poi-ooxml/build.gradle?view=markup