From 393932981c0a57d260e6d3e28afbe392dff5c2dd Mon Sep 17 00:00:00 2001 From: nico <109071306+NicoYuan1986@users.noreply.github.com> Date: Thu, 20 Jul 2023 11:50:59 +0800 Subject: [PATCH] Update pymilvus version (#25687) Signed-off-by: nico --- tests/python_client/common/common_func.py | 1 + tests/python_client/requirements.txt | 2 +- tests/python_client/testcases/test_collection.py | 2 +- tests/python_client/testcases/test_search.py | 12 ++++++++---- tests/python_client/testcases/test_utility.py | 2 +- 5 files changed, 12 insertions(+), 7 deletions(-) diff --git a/tests/python_client/common/common_func.py b/tests/python_client/common/common_func.py index 567ed0c4d8..dcb1aea002 100644 --- a/tests/python_client/common/common_func.py +++ b/tests/python_client/common/common_func.py @@ -1101,6 +1101,7 @@ def install_milvus_operator_specific_config(namespace, milvus_mode, release_name def get_wildcard_output_field_names(collection_w, output_fields): all_fields = [field.name for field in collection_w.schema.fields] + output_fields = output_fields.copy() if "*" in output_fields: output_fields.remove("*") output_fields.extend(all_fields) diff --git a/tests/python_client/requirements.txt b/tests/python_client/requirements.txt index 6dcecf4021..b437198d67 100644 --- a/tests/python_client/requirements.txt +++ b/tests/python_client/requirements.txt @@ -12,7 +12,7 @@ allure-pytest==2.7.0 pytest-print==0.2.1 pytest-level==0.1.1 pytest-xdist==2.5.0 -pymilvus==2.4.0.dev100 +pymilvus==2.4.0.dev101 pytest-rerunfailures==9.1.1 git+https://github.com/Projectplace/pytest-tags ndg-httpsclient diff --git a/tests/python_client/testcases/test_collection.py b/tests/python_client/testcases/test_collection.py index 43f85769b2..b973466630 100644 --- a/tests/python_client/testcases/test_collection.py +++ b/tests/python_client/testcases/test_collection.py @@ -1207,7 +1207,7 @@ class TestCollectionDataframe(TestcaseBase): """ self._connect() c_name = cf.gen_unique_str(prefix) - error = {ct.err_code: 0, ct.err_msg: "Dataframe can not be None."} + error = {ct.err_code: 1, ct.err_msg: "Dataframe can not be None."} self.collection_wrap.construct_from_dataframe(c_name, None, check_task=CheckTasks.err_res, check_items=error) @pytest.mark.tags(CaseLabel.L2) diff --git a/tests/python_client/testcases/test_search.py b/tests/python_client/testcases/test_search.py index 860a1a4b02..f3d7a040b3 100644 --- a/tests/python_client/testcases/test_search.py +++ b/tests/python_client/testcases/test_search.py @@ -3263,6 +3263,12 @@ class TestCollectionSearch(TestcaseBase): 4. check the result vectors should be equal to the inserted expected: search success """ + if index in ["IVF_SQ8", "IVF_PQ"]: + pytest.skip("IVF_SQ8 and IVF_PQ do not support output vector now") + if index == "DISKANN" and metrics == "IP": + pytest.skip("DISKANN(IP) does not support output vector now") + if metrics == "COSINE": + pytest.skip("COSINE does not support output vector now") # 1. create a collection and insert data collection_w, _vectors = self.init_collection_general(prefix, True, is_index=False)[:2] @@ -3428,7 +3434,7 @@ class TestCollectionSearch(TestcaseBase): @pytest.mark.tags(CaseLabel.L2) @pytest.mark.parametrize("wildcard_output_fields", [["*"], ["*", default_int64_field_name], ["*", default_search_field]]) - def test_search_with_output_field_wildcard(self, wildcard_output_fields, auto_id, _async, enable_dynamic_field): + def test_search_with_output_field_wildcard(self, wildcard_output_fields, auto_id, _async): """ target: test search with output fields using wildcard method: search with one output_field (wildcard) @@ -3436,9 +3442,7 @@ class TestCollectionSearch(TestcaseBase): """ # 1. initialize with data collection_w, _, _, insert_ids = self.init_collection_general(prefix, True, - auto_id=auto_id, - enable_dynamic_field= - enable_dynamic_field)[0:4] + auto_id=auto_id)[0:4] # 2. search log.info("test_search_with_output_field_wildcard: Searching collection %s" % collection_w.name) output_fields = cf.get_wildcard_output_field_names(collection_w, wildcard_output_fields) diff --git a/tests/python_client/testcases/test_utility.py b/tests/python_client/testcases/test_utility.py index 354be8d3be..0b2c3fc992 100644 --- a/tests/python_client/testcases/test_utility.py +++ b/tests/python_client/testcases/test_utility.py @@ -299,7 +299,7 @@ class TestUtilityParams(TestcaseBase): self.utility_wrap.wait_for_loading_complete( collection_w.name, partition_names=[ct.default_tag], check_task=CheckTasks.err_res, - check_items={ct.err_code: 1, ct.err_msg: f'partitionID of partitionName:{ct.default_tag} can not be find'}) + check_items={ct.err_code: 15, ct.err_msg: f'partitionID of partitionName:{ct.default_tag} can not be find'}) @pytest.mark.tags(CaseLabel.L2) def test_drop_collection_not_existed(self):