This is an automated email from the ASF dual-hosted git repository.

hossman pushed a commit to branch jira/SOLR-17975
in repository https://gitbox.apache.org/repos/asf/solr.git

commit 4d616b46cd0d5e6ec4d6cb7af11c37ec6541180a
Author: Chris Hostetter <[email protected]>
AuthorDate: Wed Jan 7 15:29:12 2026 -0700

    Fix LateInteractionVectorField and uncomment failing test asserts that can 
now pass if SOLR-18033.patch is applied
---
 .../apache/solr/schema/LateInteractionVectorField.java   |  6 ++++++
 .../apache/solr/search/TestLateInteractionVectors.java   | 16 ++--------------
 2 files changed, 8 insertions(+), 14 deletions(-)

diff --git 
a/solr/core/src/java/org/apache/solr/schema/LateInteractionVectorField.java 
b/solr/core/src/java/org/apache/solr/schema/LateInteractionVectorField.java
index b53bc23a5ab..fba037e5b20 100644
--- a/solr/core/src/java/org/apache/solr/schema/LateInteractionVectorField.java
+++ b/solr/core/src/java/org/apache/solr/schema/LateInteractionVectorField.java
@@ -34,6 +34,7 @@ import org.apache.lucene.search.DoubleValuesSource;
 import org.apache.lucene.search.LateInteractionFloatValuesSource;
 import org.apache.lucene.search.Query;
 import org.apache.lucene.search.SortField;
+import org.apache.lucene.util.BytesRef;
 import org.apache.solr.common.SolrException;
 import org.apache.solr.response.TextResponseWriter;
 import org.apache.solr.search.QParser;
@@ -289,6 +290,11 @@ public class LateInteractionVectorField extends FieldType {
   public void write(TextResponseWriter writer, String name, IndexableField f) 
throws IOException {
     writer.writeStr(name, toExternal(f), false);
   }
+  
+  @Override
+  public Object toObject(SchemaField sf, BytesRef term) {
+    return multiFloatVectorToString(LateInteractionField.decode(term));
+  }
 
   /** Not supported */
   @Override
diff --git 
a/solr/core/src/test/org/apache/solr/search/TestLateInteractionVectors.java 
b/solr/core/src/test/org/apache/solr/search/TestLateInteractionVectors.java
index 65330f8b77b..26b18eaa964 100644
--- a/solr/core/src/test/org/apache/solr/search/TestLateInteractionVectors.java
+++ b/solr/core/src/test/org/apache/solr/search/TestLateInteractionVectors.java
@@ -196,20 +196,8 @@ public class TestLateInteractionVectors extends 
SolrTestCaseJ4 {
         "//str[@name='lv_4_cosine'][.='" + d4s + "']",
 
         // dv only non-stored fields
-        //
-        // nocommit: non-stored fields can't be retrieved correctly yet.
-        //
-        // nocommit: this is because SolrDocumentFetcher doesn't correctly 
delegate to the
-        // FieldType.toObject (consistently) for BytesRef conversion
-        // nocommit: (only special cases are delegated, for things like 
BoolField and SORTED_SET)
-        //
-        // nocommit: need to open a new issue to track this for BINARY 
docValues (BinaryField should
-        // be only existing FT affected)
-        // nocommit: (or maybe all DV BytesRef conversion? ... would require 
thorough review of more
-        // FieldTypes)
-        //
-        // "//str[@name='lv_3_nostored'][.='"+d3s+"']",
-        // "//str[@name='lv_4_nostored'][.='"+d4s+"']",
+        "//str[@name='lv_3_nostored'][.='"+d3s+"']", // nocommit: requires 
SOLR-18033.patch be applied
+        "//str[@name='lv_4_nostored'][.='"+d4s+"']", // nocommit: requires 
SOLR-18033.patch be applied
 
         // function computations
         "//float[@name='euclid_3_def'][.=" + euclid3 + "]",

Reply via email to