lucenenet-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Erich Eichinger (JIRA)" <>
Subject [jira] Commented: (LUCENENET-102) GermanStemmer.cs has numerous string substring errors
Date Mon, 08 Oct 2007 16:46:50 GMT


Erich Eichinger commented on LUCENENET-102:

just wanted to mention, that the German Stemmer for Lucene 1.4 suffered from converting the
string.substring() method from Java to NET. In java you specify 

    string.substring( firstIndex, lastIndex) 

whereas in NET you specify 

   string.Substring( firstIndex, length )

I guess that's the case for the Snowball GermanStemmer as well

> GermanStemmer.cs has numerous string substring errors
> -----------------------------------------------------
>                 Key: LUCENENET-102
>                 URL:
>             Project: Lucene.Net
>          Issue Type: Bug
>         Environment: Lucene.Net 2.0 using the GermanStemmer
>            Reporter: Stefan Rusek
>         Attachments: GermanStemmer.cs.diff
> When using the german stemmer that is included in the 2.0 release. The stemmer will throw
ArgumentOutOfRangeException. We have fixed the issue in-house but wanted to get the fix incorporated
into the actual Lucene.Net release so that future users don't have this problem. Below is
an example stacktrace, and I will attach a diff as well.
> System.ArgumentOutOfRangeException: Index and length must refer to a location within
the string.
> Parameter name: length
>   at System.String.InternalSubStringWithChecks(Int32 startIndex, Int32 length, Boolean
>   at Lucene.Net.Analysis.DE.GermanStemmer.Strip(StringBuilder buffer) in c:\src-hosted\fogcreek\FogBugz\FogUtil.Search\FogUtil.Search\Lucene.Net\Analysis\DE\GermanStemmer.cs:line
>   at Lucene.Net.Analysis.DE.GermanStemmer.Stem(String term) in c:\src-hosted\fogcreek\FogBugz\FogUtil.Search\FogUtil.Search\Lucene.Net\Analysis\DE\GermanStemmer.cs:line
>   at Lucene.Net.Analysis.DE.GermanStemFilter.Next() in c:\src-hosted\fogcreek\FogBugz\FogUtil.Search\FogUtil.Search\Lucene.Net\Analysis\DE\GermanStemFilter.cs:line
>   at Lucene.Net.Index.DocumentWriter.InvertDocument(Document doc) in c:\src-hosted\fogcreek\FogBugz\FogUtil.Search\FogUtil.Search\Lucene.Net\Index\DocumentWriter.cs:line
>   at Lucene.Net.Index.DocumentWriter.AddDocument(String segment, Document doc) in c:\src-hosted\fogcreek\FogBugz\FogUtil.Search\FogUtil.Search\Lucene.Net\Index\DocumentWriter.cs:line
>   at Lucene.Net.Index.IndexWriter.AddDocument(Document doc, Analyzer analyzer) in c:\src-hosted\fogcreek\FogBugz\FogUtil.Search\FogUtil.Search\Lucene.Net\Index\IndexWriter.cs:line
>   at Lucene.Net.Index.IndexWriter.AddDocument(Document doc) in c:\src-hosted\fogcreek\FogBugz\FogUtil.Search\FogUtil.Search\Lucene.Net\Index\IndexWriter.cs:line

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message