pyegeria 5.3.7__py3-none-any.whl → 5.3.7.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.
- pyegeria/commands/cat/dr_egeria_md.py +2 -2
 - pyegeria/md_processing_utils.py +13 -4
 - {pyegeria-5.3.7.dist-info → pyegeria-5.3.7.2.dist-info}/METADATA +1 -1
 - {pyegeria-5.3.7.dist-info → pyegeria-5.3.7.2.dist-info}/RECORD +7 -7
 - {pyegeria-5.3.7.dist-info → pyegeria-5.3.7.2.dist-info}/LICENSE +0 -0
 - {pyegeria-5.3.7.dist-info → pyegeria-5.3.7.2.dist-info}/WHEEL +0 -0
 - {pyegeria-5.3.7.dist-info → pyegeria-5.3.7.2.dist-info}/entry_points.txt +0 -0
 
| 
         @@ -120,8 +120,8 @@ def process_markdown_file( 
     | 
|
| 
       120 
120 
     | 
    
         
             
                                updated = True
         
     | 
| 
       121 
121 
     | 
    
         
             
                                final_output.append(result)
         
     | 
| 
       122 
122 
     | 
    
         
             
                                # print(json.dumps(element_dictionary, indent=4))
         
     | 
| 
       123 
     | 
    
         
            -
                             
     | 
| 
       124 
     | 
    
         
            -
             
     | 
| 
      
 123 
     | 
    
         
            +
                            elif directive == "validate":
         
     | 
| 
      
 124 
     | 
    
         
            +
                                print(json.dumps(element_dictionary, indent=4))
         
     | 
| 
       125 
125 
     | 
    
         
             
                        elif directive == "process":
         
     | 
| 
       126 
126 
     | 
    
         
             
                            # Handle errors (skip this block but notify the user)
         
     | 
| 
       127 
127 
     | 
    
         
             
                            print(f"\n==>\tErrors found while processing command: \'{potential_command}\'\n"
         
     | 
    
        pyegeria/md_processing_utils.py
    CHANGED
    
    | 
         @@ -83,7 +83,7 @@ def extract_attribute(text: str, labels: List[str]) -> Optional[str]: 
     | 
|
| 
       83 
83 
     | 
    
         | 
| 
       84 
84 
     | 
    
         
             
                    Args:
         
     | 
| 
       85 
85 
     | 
    
         
             
                        text: The input string.
         
     | 
| 
       86 
     | 
    
         
            -
                         
     | 
| 
      
 86 
     | 
    
         
            +
                        labels: List of equivalent labels to search for
         
     | 
| 
       87 
87 
     | 
    
         | 
| 
       88 
88 
     | 
    
         
             
                    Returns:
         
     | 
| 
       89 
89 
     | 
    
         
             
                        The glossary name, or None if not found.
         
     | 
| 
         @@ -120,7 +120,7 @@ def update_a_command(txt: str, command: str, obj_type: str, q_name: str, u_guid: 
     | 
|
| 
       120 
120 
     | 
    
         
             
                #     replacement = r"\1\n\n\2"
         
     | 
| 
       121 
121 
     | 
    
         
             
                #     txt += re.sub(pattern, replacement, txt)
         
     | 
| 
       122 
122 
     | 
    
         | 
| 
       123 
     | 
    
         
            -
                status = extract_attribute(txt, "Status")
         
     | 
| 
      
 123 
     | 
    
         
            +
                status = extract_attribute(txt, ["Status"])
         
     | 
| 
       124 
124 
     | 
    
         
             
                if command in ["Create Term", "Update Term"] and status is None:
         
     | 
| 
       125 
125 
     | 
    
         
             
                    pattern = r"(## Status\s*\n)(.*?)(#)"
         
     | 
| 
       126 
126 
     | 
    
         
             
                    replacement = r"\1\n DRAFT\n\n\3"
         
     | 
| 
         @@ -499,7 +499,7 @@ def process_term_upsert_command(egeria_client: GlossaryManager, element_dictiona 
     | 
|
| 
       499 
499 
     | 
    
         
             
                print(Markdown(f"{pre_command} `{command}` for term: `\'{term_name}\'` with directive: `{directive}`"))
         
     | 
| 
       500 
500 
     | 
    
         | 
| 
       501 
501 
     | 
    
         
             
                def validate_term(obj_action: str) -> tuple[bool, bool, Optional[str], Optional[str]]:
         
     | 
| 
       502 
     | 
    
         
            -
                    nonlocal version, status, categories, categories_list, cats_exist, q_name
         
     | 
| 
      
 502 
     | 
    
         
            +
                    nonlocal version, status, categories, categories_list, cats_exist, q_name, glossary_qn
         
     | 
| 
       503 
503 
     | 
    
         
             
                    valid = True
         
     | 
| 
       504 
504 
     | 
    
         
             
                    msg = ""
         
     | 
| 
       505 
505 
     | 
    
         
             
                    known_term_guid = None
         
     | 
| 
         @@ -529,13 +529,22 @@ def process_term_upsert_command(egeria_client: GlossaryManager, element_dictiona 
     | 
|
| 
       529 
529 
     | 
    
         
             
                        msg += f"* {ERROR}Glossary qualified name is missing\n"
         
     | 
| 
       530 
530 
     | 
    
         
             
                        valid = False
         
     | 
| 
       531 
531 
     | 
    
         
             
                    else:
         
     | 
| 
      
 532 
     | 
    
         
            +
                        print(f"* {INFO}Glossary qualified name is `{glossary_qn}`")
         
     | 
| 
       532 
533 
     | 
    
         
             
                        if glossary_qn not in element_dictionary:
         
     | 
| 
       533 
534 
     | 
    
         
             
                            glossary = egeria_client.get_glossaries_by_name(glossary_qn) #assuming q_name?
         
     | 
| 
       534 
535 
     | 
    
         
             
                            if isinstance(glossary,str):
         
     | 
| 
       535 
536 
     | 
    
         
             
                                msg += f"* {ERROR}Glossary `{glossary_qn}` is unknown\n "
         
     | 
| 
       536 
537 
     | 
    
         
             
                                valid = False
         
     | 
| 
      
 538 
     | 
    
         
            +
                            elif len(glossary) != 1:
         
     | 
| 
      
 539 
     | 
    
         
            +
                                msg += f"* {ERROR}Glossary `{glossary_qn}` is ambiguous or not found\n "
         
     | 
| 
      
 540 
     | 
    
         
            +
                                valid = False
         
     | 
| 
       537 
541 
     | 
    
         
             
                            else:
         
     | 
| 
       538 
     | 
    
         
            -
                                 
     | 
| 
      
 542 
     | 
    
         
            +
                                glossary_qn = glossary[0]['glossaryProperties'].get('qualifiedName', None)
         
     | 
| 
      
 543 
     | 
    
         
            +
                                if glossary_qn is None:
         
     | 
| 
      
 544 
     | 
    
         
            +
                                    msg += f"* {ERROR}Glossary `{glossary_qn}` has no qualifiedName\n "
         
     | 
| 
      
 545 
     | 
    
         
            +
                                    valid = False
         
     | 
| 
      
 546 
     | 
    
         
            +
                                else:
         
     | 
| 
      
 547 
     | 
    
         
            +
                                    element_dictionary[glossary_qn] = {
         
     | 
| 
       539 
548 
     | 
    
         
             
                                    'guid': glossary[0]['elementHeader'].get('guid', None),
         
     | 
| 
       540 
549 
     | 
    
         
             
                                    'display_name': glossary[0]['glossaryProperties'].get('displayName', None)
         
     | 
| 
       541 
550 
     | 
    
         
             
                                    }
         
     | 
| 
         @@ -17,7 +17,7 @@ pyegeria/commands/cat/__init__.py,sha256=5OCy4m_yZsnSxdy_gvkCyP_OkjvuWKimqUGHYCJ 
     | 
|
| 
       17 
17 
     | 
    
         
             
            pyegeria/commands/cat/dr_egeria_inbox/glossary_creation_experiment.ipynb,sha256=dbzNu90fCKNohOWVSRBOB1GLyd95x8Qw51I5AkaPtso,11552
         
     | 
| 
       18 
18 
     | 
    
         
             
            pyegeria/commands/cat/dr_egeria_inbox/glossary_exp.md,sha256=KsUeTzDe5QkrTmIfIAXR74qZ29oSfRW-NAEn0RYIRqM,2534
         
     | 
| 
       19 
19 
     | 
    
         
             
            pyegeria/commands/cat/dr_egeria_jupyter.py,sha256=U-3m9BMoCXj2fvuawr3PTc2HQWAXThqQ3sIXjyCWv6s,5912
         
     | 
| 
       20 
     | 
    
         
            -
            pyegeria/commands/cat/dr_egeria_md.py,sha256= 
     | 
| 
      
 20 
     | 
    
         
            +
            pyegeria/commands/cat/dr_egeria_md.py,sha256=oOuqANna_6-yLgcOjv9PeazAWaK7x7sUyWE2yu9O90E,9519
         
     | 
| 
       21 
21 
     | 
    
         
             
            pyegeria/commands/cat/exp_list_glossaries.py,sha256=dC6Bnfm3YSMTKPP146qeslIFRiZnGu5b7iDYE07p4iU,5817
         
     | 
| 
       22 
22 
     | 
    
         
             
            pyegeria/commands/cat/get_asset_graph.py,sha256=xnXJfpDTVH1TJ2TwE3dtjaXU36Di6-N6JAyhothzz2o,12461
         
     | 
| 
       23 
23 
     | 
    
         
             
            pyegeria/commands/cat/get_collection.py,sha256=kXPcP8u-SMWfrVyyBhNoxG8mcgB7EV_5i9N9w_IBU7o,5379
         
     | 
| 
         @@ -228,7 +228,7 @@ pyegeria/full_omag_server_config.py,sha256=CQqLCy_3DZFvJZEOcGf50HWdFaWpiAIs6z-kK 
     | 
|
| 
       228 
228 
     | 
    
         
             
            pyegeria/glossary_browser_omvs.py,sha256=NHcLStpzejiT3BinIpm4FmYKPiVcBKSvp2ihZfNwTik,109579
         
     | 
| 
       229 
229 
     | 
    
         
             
            pyegeria/glossary_manager_omvs.py,sha256=QSOVqbwEASueCQzpvYNEOaUIAhOvwqLWWhfzwT8hrrs,70275
         
     | 
| 
       230 
230 
     | 
    
         
             
            pyegeria/m_test.py,sha256=M5-M2ZczsAJLXWfSeqTTADHdx6Ku-y4PbQ4M21JthAE,7778
         
     | 
| 
       231 
     | 
    
         
            -
            pyegeria/md_processing_utils.py,sha256= 
     | 
| 
      
 231 
     | 
    
         
            +
            pyegeria/md_processing_utils.py,sha256=OLgFfofi6rau9YxoubQlJXF3jg-mKwvkMzQ2iEaN7GA,43260
         
     | 
| 
       232 
232 
     | 
    
         
             
            pyegeria/mermaid_utilities.py,sha256=sQqdFUWdNpHu9d3Tk9UVe80M-5bOzses0XcFYX5FF-E,54254
         
     | 
| 
       233 
233 
     | 
    
         
             
            pyegeria/metadata_explorer_omvs.py,sha256=xHnZTQKbd6XwOhYia-RiIisrvZcqHi0SL1l6OCf04Gk,86911
         
     | 
| 
       234 
234 
     | 
    
         
             
            pyegeria/my_profile_omvs.py,sha256=d0oJYCJG7pS9BINPuGciVa00ac0jwPHNANXDCLginEc,34720
         
     | 
| 
         @@ -242,8 +242,8 @@ pyegeria/template_manager_omvs.py,sha256=PfJ9dOfmBvf59DgRdZ9Dl1Kl_UYqjF-JncXVnbC 
     | 
|
| 
       242 
242 
     | 
    
         
             
            pyegeria/utils.py,sha256=GCt1C0bp0Xng1ahzbZhzV9qQwH7Dj93IaCt2dvWb-sg,5417
         
     | 
| 
       243 
243 
     | 
    
         
             
            pyegeria/valid_metadata_omvs.py,sha256=Xq9DqBQvBFFJzaFIRKcVZ2k4gJvSh9yeXs_j-O3vn1w,65050
         
     | 
| 
       244 
244 
     | 
    
         
             
            pyegeria/x_action_author_omvs.py,sha256=RcqSzahUKCtvb_3u_wyintAlc9WFkC_2v0E12TZs8lQ,6433
         
     | 
| 
       245 
     | 
    
         
            -
            pyegeria-5.3.7.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
         
     | 
| 
       246 
     | 
    
         
            -
            pyegeria-5.3.7.dist-info/METADATA,sha256= 
     | 
| 
       247 
     | 
    
         
            -
            pyegeria-5.3.7.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
         
     | 
| 
       248 
     | 
    
         
            -
            pyegeria-5.3.7.dist-info/entry_points.txt,sha256=eAvQ_vkejlF3JzMzEc5VD93ymLA_hSFV0HM8fntG-d8,6791
         
     | 
| 
       249 
     | 
    
         
            -
            pyegeria-5.3.7.dist-info/RECORD,,
         
     | 
| 
      
 245 
     | 
    
         
            +
            pyegeria-5.3.7.2.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
         
     | 
| 
      
 246 
     | 
    
         
            +
            pyegeria-5.3.7.2.dist-info/METADATA,sha256=DYNv6UTcNgXP8koftmZ1iAQcOS2aI0Mg_-GcltcyEoE,2743
         
     | 
| 
      
 247 
     | 
    
         
            +
            pyegeria-5.3.7.2.dist-info/WHEEL,sha256=XbeZDeTWKc1w7CSIyre5aMDU_-PohRwTQceYnisIYYY,88
         
     | 
| 
      
 248 
     | 
    
         
            +
            pyegeria-5.3.7.2.dist-info/entry_points.txt,sha256=eAvQ_vkejlF3JzMzEc5VD93ymLA_hSFV0HM8fntG-d8,6791
         
     | 
| 
      
 249 
     | 
    
         
            +
            pyegeria-5.3.7.2.dist-info/RECORD,,
         
     | 
| 
         
            File without changes
         
     | 
| 
         
            File without changes
         
     | 
| 
         
            File without changes
         
     |