pvw-cli 1.0.12__py3-none-any.whl → 1.2.0__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 +2 -2
- purviewcli/cli/account.py +24 -24
- purviewcli/cli/cli.py +16 -16
- purviewcli/cli/collections.py +24 -24
- purviewcli/cli/domain.py +8 -8
- purviewcli/cli/entity.py +328 -222
- purviewcli/cli/glossary.py +29 -29
- purviewcli/cli/health.py +2 -2
- purviewcli/cli/insight.py +7 -7
- purviewcli/cli/lineage.py +11 -11
- purviewcli/cli/unified_catalog.py +610 -29
- purviewcli/cli/workflow.py +43 -43
- purviewcli/client/_entity.py +35 -0
- purviewcli/client/_unified_catalog.py +7 -0
- {pvw_cli-1.0.12.dist-info → pvw_cli-1.2.0.dist-info}/METADATA +378 -58
- {pvw_cli-1.0.12.dist-info → pvw_cli-1.2.0.dist-info}/RECORD +19 -19
- {pvw_cli-1.0.12.dist-info → pvw_cli-1.2.0.dist-info}/WHEEL +0 -0
- {pvw_cli-1.0.12.dist-info → pvw_cli-1.2.0.dist-info}/entry_points.txt +0 -0
- {pvw_cli-1.0.12.dist-info → pvw_cli-1.2.0.dist-info}/top_level.txt +0 -0
purviewcli/cli/glossary.py
CHANGED
|
@@ -49,7 +49,7 @@ def create(payload_file):
|
|
|
49
49
|
result = client.glossaryCreate(args)
|
|
50
50
|
console.print(json.dumps(result, indent=2))
|
|
51
51
|
except Exception as e:
|
|
52
|
-
console.print(f"[red]
|
|
52
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
53
53
|
|
|
54
54
|
@glossary.command()
|
|
55
55
|
@click.option('--payload-file', required=True, type=click.Path(exists=True), help='Path to JSON file with categories data')
|
|
@@ -61,7 +61,7 @@ def create_categories(payload_file):
|
|
|
61
61
|
result = client.glossaryCreateCategories(args)
|
|
62
62
|
console.print(json.dumps(result, indent=2))
|
|
63
63
|
except Exception as e:
|
|
64
|
-
console.print(f"[red]
|
|
64
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
65
65
|
|
|
66
66
|
@glossary.command()
|
|
67
67
|
@click.option('--payload-file', required=True, type=click.Path(exists=True), help='Path to JSON file with category data')
|
|
@@ -73,7 +73,7 @@ def create_category(payload_file):
|
|
|
73
73
|
result = client.glossaryCreateCategory(args)
|
|
74
74
|
console.print(json.dumps(result, indent=2))
|
|
75
75
|
except Exception as e:
|
|
76
|
-
console.print(f"[red]
|
|
76
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
77
77
|
|
|
78
78
|
@glossary.command()
|
|
79
79
|
@click.option('--payload-file', required=True, type=click.Path(exists=True), help='Path to JSON file with term data')
|
|
@@ -86,7 +86,7 @@ def create_term(payload_file, include_term_hierarchy):
|
|
|
86
86
|
result = client.glossaryCreateTerm(args)
|
|
87
87
|
console.print(json.dumps(result, indent=2))
|
|
88
88
|
except Exception as e:
|
|
89
|
-
console.print(f"[red]
|
|
89
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
90
90
|
|
|
91
91
|
@glossary.command()
|
|
92
92
|
@click.option('--payload-file', required=True, type=click.Path(exists=True), help='Path to JSON file with terms data')
|
|
@@ -99,7 +99,7 @@ def create_terms(payload_file, include_term_hierarchy):
|
|
|
99
99
|
result = client.glossaryCreateTerms(args)
|
|
100
100
|
console.print(json.dumps(result, indent=2))
|
|
101
101
|
except Exception as e:
|
|
102
|
-
console.print(f"[red]
|
|
102
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
103
103
|
|
|
104
104
|
# === DELETE OPERATIONS ===
|
|
105
105
|
|
|
@@ -113,7 +113,7 @@ def delete(glossary_guid):
|
|
|
113
113
|
result = client.glossaryDelete(args)
|
|
114
114
|
console.print(json.dumps(result, indent=2))
|
|
115
115
|
except Exception as e:
|
|
116
|
-
console.print(f"[red]
|
|
116
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
117
117
|
|
|
118
118
|
@glossary.command()
|
|
119
119
|
@click.option('--category-guid', required=True, help='The globally unique identifier of the category')
|
|
@@ -125,7 +125,7 @@ def delete_category(category_guid):
|
|
|
125
125
|
result = client.glossaryDeleteCategory(args)
|
|
126
126
|
console.print(json.dumps(result, indent=2))
|
|
127
127
|
except Exception as e:
|
|
128
|
-
console.print(f"[red]
|
|
128
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
129
129
|
|
|
130
130
|
@glossary.command()
|
|
131
131
|
@click.option('--term-guid', required=True, help='The globally unique identifier for glossary term')
|
|
@@ -137,7 +137,7 @@ def delete_term(term_guid):
|
|
|
137
137
|
result = client.glossaryDeleteTerm(args)
|
|
138
138
|
console.print(json.dumps(result, indent=2))
|
|
139
139
|
except Exception as e:
|
|
140
|
-
console.print(f"[red]
|
|
140
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
141
141
|
|
|
142
142
|
# === PUT OPERATIONS ===
|
|
143
143
|
|
|
@@ -152,7 +152,7 @@ def put(glossary_guid, payload_file):
|
|
|
152
152
|
result = client.glossaryPut(args)
|
|
153
153
|
console.print(json.dumps(result, indent=2))
|
|
154
154
|
except Exception as e:
|
|
155
|
-
console.print(f"[red]
|
|
155
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
156
156
|
|
|
157
157
|
@glossary.command()
|
|
158
158
|
@click.option('--category-guid', required=True, help='The globally unique identifier of the category')
|
|
@@ -165,7 +165,7 @@ def put_category(category_guid, payload_file):
|
|
|
165
165
|
result = client.glossaryPutCategory(args)
|
|
166
166
|
console.print(json.dumps(result, indent=2))
|
|
167
167
|
except Exception as e:
|
|
168
|
-
console.print(f"[red]
|
|
168
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
169
169
|
|
|
170
170
|
@glossary.command()
|
|
171
171
|
@click.option('--category-guid', required=True, help='The globally unique identifier of the category')
|
|
@@ -178,7 +178,7 @@ def put_category_partial(category_guid, payload_file):
|
|
|
178
178
|
result = client.glossaryPutCategoryPartial(args)
|
|
179
179
|
console.print(json.dumps(result, indent=2))
|
|
180
180
|
except Exception as e:
|
|
181
|
-
console.print(f"[red]
|
|
181
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
182
182
|
|
|
183
183
|
@glossary.command()
|
|
184
184
|
@click.option('--glossary-guid', required=True, help='The globally unique identifier for glossary')
|
|
@@ -192,7 +192,7 @@ def put_partial(glossary_guid, payload_file, include_term_hierarchy):
|
|
|
192
192
|
result = client.glossaryPutPartial(args)
|
|
193
193
|
console.print(json.dumps(result, indent=2))
|
|
194
194
|
except Exception as e:
|
|
195
|
-
console.print(f"[red]
|
|
195
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
196
196
|
|
|
197
197
|
@glossary.command()
|
|
198
198
|
@click.option('--term-guid', required=True, help='The globally unique identifier for glossary term')
|
|
@@ -206,7 +206,7 @@ def put_term(term_guid, payload_file, include_term_hierarchy):
|
|
|
206
206
|
result = client.glossaryPutTerm(args)
|
|
207
207
|
console.print(json.dumps(result, indent=2))
|
|
208
208
|
except Exception as e:
|
|
209
|
-
console.print(f"[red]
|
|
209
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
210
210
|
|
|
211
211
|
@glossary.command()
|
|
212
212
|
@click.option('--term-guid', required=True, help='The globally unique identifier for glossary term')
|
|
@@ -220,7 +220,7 @@ def put_term_partial(term_guid, payload_file, include_term_hierarchy):
|
|
|
220
220
|
result = client.glossaryPutTermPartial(args)
|
|
221
221
|
console.print(json.dumps(result, indent=2))
|
|
222
222
|
except Exception as e:
|
|
223
|
-
console.print(f"[red]
|
|
223
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
224
224
|
|
|
225
225
|
@glossary.command()
|
|
226
226
|
@click.option('--term-guid', required=True, help='The globally unique identifier for glossary term')
|
|
@@ -233,7 +233,7 @@ def put_terms_assigned_entities(term_guid, payload_file):
|
|
|
233
233
|
result = client.glossaryPutTermsAssignedEntities(args)
|
|
234
234
|
console.print(json.dumps(result, indent=2))
|
|
235
235
|
except Exception as e:
|
|
236
|
-
console.print(f"[red]
|
|
236
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
237
237
|
|
|
238
238
|
# === READ OPERATIONS ===
|
|
239
239
|
|
|
@@ -251,7 +251,7 @@ def _read_glossaries_impl(glossary_guid, limit, offset, sort, ignore_terms_and_c
|
|
|
251
251
|
result = client.glossaryRead(args)
|
|
252
252
|
console.print(json.dumps(result, indent=2))
|
|
253
253
|
except Exception as e:
|
|
254
|
-
console.print(f"[red]
|
|
254
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
255
255
|
|
|
256
256
|
@glossary.command(name="read", help="Read glossaries and list all glossaries")
|
|
257
257
|
@click.option("--glossary-guid", help="The globally unique identifier for glossary")
|
|
@@ -286,7 +286,7 @@ def read_categories(glossary_guid, limit, offset, sort):
|
|
|
286
286
|
result = client.glossaryReadCategories(args)
|
|
287
287
|
console.print(json.dumps(result, indent=2))
|
|
288
288
|
except Exception as e:
|
|
289
|
-
console.print(f"[red]
|
|
289
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
290
290
|
|
|
291
291
|
@glossary.command()
|
|
292
292
|
@click.option('--glossary-guid', help='The globally unique identifier for glossary')
|
|
@@ -301,7 +301,7 @@ def read_categories_headers(glossary_guid, limit, offset, sort):
|
|
|
301
301
|
result = client.glossaryReadCategoriesHeaders(args)
|
|
302
302
|
console.print(json.dumps(result, indent=2))
|
|
303
303
|
except Exception as e:
|
|
304
|
-
console.print(f"[red]
|
|
304
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
305
305
|
|
|
306
306
|
@glossary.command()
|
|
307
307
|
@click.option('--category-guid', help='The globally unique identifier of the category')
|
|
@@ -316,7 +316,7 @@ def read_category(category_guid, limit, offset, sort):
|
|
|
316
316
|
result = client.glossaryReadCategory(args)
|
|
317
317
|
console.print(json.dumps(result, indent=2))
|
|
318
318
|
except Exception as e:
|
|
319
|
-
console.print(f"[red]
|
|
319
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
320
320
|
|
|
321
321
|
@glossary.command()
|
|
322
322
|
@click.option('--category-guid', help='The globally unique identifier of the category')
|
|
@@ -328,7 +328,7 @@ def read_category_related(category_guid):
|
|
|
328
328
|
result = client.glossaryReadCategoryRelated(args)
|
|
329
329
|
console.print(json.dumps(result, indent=2))
|
|
330
330
|
except Exception as e:
|
|
331
|
-
console.print(f"[red]
|
|
331
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
332
332
|
|
|
333
333
|
@glossary.command()
|
|
334
334
|
@click.option('--category-guid', help='The globally unique identifier of the category')
|
|
@@ -343,7 +343,7 @@ def read_category_terms(category_guid, limit, offset, sort):
|
|
|
343
343
|
result = client.glossaryReadCategoryTerms(args)
|
|
344
344
|
console.print(json.dumps(result, indent=2))
|
|
345
345
|
except Exception as e:
|
|
346
|
-
console.print(f"[red]
|
|
346
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
347
347
|
|
|
348
348
|
@glossary.command()
|
|
349
349
|
@click.option('--glossary-guid', help='The globally unique identifier for glossary')
|
|
@@ -356,7 +356,7 @@ def read_detailed(glossary_guid, include_term_hierarchy):
|
|
|
356
356
|
result = client.glossaryReadDetailed(args)
|
|
357
357
|
console.print(json.dumps(result, indent=2))
|
|
358
358
|
except Exception as e:
|
|
359
|
-
console.print(f"[red]
|
|
359
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
360
360
|
|
|
361
361
|
@glossary.command()
|
|
362
362
|
@click.option('--term-guid', help='The globally unique identifier for glossary term')
|
|
@@ -369,7 +369,7 @@ def read_term(term_guid, include_term_hierarchy):
|
|
|
369
369
|
result = client.glossaryReadTerm(args)
|
|
370
370
|
console.print(json.dumps(result, indent=2))
|
|
371
371
|
except Exception as e:
|
|
372
|
-
console.print(f"[red]
|
|
372
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
373
373
|
|
|
374
374
|
@glossary.command()
|
|
375
375
|
@click.option('--glossary-guid', help='The globally unique identifier for glossary')
|
|
@@ -386,7 +386,7 @@ def read_terms(glossary_guid, limit, offset, sort, ext_info, include_term_hierar
|
|
|
386
386
|
result = client.glossaryReadTerms(args)
|
|
387
387
|
console.print(json.dumps(result, indent=2))
|
|
388
388
|
except Exception as e:
|
|
389
|
-
console.print(f"[red]
|
|
389
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
390
390
|
|
|
391
391
|
@glossary.command(name="list-terms", help="List all terms in a glossary (alias for read-terms)")
|
|
392
392
|
@click.option('--glossary-guid', help='The globally unique identifier for glossary')
|
|
@@ -403,7 +403,7 @@ def list_terms(glossary_guid, limit, offset, sort, ext_info, include_term_hierar
|
|
|
403
403
|
result = client.glossaryReadTerms(args)
|
|
404
404
|
console.print(json.dumps(result, indent=2))
|
|
405
405
|
except Exception as e:
|
|
406
|
-
console.print(f"[red]
|
|
406
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
407
407
|
|
|
408
408
|
@glossary.command()
|
|
409
409
|
@click.option('--term-guid', help='The globally unique identifier for glossary term')
|
|
@@ -418,7 +418,7 @@ def read_terms_assigned_entities(term_guid, limit, offset, sort):
|
|
|
418
418
|
result = client.glossaryReadTermsAssignedEntities(args)
|
|
419
419
|
console.print(json.dumps(result, indent=2))
|
|
420
420
|
except Exception as e:
|
|
421
|
-
console.print(f"[red]
|
|
421
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
422
422
|
|
|
423
423
|
@glossary.command()
|
|
424
424
|
@click.option('--glossary-guid', help='The globally unique identifier for glossary')
|
|
@@ -433,7 +433,7 @@ def read_terms_headers(glossary_guid, limit, offset, sort):
|
|
|
433
433
|
result = client.glossaryReadTermsHeaders(args)
|
|
434
434
|
console.print(json.dumps(result, indent=2))
|
|
435
435
|
except Exception as e:
|
|
436
|
-
console.print(f"[red]
|
|
436
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
437
437
|
|
|
438
438
|
@glossary.command()
|
|
439
439
|
@click.option('--operation-guid', help='The globally unique identifier for async operation/job')
|
|
@@ -445,7 +445,7 @@ def read_terms_import(operation_guid):
|
|
|
445
445
|
result = client.glossaryReadTermsImport(args)
|
|
446
446
|
console.print(json.dumps(result, indent=2))
|
|
447
447
|
except Exception as e:
|
|
448
|
-
console.print(f"[red]
|
|
448
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
449
449
|
|
|
450
450
|
@glossary.command()
|
|
451
451
|
@click.option('--term-guid', help='The globally unique identifier for glossary term')
|
|
@@ -460,7 +460,7 @@ def read_terms_related(term_guid, limit, offset, sort):
|
|
|
460
460
|
result = client.glossaryReadTermsRelated(args)
|
|
461
461
|
console.print(json.dumps(result, indent=2))
|
|
462
462
|
except Exception as e:
|
|
463
|
-
console.print(f"[red]
|
|
463
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
464
464
|
|
|
465
465
|
@glossary.command(name="import-terms")
|
|
466
466
|
@click.option('--csv-file', required=False, type=click.Path(exists=True), help='CSV file with glossary terms')
|
purviewcli/cli/health.py
CHANGED
|
@@ -194,7 +194,7 @@ def update(action_id, status, assigned_to, reason):
|
|
|
194
194
|
result = client.update_health_action(args)
|
|
195
195
|
|
|
196
196
|
if result and result.get("status") == "success":
|
|
197
|
-
console.print(f"[green]
|
|
197
|
+
console.print(f"[green][OK][/green] Health action updated successfully: {action_id}")
|
|
198
198
|
if status:
|
|
199
199
|
console.print(f" Status: {status}")
|
|
200
200
|
if assigned_to:
|
|
@@ -216,7 +216,7 @@ def delete(action_id):
|
|
|
216
216
|
result = client.delete_health_action(args)
|
|
217
217
|
|
|
218
218
|
if result and result.get("status") == "success":
|
|
219
|
-
console.print(f"[green]
|
|
219
|
+
console.print(f"[green][OK][/green] Health action deleted successfully: {action_id}")
|
|
220
220
|
else:
|
|
221
221
|
console.print(f"[red]Failed to delete health action: {action_id}[/red]")
|
|
222
222
|
|
purviewcli/cli/insight.py
CHANGED
|
@@ -37,7 +37,7 @@ def asset_distribution():
|
|
|
37
37
|
result = client.assetDistribution({})
|
|
38
38
|
console.print(json.dumps(result, indent=2))
|
|
39
39
|
except Exception as e:
|
|
40
|
-
console.print(f"[red]
|
|
40
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
41
41
|
|
|
42
42
|
@insight.command()
|
|
43
43
|
def files_aggregation():
|
|
@@ -48,7 +48,7 @@ def files_aggregation():
|
|
|
48
48
|
result = client.filesAggregation({})
|
|
49
49
|
console.print(json.dumps(result, indent=2))
|
|
50
50
|
except Exception as e:
|
|
51
|
-
console.print(f"[red]
|
|
51
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
52
52
|
|
|
53
53
|
@insight.command()
|
|
54
54
|
def files_without_resource_set():
|
|
@@ -59,7 +59,7 @@ def files_without_resource_set():
|
|
|
59
59
|
result = client.filesWithoutResourceSet({})
|
|
60
60
|
console.print(json.dumps(result, indent=2))
|
|
61
61
|
except Exception as e:
|
|
62
|
-
console.print(f"[red]
|
|
62
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
63
63
|
|
|
64
64
|
@insight.command()
|
|
65
65
|
@click.option('--number-of-days', default=30, show_default=True, type=int, help='Trailing time period in days')
|
|
@@ -72,7 +72,7 @@ def scan_status_summary(number_of_days):
|
|
|
72
72
|
result = client.scanStatusSummary(args)
|
|
73
73
|
console.print(json.dumps(result, indent=2))
|
|
74
74
|
except Exception as e:
|
|
75
|
-
console.print(f"[red]
|
|
75
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
76
76
|
|
|
77
77
|
@insight.command()
|
|
78
78
|
@click.option('--number-of-days', default=30, show_default=True, type=int, help='Trailing time period in days')
|
|
@@ -85,7 +85,7 @@ def scan_status_summary_by_ts(number_of_days):
|
|
|
85
85
|
result = client.scanStatusSummaryByTs(args)
|
|
86
86
|
console.print(json.dumps(result, indent=2))
|
|
87
87
|
except Exception as e:
|
|
88
|
-
console.print(f"[red]
|
|
88
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
89
89
|
|
|
90
90
|
@insight.command()
|
|
91
91
|
def tags():
|
|
@@ -96,7 +96,7 @@ def tags():
|
|
|
96
96
|
result = client.tags({})
|
|
97
97
|
console.print(json.dumps(result, indent=2))
|
|
98
98
|
except Exception as e:
|
|
99
|
-
console.print(f"[red]
|
|
99
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
100
100
|
|
|
101
101
|
@insight.command()
|
|
102
102
|
def tags_time_series():
|
|
@@ -107,7 +107,7 @@ def tags_time_series():
|
|
|
107
107
|
result = client.tagsTimeSeries({})
|
|
108
108
|
console.print(json.dumps(result, indent=2))
|
|
109
109
|
except Exception as e:
|
|
110
|
-
console.print(f"[red]
|
|
110
|
+
console.print(f"[red][X] Error: {e}[/red]")
|
|
111
111
|
|
|
112
112
|
# Make the insight group available for import
|
|
113
113
|
__all__ = ['insight']
|
purviewcli/cli/lineage.py
CHANGED
|
@@ -156,7 +156,7 @@ def templates(ctx):
|
|
|
156
156
|
console.print("[green]SUCCESS: Lineage templates retrieved successfully[/green]")
|
|
157
157
|
console.print(json.dumps(result, indent=2))
|
|
158
158
|
else:
|
|
159
|
-
console.print("[yellow]
|
|
159
|
+
console.print("[yellow][!] Lineage templates completed with no result[/yellow]")
|
|
160
160
|
|
|
161
161
|
except Exception as e:
|
|
162
162
|
console.print(f"[red]ERROR: Error executing lineage templates: {str(e)}[/red]")
|
|
@@ -196,7 +196,7 @@ def read(ctx, guid, depth, width, direction, output):
|
|
|
196
196
|
console.print("[green]SUCCESS: Lineage read completed successfully[/green]")
|
|
197
197
|
console.print(json.dumps(result, indent=2))
|
|
198
198
|
else:
|
|
199
|
-
console.print("[yellow]
|
|
199
|
+
console.print("[yellow][!] Lineage read completed with no result[/yellow]")
|
|
200
200
|
|
|
201
201
|
except Exception as e:
|
|
202
202
|
console.print(f"[red]ERROR: Error executing lineage read: {str(e)}[/red]")
|
|
@@ -229,7 +229,7 @@ def impact(ctx, entity_guid, output_file):
|
|
|
229
229
|
console.print("[green]SUCCESS: Lineage impact analysis completed successfully[/green]")
|
|
230
230
|
console.print(json.dumps(result, indent=2))
|
|
231
231
|
else:
|
|
232
|
-
console.print("[yellow]
|
|
232
|
+
console.print("[yellow][!] Lineage impact analysis completed with no result[/yellow]")
|
|
233
233
|
|
|
234
234
|
except Exception as e:
|
|
235
235
|
console.print(f"[red]ERROR: Error executing lineage impact: {str(e)}[/red]")
|
|
@@ -267,7 +267,7 @@ def analyze(ctx, entity_guid, direction, depth, output_file):
|
|
|
267
267
|
console.print("[green]SUCCESS: Lineage analysis completed successfully[/green]")
|
|
268
268
|
console.print(json.dumps(result, indent=2))
|
|
269
269
|
else:
|
|
270
|
-
console.print("[yellow]
|
|
270
|
+
console.print("[yellow][!] Lineage analysis completed with no result[/yellow]")
|
|
271
271
|
|
|
272
272
|
except Exception as e:
|
|
273
273
|
console.print(f"[red]ERROR: Error executing lineage analyze: {str(e)}[/red]")
|
|
@@ -289,7 +289,7 @@ def create_bulk(ctx, json_file):
|
|
|
289
289
|
lineage_client = Lineage()
|
|
290
290
|
args = {'--payloadFile': json_file}
|
|
291
291
|
result = lineage_client.lineageBulkCreate(args)
|
|
292
|
-
console.print("[green]
|
|
292
|
+
console.print("[green][OK] Bulk lineage creation completed successfully[/green]")
|
|
293
293
|
console.print(json.dumps(result, indent=2))
|
|
294
294
|
except Exception as e:
|
|
295
295
|
console.print(f"[red]ERROR: Error executing lineage create-bulk: {str(e)}[/red]")
|
|
@@ -327,7 +327,7 @@ def analyze_column(ctx, guid, column_name, direction, depth, output):
|
|
|
327
327
|
console.print("[green]SUCCESS: Column-level lineage analysis completed successfully[/green]")
|
|
328
328
|
console.print(json.dumps(result, indent=2))
|
|
329
329
|
else:
|
|
330
|
-
console.print("[yellow]
|
|
330
|
+
console.print("[yellow][!] Column-level lineage analysis completed with no result[/yellow]")
|
|
331
331
|
|
|
332
332
|
except Exception as e:
|
|
333
333
|
console.print(f"[red]ERROR: Error executing lineage analyze-column: {str(e)}[/red]")
|
|
@@ -384,7 +384,7 @@ def partial_lineage(ctx, guid, columns, relationship_types, depth, direction, ou
|
|
|
384
384
|
console.print("[green]SUCCESS: Partial lineage query completed successfully[/green]")
|
|
385
385
|
console.print(json.dumps(result, indent=2))
|
|
386
386
|
else:
|
|
387
|
-
console.print("[yellow]
|
|
387
|
+
console.print("[yellow][!] Partial lineage query completed with no result[/yellow]")
|
|
388
388
|
except Exception as e:
|
|
389
389
|
console.print(f"[red]ERROR: Error executing lineage partial: {str(e)}[/red]")
|
|
390
390
|
|
|
@@ -407,7 +407,7 @@ def impact_report(ctx, entity_guid, output_file):
|
|
|
407
407
|
reporting = LineageReporting(analyzer)
|
|
408
408
|
import asyncio
|
|
409
409
|
report = asyncio.run(reporting.generate_impact_report(entity_guid, output_file or f"impact_report_{entity_guid}.json"))
|
|
410
|
-
console.print("[green]
|
|
410
|
+
console.print("[green][OK] Impact analysis report generated successfully[/green]")
|
|
411
411
|
if output_file:
|
|
412
412
|
console.print(f"[cyan]Report saved to {output_file}[/cyan]")
|
|
413
413
|
else:
|
|
@@ -448,10 +448,10 @@ def read_by_attribute(ctx, type_name, qualified_name, depth, width, direction, o
|
|
|
448
448
|
lineage_client = Lineage()
|
|
449
449
|
result = lineage_client.lineageReadUniqueAttribute(args)
|
|
450
450
|
if result:
|
|
451
|
-
console.print("[green]
|
|
451
|
+
console.print("[green][OK] Lineage by attribute read completed successfully[/green]")
|
|
452
452
|
console.print(json.dumps(result, indent=2))
|
|
453
453
|
else:
|
|
454
|
-
console.print("[yellow]
|
|
454
|
+
console.print("[yellow][!] Lineage by attribute read completed with no result[/yellow]")
|
|
455
455
|
except Exception as e:
|
|
456
456
|
console.print(f"[red]ERROR: Error executing lineage read-by-attribute: {str(e)}[/red]")
|
|
457
457
|
|
|
@@ -468,7 +468,7 @@ def read_lineage(ctx, guid, direction, depth):
|
|
|
468
468
|
lineage_client = Lineage()
|
|
469
469
|
args = {"--guid": guid, "--direction": direction, "--depth": depth}
|
|
470
470
|
result = lineage_client.get_lineage_by_guid(args)
|
|
471
|
-
console.print("[green]
|
|
471
|
+
console.print("[green][OK] Lineage read completed successfully[/green]")
|
|
472
472
|
console.print(json.dumps(result, indent=2))
|
|
473
473
|
except Exception as e:
|
|
474
474
|
console.print(f"[red]ERROR: Error executing lineage read: {str(e)}[/red]")
|