-
Notifications
You must be signed in to change notification settings - Fork 3k
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
enhance: no need database check in restful sdk #38078
Conversation
@smellthemoon Please associate the related issue to the body of your Pull Request. (eg. “issue: #”) |
@smellthemoon E2e jenkins job failed, comment |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #38078 +/- ##
==========================================
- Coverage 81.06% 81.06% -0.01%
==========================================
Files 1369 1369
Lines 190978 190957 -21
==========================================
- Hits 154819 154801 -18
- Misses 30659 30667 +8
+ Partials 5500 5489 -11
|
/run-cpu-e2e |
@smellthemoon E2e jenkins job failed, comment |
pytest : test] [gw5] [ 37%] FAILED testcases/test_vector_operations.py::TestInsertVectorNegative::test_insert_vector_with_invalid_database_name [pytest : test] [pytest : test] =================================== FAILURES =================================== [pytest : test] ____ TestInsertVectorNegative.test_insert_vector_with_invalid_database_name ____ [pytest : test] [gw5] linux -- Python 3.10.12 /usr/local/bin/python3 [pytest : test] [gw5] linux -- Python 3.10.12 /usr/local/bin/python3[gw5] linux -- Python 3.10.12 /usr/local/bin/python3 [pytest : test] [pytest : test] self = <test_vector_operations.TestInsertVectorNegative object at 0x7f3f03cd50c0> [pytest : test] [pytest : test] def test_insert_vector_with_invalid_database_name(self): [pytest : test] """ [pytest : test] Insert a vector with an invalid database name [pytest : test] """ [pytest : test] # create a collection [pytest : test] name = gen_collection_name() [pytest : test] dim = 128 [pytest : test] payload = { [pytest : test] "collectionName": name, [pytest : test] "dimension": dim, [pytest : test] } [pytest : test] rsp = self.collection_client.collection_create(payload) [pytest : test] assert rsp['code'] == 0 [pytest : test] rsp = self.collection_client.collection_describe(name) [pytest : test] assert rsp['code'] == 0 [pytest : test] # insert data [pytest : test] nb = 10 [pytest : test] data = get_data_by_payload(payload, nb) [pytest : test] payload = { [pytest : test] "collectionName": name, [pytest : test] "data": data, [pytest : test] } [pytest : test] body_size = sys.getsizeof(json.dumps(payload)) [pytest : test] logger.info(f"body size: {body_size / 1024 / 1024} MB") [pytest : test] success = False [pytest : test] rsp = self.vector_client.vector_insert(payload, db_name="invalid_database") [pytest : test] > assert rsp['code'] == 800 [pytest : test] E assert 100 == 800 [pytest : test] [pytest : test] testcases/test_vector_operations.py:829: AssertionError |
d302ec1
to
d25ac56
Compare
@smellthemoon E2e jenkins job failed, comment |
@smellthemoon go-sdk check failed, comment |
d25ac56
to
5ae8df1
Compare
@smellthemoon go-sdk check failed, comment |
@smellthemoon E2e jenkins job failed, comment |
because in rootcoord, first see whether the collection exist and then see the db exist, has already change it logic in rootcoord. |
@czs007 But I am not sure whether I should change the code or the test case here, because the errors reported here are actually correct. The root cause is that, under a non-existent db, restful would report an error of db not exist, but pymilvus would report an error of collection not found. Any comment about this? |
5ae8df1
to
6ea8a96
Compare
@smellthemoon Thanks for your contribution. Please submit with DCO, see the contributing guide https://github.com/milvus-io/milvus/blob/master/CONTRIBUTING.md#developer-certificate-of-origin-dco. |
@smellthemoon go-sdk check failed, comment |
@smellthemoon E2e jenkins job failed, comment |
/run-cpu-e2e |
rerun go-sdk |
6ea8a96
to
620d2de
Compare
@smellthemoon go-sdk check failed, comment |
@smellthemoon E2e jenkins job failed, comment |
620d2de
to
82ad9ce
Compare
@smellthemoon E2e jenkins job failed, comment |
@smellthemoon go-sdk check failed, comment |
Signed-off-by: lixinguo <[email protected]>
82ad9ce
to
a171b7d
Compare
@smellthemoon E2e jenkins job failed, comment |
/run-cpu-e2e |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: czs007, smellthemoon The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
pr: #38078 pr: #38140 issue: #38077 --------- Signed-off-by: lixinguo <[email protected]> Co-authored-by: lixinguo <[email protected]>
#38077
remove the check for two reason