Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix query params issue dependent on bug in httpx<0.28 #1482

Merged
merged 5 commits into from
Dec 13, 2024
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions integration/test_tenants.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,22 @@
from weaviate.exceptions import WeaviateInvalidInputError, WeaviateUnsupportedFeatureError


def test_shards_on_tenants(
client_factory: ClientFactory, collection_factory: CollectionFactory
) -> None:
collection = collection_factory(
vectorizer_config=Configure.Vectorizer.none(),
multi_tenancy_config=Configure.multi_tenancy(enabled=True),
)
collection.tenants.create(Tenant(name="tenant1"))
client = client_factory()

nodes = client.cluster.nodes(collection.name, output="verbose")
count = sum(len(node.shards) for node in nodes)

assert count == 1


@pytest.mark.parametrize("tenant", ["tenant1", Tenant(name="tenant1")])
def test_delete_by_id_tenant(
collection_factory: CollectionFactory, tenant: Union[str, Tenant]
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ packages =
platforms = any
include_package_data = True
install_requires =
httpx>=0.26.0,<0.29.0
httpx>=0.26.0,<0.28.0
validators==0.34.0
authlib>=1.2.1,<1.3.2
pydantic>=2.8.0,<3.0.0
Expand Down
2 changes: 1 addition & 1 deletion weaviate/connect/v4.py
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ async def get(
return await self.__send(
"GET",
url=self.url + self._api_version_path + path,
params=params if params is not None else {},
params=params,
rlmanrique marked this conversation as resolved.
Show resolved Hide resolved
error_msg=error_msg,
status_codes=status_codes,
)
Expand Down
Loading