Issue integrating with Maven artifact

Hi all,

I tried to include language tool as a Maven artifact in my project. But when I integrated it gives me the following error with Language ‘English’ (also with Australian, American, British english). However it works without issues with ‘French’ and some other languages.

This is the error I am getting.

at org.languagetool.language.English.getSentenceTokenizer(English.java:68)
at org.languagetool.JLanguageTool.(JLanguageTool.java:198)
at org.languagetool.JLanguageTool.(JLanguageTool.java:167)
at …
at com.genix.platform3.datamining.text.preprocessing.GrammarCheckTest.main(GrammarCheckTest.java:41)
Caused by: java.lang.UnsupportedOperationException: This parser does not support specification “null” version “null”
at javax.xml.parsers.SAXParserFactory.setSchema(Unknown Source)
at net.sourceforge.segment.srx.io.Srx2SaxParser.(Srx2SaxParser.java:179)
at org.languagetool.tokenizers.SRXSentenceTokenizer.createSrxDocument(SRXSentenceTokenizer.java:60)
at org.languagetool.tokenizers.SRXSentenceTokenizer.(SRXSentenceTokenizer.java:47)

Any help with this is really appreciated.

Kind Regards,
Sam

Hi All,

I found out that it is because of the xerces dependency. Eventhough I included it as an exclude in pom.xml file, it just getting loaded every time it rebuilds.

Any suggestions on this to remove xerces dependency?

Kind Regards,
Sam

On So 10.02.2013, 18:55:36 you wrote:

I found out that it is because of the xerces dependency. Eventhough I
included it as an exclude in pom.xml file, it just getting loaded every
time it rebuilds.

Could you run “mvn dependency:tree” to see where xerces gets included?

Regards
Daniel


http://www.danielnaber.de