GeezerVison is showing github.com — fix: Support pgvector under non-default schema by Anarion-zuo · Pull Request #5970 · feast-dev/feast
Conversation
Anarion-zuo
commented
Feb 14, 2026
•
edited by devin-ai-integration
Bot
Loading
Uh oh!
There was an error while loading. Please reload this page.
What this PR does / why we need it:
Vector extension for postgres is almost always installed under the public schema by default. When the table's schema is not public, add public to search_path.
Which issue(s) this PR fixes:
Fixes #5814.
Misc
Steps to reproduce the issue with the pgvector example under examples/online_store/pgvector_tutorial. This PR resolve the following error.
- Change db_schema in
feature_store.yaml to a value other than 'public'.
- Execute
feast apply.
- Execute
python3 pgvector_example.py, and get the following error.
Performing similarity search for: 'wireless audio device with good sound'
Traceback (most recent call last):
File "/Users/bytedance/Projects/feast/examples/online_store/pgvector_tutorial/pgvector_example.py", line 207, in <module>
main()
File "/Users/bytedance/Projects/feast/examples/online_store/pgvector_tutorial/pgvector_example.py", line 200, in main
perform_similarity_search(store, "wireless audio device with good sound", top_k=3)
File "/Users/bytedance/Projects/feast/examples/online_store/pgvector_tutorial/pgvector_example.py", line 136, in perform_similarity_search
results = store.retrieve_online_documents(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/bytedance/Projects/feast/sdk/python/feast/feature_store.py", line 2554, in retrieve_online_documents
document_features = self._retrieve_from_online_store(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/bytedance/Projects/feast/sdk/python/feast/feature_store.py", line 2785, in _retrieve_from_online_store
documents = provider.retrieve_online_documents(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/bytedance/Projects/feast/sdk/python/feast/infra/passthrough_provider.py", line 306, in retrieve_online_documents
result = self.online_store.retrieve_online_documents(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/bytedance/Projects/feast/sdk/python/feast/infra/online_stores/postgres_online_store/postgres.py", line 439, in retrieve_online_documents
cur.execute(
File "/Users/bytedance/Projects/feast/.venv/lib/python3.11/site-packages/psycopg/cursor.py", line 97, in execute
raise ex.with_traceback(None)
psycopg.errors.UndefinedObject: type "vector" does not exist
LINE 7: vector_value <-> $1::vector as dista...
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Reviewers
shuchu
shuchu approved these changes
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|