pvw-cli 1.0.4__py3-none-any.whl → 1.0.6__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of pvw-cli might be problematic. Click here for more details.
- purviewcli/__init__.py +1 -1
- purviewcli/cli/account.py +10 -10
- purviewcli/cli/collections.py +6 -6
- purviewcli/cli/entity.py +6 -4
- purviewcli/cli/types.py +2 -2
- purviewcli/client/_search.py +24 -8
- {pvw_cli-1.0.4.dist-info → pvw_cli-1.0.6.dist-info}/METADATA +1 -1
- {pvw_cli-1.0.4.dist-info → pvw_cli-1.0.6.dist-info}/RECORD +11 -11
- {pvw_cli-1.0.4.dist-info → pvw_cli-1.0.6.dist-info}/WHEEL +0 -0
- {pvw_cli-1.0.4.dist-info → pvw_cli-1.0.6.dist-info}/entry_points.txt +0 -0
- {pvw_cli-1.0.4.dist-info → pvw_cli-1.0.6.dist-info}/top_level.txt +0 -0
purviewcli/__init__.py
CHANGED
purviewcli/cli/account.py
CHANGED
|
@@ -45,7 +45,7 @@ def get_account(ctx):
|
|
|
45
45
|
|
|
46
46
|
from purviewcli.client._account import Account
|
|
47
47
|
account_client = Account()
|
|
48
|
-
result = account_client.
|
|
48
|
+
result = account_client.accountRead(args)
|
|
49
49
|
|
|
50
50
|
if result:
|
|
51
51
|
console.print("[green]✓ Account information retrieved successfully[/green]")
|
|
@@ -71,7 +71,7 @@ def get_access_keys(ctx):
|
|
|
71
71
|
|
|
72
72
|
from purviewcli.client._account import Account
|
|
73
73
|
account_client = Account()
|
|
74
|
-
result = account_client.
|
|
74
|
+
result = account_client.accountReadAccessKeys(args)
|
|
75
75
|
|
|
76
76
|
if result:
|
|
77
77
|
console.print("[green]✓ Access keys retrieved successfully[/green]")
|
|
@@ -101,7 +101,7 @@ def regenerate_access_keys(ctx, key_type):
|
|
|
101
101
|
|
|
102
102
|
from purviewcli.client._account import Account
|
|
103
103
|
account_client = Account()
|
|
104
|
-
result = account_client.
|
|
104
|
+
result = account_client.accountRegenerateAccessKey(args)
|
|
105
105
|
|
|
106
106
|
if result:
|
|
107
107
|
console.print("[green]✓ Access keys regenerated successfully[/green]")
|
|
@@ -129,7 +129,7 @@ def update_account(ctx, friendly_name):
|
|
|
129
129
|
|
|
130
130
|
from purviewcli.client._account import Account
|
|
131
131
|
account_client = Account()
|
|
132
|
-
result = account_client.
|
|
132
|
+
result = account_client.accountUpdate(args)
|
|
133
133
|
|
|
134
134
|
if result:
|
|
135
135
|
console.print("[green]✓ Account updated successfully[/green]")
|
|
@@ -153,9 +153,9 @@ def get_collections(ctx):
|
|
|
153
153
|
|
|
154
154
|
args = {}
|
|
155
155
|
|
|
156
|
-
from purviewcli.client.
|
|
157
|
-
account_client =
|
|
158
|
-
result = account_client.
|
|
156
|
+
from purviewcli.client._collections import Collections
|
|
157
|
+
account_client = Collections()
|
|
158
|
+
result = account_client.collectionsRead(args)
|
|
159
159
|
|
|
160
160
|
if result:
|
|
161
161
|
console.print("[green]✓ Collections retrieved successfully[/green]")
|
|
@@ -181,9 +181,9 @@ def get_collection(ctx, collection_name):
|
|
|
181
181
|
|
|
182
182
|
args = {"--collectionName": collection_name}
|
|
183
183
|
|
|
184
|
-
from purviewcli.client.
|
|
185
|
-
account_client =
|
|
186
|
-
result = account_client.
|
|
184
|
+
from purviewcli.client._collections import Collections
|
|
185
|
+
account_client = Collections()
|
|
186
|
+
result = account_client.collectionsRead(args)
|
|
187
187
|
|
|
188
188
|
if result:
|
|
189
189
|
console.print("[green]✓ Collection information retrieved successfully[/green]")
|
purviewcli/cli/collections.py
CHANGED
|
@@ -48,7 +48,7 @@ def create(collection_name, friendly_name, description, parent_collection, paylo
|
|
|
48
48
|
"--payloadFile": payload_file,
|
|
49
49
|
}
|
|
50
50
|
client = Collections()
|
|
51
|
-
result = client.
|
|
51
|
+
result = client.collectionsCreate(args)
|
|
52
52
|
click.echo(json.dumps(result, indent=2))
|
|
53
53
|
except Exception as e:
|
|
54
54
|
click.echo(f"Error: {e}")
|
|
@@ -61,7 +61,7 @@ def delete(collection_name):
|
|
|
61
61
|
try:
|
|
62
62
|
args = {"--collectionName": collection_name}
|
|
63
63
|
client = Collections()
|
|
64
|
-
result = client.
|
|
64
|
+
result = client.collectionsDelete(args)
|
|
65
65
|
click.echo(json.dumps(result, indent=2))
|
|
66
66
|
except Exception as e:
|
|
67
67
|
click.echo(f"Error: {e}")
|
|
@@ -74,7 +74,7 @@ def get(collection_name):
|
|
|
74
74
|
try:
|
|
75
75
|
args = {"--collectionName": collection_name}
|
|
76
76
|
client = Collections()
|
|
77
|
-
result = client.
|
|
77
|
+
result = client.collectionsRead(args)
|
|
78
78
|
click.echo(json.dumps(result, indent=2))
|
|
79
79
|
except Exception as e:
|
|
80
80
|
click.echo(f"Error: {e}")
|
|
@@ -85,7 +85,7 @@ def list():
|
|
|
85
85
|
"""List all collections"""
|
|
86
86
|
try:
|
|
87
87
|
client = Collections()
|
|
88
|
-
result = client.
|
|
88
|
+
result = client.collectionsRead({})
|
|
89
89
|
click.echo(json.dumps(result, indent=2))
|
|
90
90
|
except Exception as e:
|
|
91
91
|
click.echo(f"Error: {e}")
|
|
@@ -104,7 +104,7 @@ def import_csv(csv_file):
|
|
|
104
104
|
args = {"--csv-file": csv_file}
|
|
105
105
|
client = Collections()
|
|
106
106
|
# You may need to implement this method in your client
|
|
107
|
-
result = client.
|
|
107
|
+
result = client.collectionsImport(args)
|
|
108
108
|
click.echo(json.dumps(result, indent=2))
|
|
109
109
|
except Exception as e:
|
|
110
110
|
click.echo(f"Error: {e}")
|
|
@@ -130,7 +130,7 @@ def export_csv(output_file, include_hierarchy, include_metadata):
|
|
|
130
130
|
}
|
|
131
131
|
client = Collections()
|
|
132
132
|
# You may need to implement this method in your client
|
|
133
|
-
result = client.
|
|
133
|
+
result = client.collectionsExport(args)
|
|
134
134
|
click.echo(json.dumps(result, indent=2))
|
|
135
135
|
except Exception as e:
|
|
136
136
|
click.echo(f"Error: {e}")
|
purviewcli/cli/entity.py
CHANGED
|
@@ -1799,16 +1799,18 @@ def list(type_name, limit):
|
|
|
1799
1799
|
from purviewcli.client._search import Search
|
|
1800
1800
|
search_client = Search()
|
|
1801
1801
|
|
|
1802
|
-
# Create search query payload
|
|
1802
|
+
# Create search query payload with proper filter structure
|
|
1803
1803
|
search_payload = {
|
|
1804
1804
|
"keywords": "*",
|
|
1805
1805
|
"limit": limit,
|
|
1806
|
-
"filter": {}
|
|
1807
1806
|
}
|
|
1808
1807
|
|
|
1809
|
-
#
|
|
1808
|
+
# Only add filter if type_name is specified
|
|
1810
1809
|
if type_name:
|
|
1811
|
-
search_payload["filter"]
|
|
1810
|
+
search_payload["filter"] = {
|
|
1811
|
+
"entityType": type_name # Send as string, not array
|
|
1812
|
+
}
|
|
1813
|
+
# If no type specified, don't include filter at all
|
|
1812
1814
|
|
|
1813
1815
|
# Convert to args format expected by searchQuery
|
|
1814
1816
|
search_args = {
|
purviewcli/cli/types.py
CHANGED
|
@@ -275,7 +275,7 @@ def read_typedefs(include_term_template, type_):
|
|
|
275
275
|
try:
|
|
276
276
|
args = {'--includeTermTemplate': include_term_template, '--type': type_}
|
|
277
277
|
client = Types()
|
|
278
|
-
result = client.
|
|
278
|
+
result = client.typesRead(args)
|
|
279
279
|
click.echo(json.dumps(result, indent=2))
|
|
280
280
|
except Exception as e:
|
|
281
281
|
click.echo(f"Error: {e}")
|
|
@@ -288,7 +288,7 @@ def read_typedefs_headers(include_term_template, type_):
|
|
|
288
288
|
try:
|
|
289
289
|
args = {'--includeTermTemplate': include_term_template, '--type': type_}
|
|
290
290
|
client = Types()
|
|
291
|
-
result = client.
|
|
291
|
+
result = client.typesReadHeaders(args)
|
|
292
292
|
click.echo(json.dumps(result, indent=2))
|
|
293
293
|
except Exception as e:
|
|
294
294
|
click.echo(f"Error: {e}")
|
purviewcli/client/_search.py
CHANGED
|
@@ -33,27 +33,43 @@ class Search(Endpoint):
|
|
|
33
33
|
self.endpoint = ENDPOINTS["discovery"]["query"]
|
|
34
34
|
self.params = get_api_version_params("datamap")
|
|
35
35
|
|
|
36
|
-
#
|
|
36
|
+
# Check if direct payload is provided
|
|
37
|
+
if args.get("--payload"):
|
|
38
|
+
import json
|
|
39
|
+
self.payload = json.loads(args["--payload"])
|
|
40
|
+
return
|
|
41
|
+
|
|
42
|
+
# Check if payload file is provided
|
|
43
|
+
if args.get("--payloadFile"):
|
|
44
|
+
self.payload = get_json(args, "--payloadFile")
|
|
45
|
+
return
|
|
46
|
+
|
|
47
|
+
# Build search payload from individual parameters
|
|
37
48
|
search_request = {
|
|
38
49
|
"keywords": args.get("--keywords", "*"),
|
|
39
50
|
"limit": args.get("--limit", 50),
|
|
40
|
-
"offset": args.get("--offset", 0)
|
|
41
|
-
"filter": {},
|
|
42
|
-
"facets": []
|
|
51
|
+
"offset": args.get("--offset", 0)
|
|
43
52
|
}
|
|
44
53
|
|
|
54
|
+
# Only add filter if there are actual filter values
|
|
55
|
+
filter_obj = {}
|
|
56
|
+
|
|
45
57
|
# Add filters if provided
|
|
46
58
|
if args.get("--filter"):
|
|
47
|
-
|
|
59
|
+
filter_obj.update(self._parse_filter(args["--filter"]))
|
|
48
60
|
|
|
49
61
|
if args.get("--entityType"):
|
|
50
|
-
|
|
62
|
+
filter_obj["entityType"] = args["--entityType"]
|
|
51
63
|
|
|
52
64
|
if args.get("--classification"):
|
|
53
|
-
|
|
65
|
+
filter_obj["classification"] = args["--classification"]
|
|
54
66
|
|
|
55
67
|
if args.get("--term"):
|
|
56
|
-
|
|
68
|
+
filter_obj["term"] = args["--term"]
|
|
69
|
+
|
|
70
|
+
# Only include filter if it has content
|
|
71
|
+
if filter_obj:
|
|
72
|
+
search_request["filter"] = filter_obj
|
|
57
73
|
|
|
58
74
|
# Add facets if requested
|
|
59
75
|
if args.get("--facets"):
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
purviewcli/__init__.py,sha256
|
|
1
|
+
purviewcli/__init__.py,sha256=4Em70RIQIEjQmZFrzWalQOgeNx_7jLGYVoevuxAjEwg,423
|
|
2
2
|
purviewcli/__main__.py,sha256=n_PFo1PjW8L1OKCNLsW0vlVSo8tzac_saEYYLTu93iQ,372
|
|
3
3
|
purviewcli/cli/__init__.py,sha256=vrqitIgq2VoisqaHifSpvfZ7DDRpskoF9YUUiPNOKBE,73
|
|
4
|
-
purviewcli/cli/account.py,sha256=
|
|
4
|
+
purviewcli/cli/account.py,sha256=YENHkBD0VREajDqtlkTJ-zUvq8aq7LF52HDSOSsgku8,7080
|
|
5
5
|
purviewcli/cli/cli.py,sha256=imIuh8FoyT8OQGJAyoIYEP8ArAEtnF7GzRc-m1uQ3G8,5930
|
|
6
|
-
purviewcli/cli/collections.py,sha256=
|
|
6
|
+
purviewcli/cli/collections.py,sha256=eIhqdURUkc9SthZYJBbAAp6rYGUYylqPyUfjO0eaLhU,4416
|
|
7
7
|
purviewcli/cli/data_product.py,sha256=WAoUlvugKAR0OHSDuzgtZ_3-QZVAtPzO4cmPWO6qgu0,11190
|
|
8
8
|
purviewcli/cli/domain.py,sha256=zI7YPhcCa4u4MIwnWHQPngTUCKOs6C_rEkdpW-Kl6hM,20897
|
|
9
|
-
purviewcli/cli/entity.py,sha256=
|
|
9
|
+
purviewcli/cli/entity.py,sha256=j3TCedQq9ELa-dz2BOLw_l1jhiwqrjpsGKPlS789Wr0,69113
|
|
10
10
|
purviewcli/cli/glossary.py,sha256=Lt4ifyESuuaZLOzssv4GcQEO2AQKYS8Zy8L9UFfdglU,25696
|
|
11
11
|
purviewcli/cli/insight.py,sha256=Kevqla6iZ7hPgb-gIWQiXSl2er-N0-Z7Q--IH1icWbs,3853
|
|
12
12
|
purviewcli/cli/lineage.py,sha256=J7_KSwtdElWc2N5i5l1YBP6QzaWrqP6nnPrjDKzVEkE,21356
|
|
@@ -16,7 +16,7 @@ purviewcli/cli/relationship.py,sha256=Ky4klI-clKh6sRK7bsI7SwgtVrpo1ljegVyrbqjkeO
|
|
|
16
16
|
purviewcli/cli/scan.py,sha256=91iKDH8iVNJKndJAisrKx3J4HRoPH2qfmxguLZH3xHY,13807
|
|
17
17
|
purviewcli/cli/search.py,sha256=MQazyv_DumX6YJAWzQyN1PXwU5xiteoSgTcEwHHBxc8,5801
|
|
18
18
|
purviewcli/cli/share.py,sha256=QRZhHM59RxdYqXOjSYLfVRZmjwMg4Y-bWxMSQVTQiIE,20197
|
|
19
|
-
purviewcli/cli/types.py,sha256=
|
|
19
|
+
purviewcli/cli/types.py,sha256=zo_8rAqDQ1vqi5y-dBh_sVY6i16UaJLLx_vBJBfZrrw,23729
|
|
20
20
|
purviewcli/cli/workflow.py,sha256=DZLzVCZVp5k7gfBrh7YTARBHHEDgffQ8M0CBQh-h548,13260
|
|
21
21
|
purviewcli/client/__init__.py,sha256=qjhTkXkgxlNUY3R1HkrT_Znt03-2d8JDolPVOeVv2xI,37
|
|
22
22
|
purviewcli/client/_account.py,sha256=5lacA7vvjGBLHUDRjFR7B5E8eN6T07rctVDRXR9JFTY,12397
|
|
@@ -31,7 +31,7 @@ purviewcli/client/_management.py,sha256=2_ZXRSeEzGuHv1muUbn8mQb07enYYuHPI3NskIHI
|
|
|
31
31
|
purviewcli/client/_policystore.py,sha256=wx9Yw6wcvj236ZmmitUKxW5u4YAtfJqAFNuxMpa7HIU,18078
|
|
32
32
|
purviewcli/client/_relationship.py,sha256=KJZRltrzpTw7cfKjlZH2MuoTPS7eHxxp3cqU2etDSEA,9997
|
|
33
33
|
purviewcli/client/_scan.py,sha256=2atEBD-kKWtFuBSWh2P0cwp42gfg7qgwWq-072QZMs4,15154
|
|
34
|
-
purviewcli/client/_search.py,sha256=
|
|
34
|
+
purviewcli/client/_search.py,sha256=IlqqBfDZ4dJqPh1PShMrkIm0_x_5wwMzIqkYZMUWMkQ,11678
|
|
35
35
|
purviewcli/client/_share.py,sha256=vKENIhePuzi3WQazNfv5U9y-6yxRk222zrFA-SGh1pc,10494
|
|
36
36
|
purviewcli/client/_types.py,sha256=ONa3wh1F02QOVy51UGq54121TkqRcWczdXIvNqPIFU0,15454
|
|
37
37
|
purviewcli/client/_unified_catalog.py,sha256=ySIx2t5gfCGn4KDqNB2AvHQbfB4UC4e5DkujoyEZu2I,11814
|
|
@@ -52,8 +52,8 @@ purviewcli/client/settings.py,sha256=nYdnYurTZsgv9vcgljnzVxLPtYVl9q6IplqOzi1aRvI
|
|
|
52
52
|
purviewcli/client/sync_client.py,sha256=IEuQVEud7bpBCwqfmAFGIj9c5Q_m2vb9uoK4ugGfa9c,5977
|
|
53
53
|
purviewcli/plugins/__init__.py,sha256=rpt3OhFt_wSE_o8Ga8AXvw1pqkdBxLmjrhYtE_-LuJo,29
|
|
54
54
|
purviewcli/plugins/plugin_system.py,sha256=C-_dL4FUj90o1JS7Saxkpov6fz0GIF5PFhZTYwqBkWE,26774
|
|
55
|
-
pvw_cli-1.0.
|
|
56
|
-
pvw_cli-1.0.
|
|
57
|
-
pvw_cli-1.0.
|
|
58
|
-
pvw_cli-1.0.
|
|
59
|
-
pvw_cli-1.0.
|
|
55
|
+
pvw_cli-1.0.6.dist-info/METADATA,sha256=LNBPiYTOSi2u0zYiNFkptV6bfwyVCcYKCkKcaZfVppU,12624
|
|
56
|
+
pvw_cli-1.0.6.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
|
|
57
|
+
pvw_cli-1.0.6.dist-info/entry_points.txt,sha256=VI6AAbc6sWahOCX7sn_lhJIr9OiJM0pHF7rmw1YVGlE,82
|
|
58
|
+
pvw_cli-1.0.6.dist-info/top_level.txt,sha256=LrADzPoKwF1xY0pGKpWauyOVruHCIWKCkT7cwIl6IuI,11
|
|
59
|
+
pvw_cli-1.0.6.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|