ISWC-Reproducibility-Track / Paper_606

0 stars 0 forks source link

Java null pointer exception and java.lang.StringIndexOutOfBoundsException #9

Closed MvanErp closed 4 years ago

MvanErp commented 4 years ago

When running java -jar Crime_Ingestion_App-1.0.0.jar

I get the following errors:

18:02:02.022 INFO Adding annotator ita_toksent 18:02:02.022 INFO Adding annotator pos 18:02:02.022 INFO Adding annotator ita_morpho 18:02:02.022 INFO Adding annotator ita_lemma 18:02:02.022 INFO Adding annotator ner 18:02:02.022 INFO Adding annotator depparse 18:02:02.022 INFO Adding annotator fake_dep java.lang.NullPointerException

and a bit further on (for I think a different file):

Inserito: https://gazzettadimodena.gelocal.it/modena/cronaca/2019/10/29/news/balsamico-il-passaporto-digitale-per-l-autenticita-di-tutta-la-filiera-1.37806608 2019-10-30 01:00:00 Balsamico, il passaporto digitale per l’autenticità di tutta la filiera . Sulle confezioni ci sarà un contrassegno sofisticato con le certificazioni Csqa anti-contraffazioni [...] 18:02:12.087 INFO Adding annotator ita_toksent 18:02:12.087 INFO Adding annotator pos 18:02:12.087 INFO Adding annotator ita_morpho 18:02:12.087 INFO Adding annotator ita_lemma 18:02:12.087 INFO Adding annotator ner 18:02:12.087 INFO Adding annotator depparse 18:02:12.087 INFO Adding annotator fake_dep Exception in thread "main" java.lang.StringIndexOutOfBoundsException: begin 0, end -2, length 4 at java.base/java.lang.String.checkBoundsBeginEnd(String.java:3319) at java.base/java.lang.String.substring(String.java:1874) at eu.fbk.dh.tint.digimorph.annotator.GuessModel.guess(GuessModel.java:321) at eu.fbk.dh.tint.digimorph.annotator.DigiLemmaAnnotator.annotate(DigiLemmaAnnotator.java:212) at edu.stanford.nlp.pipeline.AnnotationPipeline.annotate(AnnotationPipeline.java:76) at edu.stanford.nlp.pipeline.StanfordCoreNLP.annotate(StanfordCoreNLP.java:599) at eu.fbk.dh.tint.runner.TintPipeline.runRaw(TintPipeline.java:119) at eu.fbk.dh.tint.runner.TintPipeline.runRaw(TintPipeline.java:103) at NewsArticles.addNewsGM(NewsArticles.java:685) at Main.main(Main.java:63)

Could you let me know how to resolve these?

federicarollo commented 4 years ago

I have modified the source code to fix this problem.