lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Elschot <>
Subject Re: [jira] Commented: (LUCENE-413) [PATCH] BooleanScorer2 ArrayIndexOutOfBoundsException + alternative NearSpans
Date Mon, 03 Apr 2006 21:24:16 GMT
On Monday 03 April 2006 21:15, Yonik Seeley (JIRA) wrote:
[ ] 
> Yonik Seeley commented on LUCENE-413:
> -------------------------------------
> Excellent news!

Yes, after all those months :)

> I'll do a quick review of the changes to SpanScorer, clean up the tests, and 
commit (just so no one is duplicating the effort). doesn't react here, so I'm posting on java-dev.

Some remaining things:

Dallan, could you test without the patch to DisjunctionScorer, but with the
posted SpanScorer?
Also, a simple test case for this bug would be more than welcome, but this
may be difficult to provide.

Yonik, the boolean someSpanInDoc in the new setFreqCurrentDoc() method
is superfluous, it will always be true at the end of the method.
It's better to replace the last line of this method with the original:
    return more || (freq != 0);
I'd prefer to return true at the end of this method, because testing the freq 
value allows the Similarity of the query to influence the result of next()
and skipTo(), and I think a Similarity should only influence the score() 
But backward compatibility may be more important, and it also allows
to have a non match when the resulting span is shorter than the slop
allowed by a NearSpans.

TestSpansAdvanced2 inherits from TestSpansAdvanced and iirc this causes
some test methods in TestSpansAdvanced to be repeated at the 
TestSpansAdvanced2 test. Correcting this will need some refactoring.
The problem is that I don't know what these two classes are supposed
to test. Anyway, the warnings for the unexpected score values might be used to 
fill in the new expected values.

Paul Elschot

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message