vigyasharma opened a new issue, #12097:
URL: https://github.com/apache/lucene/issues/12097

   ### Description
   
   Found this test failing in Lucene-Check-9.x - Build # 4239. 
   
   **Steps to repro:**
   ```ruby
   gradlew test --tests 
TestIndexSortSortedNumericDocValuesRangeQuery.testCountBoundary 
-Dtests.seed=A11A06AE642497F1 -Dtests.multiplier=2 -Dtests.locale=en-KE 
-Dtests.timezone=Singapore -Dtests.asserts=true -Dtests.file.encoding=UTF-8
   ```
   
   I've been able to repro this failure in both `branch_9x` as well as `main`. 
This is what I found with a debugger - 
   
   It seems that in this test seed, the missing document [(created 
here)](https://github.com/apache/lucene/blob/main/lucene/core/src/test/org/apache/lucene/search/TestIndexSortSortedNumericDocValuesRangeQuery.java#L589),
 goes into a separate leaf. Then for that leaf context, [the 
IteratorAndCount](https://github.com/apache/lucene/blob/main/lucene/core/src/java/org/apache/lucene/search/IndexSortSortedNumericDocValuesRangeQuery.java#L200)
 has `count = -1`, taking the flow to the fallback query. 
   And since the document does not have a points value, the fallback query gets 
`PointValues == null`, leading it to return a 0 
[here](https://github.com/apache/lucene/blob/main/lucene/core/src/java/org/apache/lucene/search/PointRangeQuery.java#L381).
   
   I'm not very familiar with this part of Lucene, but I guess it is likely for 
the missing document to land in a leaf of its own. Would it help if the missing 
doc had a points value but for a different field?
   
   ### Gradle command to reproduce
   
   ```ruby
   gradlew test --tests 
TestIndexSortSortedNumericDocValuesRangeQuery.testCountBoundary 
-Dtests.seed=A11A06AE642497F1 -Dtests.multiplier=2 -Dtests.locale=en-KE 
-Dtests.timezone=Singapore -Dtests.asserts=true -Dtests.file.encoding=UTF-8
   ```


-- 
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: issues-unsubscr...@lucene.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to