You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by GitBox <gi...@apache.org> on 2020/06/04 23:21:54 UTC

[GitHub] [lucene-solr] tflobbe commented on a change in pull request #1553: LUCENE-9393: FunctionScoreQuery turns TOP_DOCS to COMPLETE in inner weights

tflobbe commented on a change in pull request #1553:
URL: https://github.com/apache/lucene-solr/pull/1553#discussion_r435604487



##########
File path: lucene/queries/src/test/org/apache/lucene/queries/function/TestFunctionScoreQuery.java
##########
@@ -244,4 +247,33 @@ public void testAccessToValueSource() throws Exception {
 
   }
 
+  public void testScoreMode() throws Exception {
+    // Value Source doesn't need scores
+    assertInnerScoreMode(ScoreMode.COMPLETE_NO_SCORES, ScoreMode.COMPLETE, DoubleValuesSource.fromDoubleField("foo"));

Review comment:
       While this test makes the current code pass, I'm trying to understand why it is correct. Why do we pass a COMPLETE_NO_SCORES to the underlying weight when the function's ValueSource doesn't need scores?




----------------------------------------------------------------
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.

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



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