Uploaded image for project: 'Tika'
  1. Tika
  2. TIKA-2884

Tika Parse - Null Pointer

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Invalid
    • Affects Version/s: 1.21
    • Fix Version/s: 1.21
    • Component/s: ocr
    • Labels:
      None

      Description

      I am running tika 1.21 to parse the pdf documents with tesseract ocr 3.5 on Amazon linux and it intermittently fails to parse. Sometimes same file gets process succesfully. Below i the error

       

      Caused by: java.lang.NullPointerException: null
      at org.apache.tika.sax.xpath.MatchingContentHandler.startElement(MatchingContentHandler.java:46)
      at org.apache.tika.sax.ContentHandlerDecorator.startElement(ContentHandlerDecorator.java:126)
      at org.apache.tika.sax.ContentHandlerDecorator.startElement(ContentHandlerDecorator.java:126)
      at org.apache.tika.sax.SecureContentHandler.startElement(SecureContentHandler.java:250)
      at org.apache.tika.sax.ContentHandlerDecorator.startElement(ContentHandlerDecorator.java:126)
      at org.apache.tika.sax.ContentHandlerDecorator.startElement(ContentHandlerDecorator.java:126)
      at org.apache.tika.sax.ContentHandlerDecorator.startElement(ContentHandlerDecorator.java:126)
      at org.apache.tika.sax.SafeContentHandler.startElement(SafeContentHandler.java:265)
      at org.apache.tika.sax.XHTMLContentHandler.lazyStartHead(XHTMLContentHandler.java:146)
      at org.apache.tika.sax.XHTMLContentHandler.lazyEndHead(XHTMLContentHandler.java:164)
      at org.apache.tika.sax.XHTMLContentHandler.startElement(XHTMLContentHandler.java:253)
      at org.apache.tika.sax.XHTMLContentHandler.startElement(XHTMLContentHandler.java:297)
      at org.apache.tika.parser.pdf.AbstractPDF2XHTML.startPage(AbstractPDF2XHTML.java:173)
      at org.apache.tika.parser.pdf.OCR2XHTML.processPage(OCR2XHTML.java:96)
      at org.apache.tika.parser.pdf.AbstractPDF2XHTML.processPages(AbstractPDF2XHTML.java:835)
      at org.apache.pdfbox.text.PDFTextStripper.writeText(PDFTextStripper.java:266)
      at org.apache.tika.parser.pdf.OCR2XHTML.process(OCR2XHTML.java:66)
      at org.apache.tika.parser.pdf.PDFParser.parse(PDFParser.java:167)
      at org.apache.tika.parser.CompositeParser.parse(CompositeParser.java:280)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                raviopen Ravi
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: