Build fails with fresh maven cache
aalsup opened this issue · 6 comments
Build fails with the following error:
Failed to execute goal on project baleen-collectionreaders: Could not resolve dependencies for project uk.gov.dstl.baleen:baleen-collectionreaders:jar:2.5.0-SNAPSHOT: Failure to find org.apache.pdfbox:jbig2-imageio:jar:3.0.0-SNAPSHOT in https://repository.apache.org/content/repositories/snapshots was cached in the local repository, resolution will not be reattempted until the update interval of apache-snapshots has elapsed or updates are forced
There's a transitive dependency on jbig2-imageio.jar-3.0.0-SNAPSHOT
; however, that snapshot version is not longer available in the Apache Maven Repo.
Only jbig2-imageio.jar:3.0.1-SNAPSHOT
is available. See here:
https://repository.apache.org/content/repositories/snapshots/org/apache/pdfbox/jbig2-imageio/
Steps to reproduce:
- Remove the existing
jbig2-imageio.jar-3.0.0-SNAPSHOT
artifacts from your local.m2/repository
mvn clean package
(or whatever goals you typically specify)
It looks like the dependency is dragged in as follows:
- uk.gov.dstl.baleen:baleen-collectionreaders:jar:2.5.0-SNAPSHOT
- io.committed.krill:krill:jar:1.0.2
- org.apache.tika:tika-parsers:jar:1.16
- org.apache.pdfbox:jbig2-imageio:jar:3.0.0-SNAPSHOT
A quick workaround is to edit baleen-collectionreaders/pom.xml
as follows:
- Add an explicit dependency on jbig2-imageio:3.0.1-SNAPSHOT
<dependency>
<groupId>org.apache.pdfbox</groupId>
<artifactId>jbig2-imageio</artifactId>
<version>3.0.1-SNAPSHOT</version>
</dependency>
- Modify the krill dependency to exclude jbig2-imageio
<dependency>
<groupId>io.committed.krill</groupId>
<artifactId>krill</artifactId>
<version>${krill.version}</version>
<exclusions>
<exclusion>
<groupId>org.apache.pdfbox</groupId>
<artifactId>jbig2-imageio</artifactId>
</exclusion>
</exclusions>
</dependency>
Thank you for raising this and taking the time to find a workaround for it. We will look into it as soon as possible.
The 3.0.0-SNAPSHOT has been published so you can use 3.0.0.
I've updated krill to use 3.0.0, so you can update krill to 1.0.3 to fix this problem.
Thanks Stuart. I will update the version of krill within Baleen.
Hopefully this resolves the issue. Thanks Andrew and Stuart.
👍