You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Found during review of #1012 (issue #888 vector stores).
Problem
CouchbaseVectorStore._search_sync called scope.search(index, request)withoutSearchOptions(fields=[...]). The Couchbase FTS Python SDK returns only id + score per SearchRow unless fields are explicitly requested; SearchRow.fields is otherwise empty. So against a real Couchbase cluster every hit came back with text="" and metadata={} — retrieval was effectively broken.
Secondary: the row-field extraction assumed row.fields might be callable, but in couchbase 4.x SearchRow.fields is a dict attribute, so the code path .get() on the SearchRow itself would raise AttributeError.
The smoke-test fake returned populated fields and ignored search options, hiding both issues (the classic "plausible-but-wrong API" trap).
Fix
Pass SearchOptions(fields=["*"], limit=limit) to scope.search(...).
Extract row.fields handling both the dict attribute (real SDK) and a callable (defensive).
Regression test reshaped to model SearchRow.fields as a dict attribute and to assert fields=["*"] is requested (fails on old code, passes on fix).
Activity
fix(retrieval): request Couchbase FTS fields so search returns text/m…
Merge #1012: add 9 vector stores (closes #888)