tabulapdf icon indicating copy to clipboard operation
tabulapdf copied to clipboard

Error - Error in .jcall("RJavaTools", "Ljava/lang/Object;", "invokeMethod", cl, : java.lang.IllegalArgumentException: Comparison method violates its general contract!

Open Mayalandy opened this issue 7 years ago • 3 comments

Hi,

I really like this tabulizer and it's working very well. However, I recently tried to process a number of pdfs and am getting this error. Thought I'd pass it along.

Thanks ALL_2017_08_31.pdf

Mayalandy avatar Sep 04 '17 01:09 Mayalandy

Did you find a solution? I have the same error. And seems like some pages in the pdf file causing this. Do you know which pages in the example you give having the error?

wenzhenghe7 avatar May 01 '18 22:05 wenzhenghe7

I have the same problem with this file: 452216668-Datos-18-03-20.pdf

Interestingly, the other files from the same website give no issues.

gorkang avatar Mar 19 '20 19:03 gorkang

NEW FILE (errors): 453061401-Datos-23-03-20.pdf

OLD FILE (works): 451150373-Datos-10-03-20.pdf

The issue only appears in the NEW FILE when using lattice:

source_pdf = "453061401-Datos-23-03-20.pdf
extract_tables(source_pdf, method = "lattice") # error
extract_tables(source_pdf, method = "stream") # works

And it seems to be located in page 4:

source_pdf = "453061401-Datos-23-03-20.pdf
extract_tables(source_pdf, method = "lattice", pages = c(1:3)) # works
extract_tables(source_pdf, method = "lattice", pages = c(4)) # fails

Everything works fine with the OLD FILE.

gorkang avatar Mar 25 '20 11:03 gorkang