@@ -2822,7 +2822,7 @@ def test_search_expr_json_field(self):
2822
2822
for hits in search_res :
2823
2823
ids = hits .ids
2824
2824
assert set (ids ).issubset (filter_ids_set )
2825
- # 6. search again with expression template and hint
2825
+ # 6. search again with expression template and hint
2826
2826
search_params = default_search_params .copy ()
2827
2827
search_params .update ({"hints" : "iterative_filter" })
2828
2828
search_res , _ = collection_w .search (search_vectors [:default_nq ], default_search_field ,
@@ -2840,10 +2840,10 @@ def test_search_expr_json_field(self):
2840
2840
log .info (filter_ids_set )
2841
2841
assert set (ids ).issubset (filter_ids_set )
2842
2842
# 7. create json index
2843
- default_json_path_index = {"index_type" : "INVERTED" , "params" : {"json_cast_type" : DataType . DOUBLE ,
2843
+ default_json_path_index = {"index_type" : "INVERTED" , "params" : {"json_cast_type" : "double" ,
2844
2844
"json_path" : f"{ ct .default_json_field_name } ['number']" }}
2845
2845
collection_w .create_index (ct .default_json_field_name , default_json_path_index , index_name = f"{ ct .default_json_field_name } _0" )
2846
- default_json_path_index = {"index_type" : "INVERTED" , "params" : {"json_cast_type" : DataType . DOUBLE ,
2846
+ default_json_path_index = {"index_type" : "INVERTED" , "params" : {"json_cast_type" : "double" ,
2847
2847
"json_path" : f"{ ct .default_json_field_name } ['float']" }}
2848
2848
collection_w .create_index (ct .default_json_field_name , default_json_path_index , index_name = f"{ ct .default_json_field_name } _1" )
2849
2849
# 8. release and load to make sure the new index is loaded
0 commit comments