mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-12-03 09:53:45 +00:00
fix(unittest): add pymilvus and milvus-lite to unit dep group
This commit resolves unittest-3.12 issues. - It adds pymilvus and milvus-lite to unit dep group - It rename VectorDB to VectorStore Signed-off-by: Mustafa Elbehery <melbeher@redhat.com>
This commit is contained in:
parent
3e8291c1b9
commit
c6bf292f07
4 changed files with 17 additions and 4 deletions
|
|
@ -123,6 +123,8 @@ unit = [
|
||||||
"together",
|
"together",
|
||||||
"coverage",
|
"coverage",
|
||||||
"moto[s3]>=5.1.10",
|
"moto[s3]>=5.1.10",
|
||||||
|
"pymilvus>=2.6.1",
|
||||||
|
"milvus-lite>=2.5.0",
|
||||||
]
|
]
|
||||||
# These are the core dependencies required for running integration tests. They are shared across all
|
# These are the core dependencies required for running integration tests. They are shared across all
|
||||||
# providers. If a provider requires additional dependencies, please add them to your environment
|
# providers. If a provider requires additional dependencies, please add them to your environment
|
||||||
|
|
|
||||||
8
tests/conftest.py
Normal file
8
tests/conftest.py
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
# Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||||
|
# All rights reserved.
|
||||||
|
#
|
||||||
|
# This source code is licensed under the terms described in the LICENSE file in
|
||||||
|
# the root directory of this source tree.
|
||||||
|
|
||||||
|
# This file intentionally left empty - pytest will auto-discover conftest.py files
|
||||||
|
# in subdirectories and load their fixtures automatically.
|
||||||
|
|
@ -11,7 +11,6 @@ import numpy as np
|
||||||
import pytest
|
import pytest
|
||||||
from pymilvus import AsyncMilvusClient, connections
|
from pymilvus import AsyncMilvusClient, connections
|
||||||
|
|
||||||
from llama_stack.apis.vector_dbs import VectorDB
|
|
||||||
from llama_stack.apis.vector_io import Chunk, ChunkMetadata, QueryChunksResponse
|
from llama_stack.apis.vector_io import Chunk, ChunkMetadata, QueryChunksResponse
|
||||||
from llama_stack.apis.vector_stores import VectorStore
|
from llama_stack.apis.vector_stores import VectorStore
|
||||||
from llama_stack.core.storage.datatypes import KVStoreReference, SqliteKVStoreConfig
|
from llama_stack.core.storage.datatypes import KVStoreReference, SqliteKVStoreConfig
|
||||||
|
|
@ -205,8 +204,8 @@ async def milvus_vec_adapter(milvus_vec_db_path, mock_inference_api):
|
||||||
files_api=None,
|
files_api=None,
|
||||||
)
|
)
|
||||||
await adapter.initialize()
|
await adapter.initialize()
|
||||||
await adapter.register_vector_db(
|
await adapter.register_vector_store(
|
||||||
VectorDB(
|
VectorStore(
|
||||||
identifier=adapter.metadata_collection_name,
|
identifier=adapter.metadata_collection_name,
|
||||||
provider_id="test_provider",
|
provider_id="test_provider",
|
||||||
embedding_model="test_model",
|
embedding_model="test_model",
|
||||||
|
|
|
||||||
6
uv.lock
generated
6
uv.lock
generated
|
|
@ -1,5 +1,5 @@
|
||||||
version = 1
|
version = 1
|
||||||
revision = 2
|
revision = 3
|
||||||
requires-python = ">=3.12"
|
requires-python = ">=3.12"
|
||||||
resolution-markers = [
|
resolution-markers = [
|
||||||
"(python_full_version >= '3.13' and platform_machine != 'aarch64' and sys_platform == 'linux') or (python_full_version >= '3.13' and sys_platform != 'darwin' and sys_platform != 'linux')",
|
"(python_full_version >= '3.13' and platform_machine != 'aarch64' and sys_platform == 'linux') or (python_full_version >= '3.13' and sys_platform != 'darwin' and sys_platform != 'linux')",
|
||||||
|
|
@ -2074,9 +2074,11 @@ unit = [
|
||||||
{ name = "faiss-cpu" },
|
{ name = "faiss-cpu" },
|
||||||
{ name = "litellm" },
|
{ name = "litellm" },
|
||||||
{ name = "mcp" },
|
{ name = "mcp" },
|
||||||
|
{ name = "milvus-lite" },
|
||||||
{ name = "moto", extra = ["s3"] },
|
{ name = "moto", extra = ["s3"] },
|
||||||
{ name = "ollama" },
|
{ name = "ollama" },
|
||||||
{ name = "psycopg2-binary" },
|
{ name = "psycopg2-binary" },
|
||||||
|
{ name = "pymilvus" },
|
||||||
{ name = "pypdf" },
|
{ name = "pypdf" },
|
||||||
{ name = "sqlalchemy", extra = ["asyncio"] },
|
{ name = "sqlalchemy", extra = ["asyncio"] },
|
||||||
{ name = "sqlite-vec" },
|
{ name = "sqlite-vec" },
|
||||||
|
|
@ -2216,9 +2218,11 @@ unit = [
|
||||||
{ name = "faiss-cpu" },
|
{ name = "faiss-cpu" },
|
||||||
{ name = "litellm" },
|
{ name = "litellm" },
|
||||||
{ name = "mcp" },
|
{ name = "mcp" },
|
||||||
|
{ name = "milvus-lite", specifier = ">=2.5.0" },
|
||||||
{ name = "moto", extras = ["s3"], specifier = ">=5.1.10" },
|
{ name = "moto", extras = ["s3"], specifier = ">=5.1.10" },
|
||||||
{ name = "ollama" },
|
{ name = "ollama" },
|
||||||
{ name = "psycopg2-binary", specifier = ">=2.9.0" },
|
{ name = "psycopg2-binary", specifier = ">=2.9.0" },
|
||||||
|
{ name = "pymilvus", specifier = ">=2.6.1" },
|
||||||
{ name = "pypdf", specifier = ">=6.1.3" },
|
{ name = "pypdf", specifier = ">=6.1.3" },
|
||||||
{ name = "sqlalchemy" },
|
{ name = "sqlalchemy" },
|
||||||
{ name = "sqlalchemy", extras = ["asyncio"], specifier = ">=2.0.41" },
|
{ name = "sqlalchemy", extras = ["asyncio"], specifier = ">=2.0.41" },
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue