-
Notifications
You must be signed in to change notification settings - Fork 20
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
Error on detecting pdf #14
Comments
Update: With 2.7.0 it works. |
This genuinely looks like a Tika API change. I Don't know what Pantomime can do about it. |
Right, so since this just happened to me and this issue pops up very high on Google for the exception, I thought to trace this and publish an answer here for others that might experience the same thing. Digging around a bit more, I found issue TIKA-1717 and from there it became clear that somehow my project was using an older version of commons-compress. I then used In my case the exclusions were: {:dependencies ;; ...
[org.webjars/webjars-locator-jboss-vfs "0.1.0"
:exclusions [org.apache.commons/commons-compress]]
[me.raynes/fs "1.4.6"
:exclusions [org.clojure/clojure
org.apache.commons/commons-compress]]
;; ...
} The webjars-locator is part of the default luminus template, so this might very easily happen to someone in the future. Pantomime will at least bring in commons-compress 1.12, the bug I mentioned in Tika was resolved in commons-compress 1.11. So those are some versions to work around. |
@kennethkalmer thank you! is there anything Pantomime can do to avoid this? or is it really an outdated [transient] dependency on |
Outdated transient dependency 😢 There are probably a few things:
The sad truth is that many version of Maybe the first and second points should both be done. The first one shares knowledge with users that is more broadly applicable to other edge cases too, not just with Pantomime. The second point just adds some clarity to that moment of insane confusion... Especially seeing a Zip error when trying to parse a PDF file Wdyt? |
Oh snap, just realized the same was discussed in #15 |
I will add a modern |
Upgrading Pantomime from 2.3.0 to 2.8.0 i found the sequent Exception thrown while :
java.lang.NoClassDefFoundError: org/apache/commons/compress/PasswordRequiredException
at org.apache.tika.parser.pkg.ZipContainerDetector.detect(ZipContainerDetector.java:88)
at org.apache.tika.detect.CompositeDetector.detect(CompositeDetector.java:77)
at org.apache.tika.Tika.detect(Tika.java:156)
at org.apache.tika.Tika.detect(Tika.java:287)
at pantomime.mime$eval20617$fn__20618.invoke(mime.clj:38)
at pantomime.mime$eval20596$fn__20597$G__20587__20602.invoke(mime.clj:24)
I struggled a while and the problem occurred while i was performing the following code:
Reverting Pantomime from 2.8 to 2.3 fixes the problem.
The text was updated successfully, but these errors were encountered: