pyegeria 5.3.8.0__py3-none-any.whl → 5.3.8.2__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.
@@ -189,7 +189,8 @@ def process_markdown_file(
189
189
  f2.write(prov_output)
190
190
  click.echo(f"\n==> Output written to {new_file_path}")
191
191
  else:
192
- click.echo("\nNo updates detected. New File not created.")
192
+ if directive != 'display':
193
+ click.echo("\nNo updates detected. New File not created.")
193
194
 
194
195
  except (Exception):
195
196
  console.print_exception(show_locals=True)
@@ -33,7 +33,8 @@ command_list = ["Provenance", "Create Glossary", "Update Glossary", "Create Term
33
33
  "Create Personal Project", "Update Personal Project", "Create Category", "Update Category",
34
34
  "Create Solution Blueprint", "Update Solution Blueprint", "Create Solution Component",
35
35
  "Update Solution Component", ]
36
- debug_level = "debug"
36
+ # verbosity - verbose, quiet, debug
37
+ debug_level = "verbose"
37
38
  message_types = {
38
39
  "INFO": "INFO-", "WARNING": "WARNING->", "ERROR": "ERROR->", "DEBUG-INFO": "DEBUG-INFO->",
39
40
  "DEBUG-WARNING": "DEBUG-WARNING->", "DEBUG-ERROR": "DEBUG-ERROR->", "ALWAYS": "\n\n==> "
@@ -69,6 +70,12 @@ def is_valid_iso_date(date_text) -> bool:
69
70
  except ValueError:
70
71
  return False
71
72
 
73
+ def set_debug_level(directive: str) -> None:
74
+ """Sets the debug level for the script."""
75
+ global debug_level
76
+ if directive == "display":
77
+ debug_level = "display-only"
78
+
72
79
 
73
80
  def get_current_datetime_string():
74
81
  """Returns the current date and time as a human-readable string."""
@@ -220,6 +227,8 @@ def print_msg(msg_level: str, msg: str, verbosity: str):
220
227
  print(record)
221
228
  case "debug":
222
229
  print(record)
230
+ case "display-only":
231
+ pass
223
232
  case _:
224
233
  print("Invalid verbosity level - exiting\n")
225
234
  sys.exit(1)
@@ -303,7 +312,7 @@ def process_provenance_command(file_path: str, txt: [str]) -> str:
303
312
  existing_prov = extracted_text # Return the cleaned text
304
313
  else:
305
314
  existing_prov = None
306
- print(f"txt is: {txt}, existing_prov: {existing_prov}")
315
+ # print(f"txt is: {txt}, existing_prov: {existing_prov}")
307
316
  existing_prov = existing_prov if existing_prov else " "
308
317
  return f"\n# Provenance:\n{existing_prov}\n{output}\n"
309
318
 
@@ -556,7 +565,7 @@ def process_blueprint_upsert_command(egeria_client: EgeriaTech, element_dictiona
556
565
  A string summarizing the outcome of the processing.
557
566
  """
558
567
  command, object_type, object_action = extract_command_plus(txt)
559
-
568
+ set_debug_level(directive)
560
569
  display_name = process_simple_attribute(txt, ['Display Name', 'Blueprint Name'],ERROR)
561
570
  description = process_simple_attribute(txt, ['Description'])
562
571
  version = process_simple_attribute(txt, ['Version', "Version Identifier", "Published Version"])
@@ -660,6 +669,7 @@ def process_solution_component_upsert_command(egeria_client: EgeriaTech, element
660
669
  Returns: str
661
670
  A string summarizing the outcome of the processing.
662
671
  """
672
+ set_debug_level(directive)
663
673
  bp_qname_list = []
664
674
  command, object_type, object_action = extract_command_plus(txt)
665
675
 
@@ -820,6 +830,7 @@ def process_glossary_upsert_command(egeria_client: EgeriaTech, element_dictionar
820
830
  # object_type = command.split(' ')[1].strip()
821
831
  # object_action = command.split(' ')[0].strip()
822
832
  command, object_type, object_action = extract_command_plus(txt)
833
+ set_debug_level(directive)
823
834
 
824
835
  glossary_name = process_simple_attribute(txt, ['Glossary Name', 'Display Name'])
825
836
  print(Markdown(f"{pre_command} `{object_action}` `{object_type}` for glossary: `\'{glossary_name}\'` with directive: `{directive}` "))
@@ -937,7 +948,7 @@ def process_categories_upsert_command(egeria_client: EgeriaTech, element_diction
937
948
  :return: A string summarizing the outcome of the processing.
938
949
  """
939
950
  valid = True
940
-
951
+ set_debug_level(directive)
941
952
  # command = extract_command(txt)
942
953
  # object_type = command.split(' ')[1].strip()
943
954
  # object_action = command.split(' ')[0].strip()
@@ -1074,7 +1085,7 @@ def process_term_upsert_command(egeria_client: EgeriaTech, element_dictionary: d
1074
1085
  valid = True
1075
1086
  categories_list = None
1076
1087
  cats_exist = True
1077
-
1088
+ set_debug_level(directive)
1078
1089
  known_q_name = None
1079
1090
  command = extract_command(txt)
1080
1091
  object_type = command.split(' ')[1].strip()
@@ -1258,6 +1269,7 @@ def process_per_proj_upsert_command(egeria_client: ProjectManager, element_dicti
1258
1269
  object = command.split()
1259
1270
  object_type = f"{object[1]} {object[2]}"
1260
1271
  object_action = object[0]
1272
+ set_debug_level(directive)
1261
1273
 
1262
1274
  project_name = process_simple_attribute(txt, ['Project Name'])
1263
1275
  description = process_simple_attribute(txt, ['Description'])
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: pyegeria
3
- Version: 5.3.8.0
3
+ Version: 5.3.8.2
4
4
  Summary: A python client for Egeria
5
5
  License: Apache 2.0
6
6
  Keywords: egeria,metadata,governance
@@ -16,7 +16,7 @@ pyegeria/commands/cat/README.md,sha256=-aaAnIT2fcfU63vajgB-RzQk4l4yFdhkyVfSaTPiq
16
16
  pyegeria/commands/cat/__init__.py,sha256=5OCy4m_yZsnSxdy_gvkCyP_OkjvuWKimqUGHYCJc_qA,450
17
17
  pyegeria/commands/cat/dr_egeria_inbox/glossary_creation_experiment.ipynb,sha256=dbzNu90fCKNohOWVSRBOB1GLyd95x8Qw51I5AkaPtso,11552
18
18
  pyegeria/commands/cat/dr_egeria_jupyter.py,sha256=U-3m9BMoCXj2fvuawr3PTc2HQWAXThqQ3sIXjyCWv6s,5912
19
- pyegeria/commands/cat/dr_egeria_md.py,sha256=X4lwgFwYgfDz8TX0qwW6XL9D-ZHIGLPL93dBKZSIsWc,10411
19
+ pyegeria/commands/cat/dr_egeria_md.py,sha256=Fd6k305KQ4Mpfk-ME3XgH7RneGCaIOZ68xelWlCMaF0,10454
20
20
  pyegeria/commands/cat/exp_list_glossaries.py,sha256=dC6Bnfm3YSMTKPP146qeslIFRiZnGu5b7iDYE07p4iU,5817
21
21
  pyegeria/commands/cat/get_asset_graph.py,sha256=xnXJfpDTVH1TJ2TwE3dtjaXU36Di6-N6JAyhothzz2o,12461
22
22
  pyegeria/commands/cat/get_collection.py,sha256=kXPcP8u-SMWfrVyyBhNoxG8mcgB7EV_5i9N9w_IBU7o,5379
@@ -229,7 +229,7 @@ pyegeria/glossary_browser_omvs.py,sha256=hOQJ1ipVfzAqS7UvHCJtKhG5MfpYNJfWk5zk_yK
229
229
  pyegeria/glossary_manager_omvs.py,sha256=JMgvbockir-D1Y9pKKlPg4a9qlRwWAS_7B9wBMcCPnA,66820
230
230
  pyegeria/m_test.py,sha256=M5-M2ZczsAJLXWfSeqTTADHdx6Ku-y4PbQ4M21JthAE,7778
231
231
  pyegeria/md_processing_helpers.py,sha256=sV-ciVg_xOGVGTH_CMpH2B5k3V5jzdFp_XvnQQ5xafw,2131
232
- pyegeria/md_processing_utils.py,sha256=KCw9XXVX2sgqz7th47FlsDJ3yapKvYaSCJlWJ8ATJJs,67988
232
+ pyegeria/md_processing_utils.py,sha256=lxul-3ryNv3xx86j6ov84eEbgO43KndDr6Sl4CV2QxY,68441
233
233
  pyegeria/md_processing_utils_orig.py,sha256=WGoVpsV03wwgv9YwDDHZ0EO4-opN8BdoISt4ZhkYGuQ,52492
234
234
  pyegeria/mermaid_utilities.py,sha256=sQqdFUWdNpHu9d3Tk9UVe80M-5bOzses0XcFYX5FF-E,54254
235
235
  pyegeria/metadata_explorer_omvs.py,sha256=xHnZTQKbd6XwOhYia-RiIisrvZcqHi0SL1l6OCf04Gk,86911
@@ -245,8 +245,8 @@ pyegeria/template_manager_omvs.py,sha256=PfJ9dOfmBvf59DgRdZ9Dl1Kl_UYqjF-JncXVnbC
245
245
  pyegeria/utils.py,sha256=GCt1C0bp0Xng1ahzbZhzV9qQwH7Dj93IaCt2dvWb-sg,5417
246
246
  pyegeria/valid_metadata_omvs.py,sha256=Xq9DqBQvBFFJzaFIRKcVZ2k4gJvSh9yeXs_j-O3vn1w,65050
247
247
  pyegeria/x_action_author_omvs.py,sha256=RcqSzahUKCtvb_3u_wyintAlc9WFkC_2v0E12TZs8lQ,6433
248
- pyegeria-5.3.8.0.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
249
- pyegeria-5.3.8.0.dist-info/METADATA,sha256=m-1X-9AiILczZLSPTt0QBg3cz9ffUjPpw0PSC6H6U0g,2740
250
- pyegeria-5.3.8.0.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
251
- pyegeria-5.3.8.0.dist-info/entry_points.txt,sha256=eAvQ_vkejlF3JzMzEc5VD93ymLA_hSFV0HM8fntG-d8,6791
252
- pyegeria-5.3.8.0.dist-info/RECORD,,
248
+ pyegeria-5.3.8.2.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
249
+ pyegeria-5.3.8.2.dist-info/METADATA,sha256=WqXNrVeFnKJPkc9WwF3R_MT4b_tfQKwHKgmYTwFI8XE,2740
250
+ pyegeria-5.3.8.2.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
251
+ pyegeria-5.3.8.2.dist-info/entry_points.txt,sha256=eAvQ_vkejlF3JzMzEc5VD93ymLA_hSFV0HM8fntG-d8,6791
252
+ pyegeria-5.3.8.2.dist-info/RECORD,,