⏏️Disconnecting from the Service
Example
import pyenvector as ev
# 1. Initialize the connection
ev.init_connect(address="localhost:50050", access_token=None)
# 2. Check that the connection is active
if ev.is_connected():
print(f"Connection active: {ev.is_connected()} ✅")
else:
print("Failed to connect.")
# 3. Disconnect from the service
print("Disconnecting from the service...")
ev.disconnect()
# 4. Check the connection status again
if not ev.is_connected():
print(f"Connection active: {ev.is_connected()} ❌")
else:
print("Still connected.")Last updated

