Skip to content
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

support json for cli #65

Merged
merged 2 commits into from
Dec 8, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions milvus_cli/Types.py
Original file line number Diff line number Diff line change
@@ -32,6 +32,7 @@ def __str__(self):
"VARCHAR",
"BINARY_VECTOR",
"FLOAT_VECTOR",
"JSON",
]

IndexTypes = [
@@ -126,6 +127,7 @@ def __str__(self):
11: "DOUBLE",
20: "STRING",
21: "VARCHAR",
23: "JSON",
100: "BINARY_VECTOR",
101: "FLOAT_VECTOR",
999: "UNKNOWN",
4 changes: 2 additions & 2 deletions milvus_cli/scripts/collection_cli.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
from tabulate import tabulate
from .helper_cli import create, getList, delete, rename, show, load, release
import click
import os
import sys
@@ -8,6 +7,7 @@
parent_dir = os.path.dirname(current_dir)
sys.path.append(parent_dir)

from .helper_cli import create, getList, delete, rename, show, load, release
from Validation import validateCollectionParameter
from Types import ParameterException

@@ -24,7 +24,7 @@
"-p", "--schema-primary-field", "primaryField", help="Primary field name."
)
@click.option(
"-a",
"-A",
"--schema-auto-id",
"autoId",
help="[Optional, Flag] - Enable auto id.",
3 changes: 1 addition & 2 deletions milvus_cli/test/test_index.py
Original file line number Diff line number Diff line change
@@ -23,7 +23,7 @@
class TestIndex(unittest.TestCase):
@classmethod
def setUpClass(cls):
milvusConnection.connect(uri=uri, alias=tempAlias)
milvusConnection.connect(uri=uri)
fields = [
"id:VARCHAR:128",
"title:VARCHAR:512",
@@ -33,7 +33,6 @@ def setUpClass(cls):
collection.create_collection(
collectionName=collectionName,
fields=fields,
alias=tempAlias,
autoId=False,
description="this is a test collection",
primaryField="id",
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -5,7 +5,7 @@

setup(
name="milvus_cli",
version="v0.4.0",
version="v0.4.1",
author="Milvus Team",
author_email="milvus-team@zilliz.com",
url="https://github.com/zilliztech/milvus_cli",
@@ -17,7 +17,7 @@
include_package_data=True,
install_requires=[
"Click==8.0.1",
"pymilvus==2.3.0",
"pymilvus==2.3.4",
"tabulate==0.8.9",
"requests==2.26.0",
],