benwtrent commented on issue #15324:
URL: https://github.com/apache/lucene/issues/15324#issuecomment-3407780651

   Updated to 10.2 with the same segment geometry and queries, and still 
getting the EOF. When we do leaf partitions and indicate we want to search the 
entire leaf, that generally means the `max` value we initially provide to 
`MaxScoreBulkScorer` is `NO_MORE_DOCS`
   
   ```
       public static LeafReaderContextPartition 
createForEntireSegment(LeafReaderContext ctx) {
         return new LeafReaderContextPartition(
             ctx, 0, DocIdSetIterator.NO_MORE_DOCS, ctx.reader().maxDoc());
       }
   ```
   
   within `scoreInnerWindowWithFilter` it seems like:
   
   ```
       int innerWindowMax = MathUtil.unsignedMin(max, innerWindowMin + 
INNER_WINDOW_SIZE);
   ```
   
   Could end up being a value between the actual max doc in the segment and 
`NO_MORE_DOCS`, unless we force that `max` to be the the iterator max, but it 
seems the "default" behavior is for the max passed in to be `outerWindowMax` 
which could be `NO_MORE_DOCS`.
   
   
   I am still not 100% sure how this ends up causing `top.doc == top.maxDoc`, 
but we end up in that state some how...


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to