tika-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Derrick Johnson (JIRA)" <j...@apache.org>
Subject [jira] [Created] (TIKA-1163) NPE thrown by TikaConfig.getDefaultConfig()
Date Sun, 18 Aug 2013 20:18:47 GMT
Derrick Johnson created TIKA-1163:
-------------------------------------

             Summary: NPE thrown by TikaConfig.getDefaultConfig() 
                 Key: TIKA-1163
                 URL: https://issues.apache.org/jira/browse/TIKA-1163
             Project: Tika
          Issue Type: Bug
    Affects Versions: 1.4
         Environment: OS-X, JDK 1.7
            Reporter: Derrick Johnson


The below exception gets thrown every time I execute TikaConfig.getDefaultConfig. Similary,
invoking `Tika t = new Tika()` throws the same exception, since code inside this constructor
invokes TikaConfig.getDefaultConfig().

This problem is non-existent when I use Tika-core and Tika-parsers 1.0. But when bump the
version numbers to 1.2 (in order to get around a bug in PDFBOX), the problem shows up. I'm
using maven. I've carefully ensured that I'm not pulling in the wrong version of Tika, using
things like `mvn dependency:tree` and making there were no sneaky problematic transitive dependencies.




java.lang.NullPointerException
	at org.apache.tika.mime.MimeTypesReader$ClauseRecord.stop(MimeTypesReader.java:245)
	at org.apache.tika.mime.MimeTypesReader.endElement(MimeTypesReader.java:203)
	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:606)
	at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:183)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1303)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2717)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:607)
	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:489)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:835)
	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:123)
	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1210)
	at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:568)
	at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:302)
	at javax.xml.parsers.SAXParser.parse(SAXParser.java:195)
	at org.apache.tika.mime.MimeTypesReader.read(MimeTypesReader.java:115)
	at org.apache.tika.mime.MimeTypesFactory.create(MimeTypesFactory.java:64)
	at org.apache.tika.mime.MimeTypesFactory.create(MimeTypesFactory.java:93)
	at org.apache.tika.mime.MimeTypesFactory.create(MimeTypesFactory.java:149)
	at org.apache.tika.mime.MimeTypes.getDefaultMimeTypes(MimeTypes.java:479)
	at org.apache.tika.config.TikaConfig.getDefaultMimeTypes(TikaConfig.java:60)
	at org.apache.tika.config.TikaConfig.<init>(TikaConfig.java:169)
	at org.apache.tika.config.TikaConfig.getDefaultConfig(TikaConfig.java:268)
        at 
my.method.which.invokes `new Tika()`

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message