MCPcopy Create free account
hub / github.com/cosdata/cosdata / delete_collection

Function delete_collection

tests/test-key-value-store.py:88–92  ·  view source on GitHub ↗
(name)

Source from the content-addressed store, hash-verified

86 return bytes(response.json()["bytes"]).decode("utf-8")
87
88def delete_collection(name):
89 url = f"{client.base_url}/collections/{name}"
90 response = requests.delete(url, headers=client._get_headers(), verify=client.verify_ssl)
91 if response.status_code not in [200, 204, 404]:
92 raise Exception(f"Failed to delete collection: {response.text}")
93
94# ============== TEST UTILITIES ==============
95

Callers 1

mainFunction · 0.70

Calls 2

deleteMethod · 0.45
_get_headersMethod · 0.45

Tested by

no test coverage detected