Skip to content

Commit 53370a3

Browse files
committed
fix: increase timeout when adding files to vector stores
Needed to avoid problems when using sentence-transformers Signed-off-by: Jorge Garcia Oncins <jgarciao@redhat.com>
1 parent 4d0f79f commit 53370a3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tests/llama_stack/utils.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,10 @@ def vector_store_create_and_poll(
103103
TimeoutError: If wait_timeout is reached while status is still in_progress.
104104
"""
105105
vs_file = llama_stack_client.vector_stores.files.create(
106-
vector_store_id=vector_store_id, file_id=file_id, attributes=attributes
106+
vector_store_id=vector_store_id,
107+
file_id=file_id,
108+
timeout=240, # Increased timeout for slow processing (e.g., sentence-transformers)
109+
attributes=dict(attributes) if attributes else attributes,
107110
)
108111
terminal_statuses = ("completed", "failed", "cancelled")
109112
deadline = time.monotonic() + wait_timeout

0 commit comments

Comments
 (0)