pyegeria 5.3.9.9.3__py3-none-any.whl → 5.5.3.3__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 pyegeria might be problematic. Click here for more details.

Files changed (272) hide show
  1. commands/__init__.py +24 -0
  2. commands/cat/Dr-Egeria_md-orig.py +2 -2
  3. commands/cat/__init__.py +1 -17
  4. commands/cat/collection_actions.py +197 -0
  5. commands/cat/dr_egeria_command_help.py +372 -0
  6. commands/cat/dr_egeria_jupyter.py +7 -7
  7. commands/cat/dr_egeria_md.py +27 -182
  8. commands/cat/exp_list_glossaries.py +11 -14
  9. commands/cat/get_asset_graph.py +37 -267
  10. commands/cat/{get_collection.py → get_collection_tree.py} +10 -18
  11. commands/cat/get_project_dependencies.py +14 -14
  12. commands/cat/get_project_structure.py +15 -14
  13. commands/cat/get_tech_type_elements.py +16 -116
  14. commands/cat/glossary_actions.py +145 -298
  15. commands/cat/list_assets.py +3 -11
  16. commands/cat/list_cert_types.py +17 -63
  17. commands/cat/list_collections.py +46 -138
  18. commands/cat/list_deployed_catalogs.py +15 -27
  19. commands/cat/list_deployed_database_schemas.py +27 -43
  20. commands/cat/list_deployed_databases.py +16 -31
  21. commands/cat/list_deployed_servers.py +35 -54
  22. commands/cat/list_glossaries.py +18 -17
  23. commands/cat/list_projects.py +10 -12
  24. commands/cat/list_tech_type_elements.py +21 -37
  25. commands/cat/list_tech_types.py +13 -25
  26. commands/cat/list_terms.py +38 -79
  27. commands/cat/list_todos.py +4 -11
  28. commands/cat/list_user_ids.py +3 -10
  29. commands/cat/my_reports.py +559 -0
  30. commands/cat/run_report.py +394 -0
  31. commands/cat/run_report_orig.py +528 -0
  32. commands/cli/egeria.py +222 -247
  33. commands/cli/egeria_cat.py +68 -81
  34. commands/cli/egeria_my.py +13 -0
  35. commands/cli/egeria_ops.py +69 -74
  36. commands/cli/egeria_tech.py +17 -93
  37. commands/cli/ops_config.py +3 -6
  38. commands/{cat/list_categories.py → deprecated/list_data_designer.py} +53 -64
  39. commands/{cat/list_data_structures.py → deprecated/list_data_structures_full.py} +3 -6
  40. commands/deprecated/old_get_asset_graph.py +315 -0
  41. commands/my/__init__.py +0 -2
  42. commands/my/list_my_profile.py +27 -34
  43. commands/my/list_my_roles.py +1 -7
  44. commands/my/monitor_my_todos.py +1 -7
  45. commands/my/monitor_open_todos.py +6 -7
  46. commands/my/todo_actions.py +4 -5
  47. commands/ops/__init__.py +0 -2
  48. commands/ops/gov_server_actions.py +17 -21
  49. commands/ops/list_archives.py +17 -38
  50. commands/ops/list_catalog_targets.py +33 -40
  51. commands/ops/load_archive.py +35 -26
  52. commands/ops/{monitor_engine_activity_c.py → monitor_active_engine_activity.py} +51 -82
  53. commands/ops/{monitor_integ_daemon_status.py → monitor_daemon_status.py} +35 -55
  54. commands/ops/monitor_engine_activity.py +79 -77
  55. commands/ops/{monitor_gov_eng_status.py → monitor_engine_status.py} +10 -7
  56. commands/ops/monitor_platform_status.py +38 -50
  57. commands/ops/monitor_server_startup.py +6 -11
  58. commands/ops/monitor_server_status.py +7 -11
  59. commands/ops/orig_monitor_server_list.py +8 -8
  60. commands/ops/orig_monitor_server_status.py +1 -5
  61. commands/ops/refresh_integration_daemon.py +5 -5
  62. commands/ops/restart_integration_daemon.py +5 -5
  63. commands/ops/table_integ_daemon_status.py +6 -6
  64. commands/ops/x_engine_actions.py +7 -7
  65. commands/tech/__init__.py +0 -2
  66. commands/tech/{generic_actions.py → element_actions.py} +6 -11
  67. commands/tech/get_element_info.py +20 -29
  68. commands/tech/get_guid_info.py +23 -42
  69. commands/tech/get_tech_details.py +20 -35
  70. commands/tech/get_tech_type_template.py +28 -39
  71. commands/tech/list_all_om_type_elements.py +24 -30
  72. commands/tech/list_all_om_type_elements_x.py +22 -28
  73. commands/tech/list_all_related_elements.py +19 -28
  74. commands/tech/list_anchored_elements.py +22 -30
  75. commands/tech/list_asset_types.py +19 -24
  76. commands/tech/list_elements_by_classification_by_property_value.py +26 -32
  77. commands/tech/list_elements_by_property_value.py +19 -25
  78. commands/tech/list_elements_by_property_value_x.py +20 -28
  79. commands/tech/list_elements_for_classification.py +28 -41
  80. commands/tech/list_gov_action_processes.py +16 -27
  81. commands/tech/list_information_supply_chains.py +22 -30
  82. commands/tech/list_registered_services.py +14 -26
  83. commands/tech/list_related_elements_with_prop_value.py +15 -25
  84. commands/tech/list_related_specification.py +1 -4
  85. commands/tech/list_relationship_types.py +15 -25
  86. commands/tech/list_relationships.py +20 -36
  87. commands/tech/list_solution_blueprints.py +28 -33
  88. commands/tech/list_solution_components.py +23 -29
  89. commands/tech/list_solution_roles.py +21 -32
  90. commands/tech/list_tech_templates.py +51 -54
  91. commands/tech/list_valid_metadata_values.py +5 -9
  92. commands/tech/table_tech_templates.py +2 -6
  93. commands/tech/x_list_related_elements.py +1 -4
  94. examples/GeoSpatial Products Example.py +524 -0
  95. examples/Jupyter Notebooks/P-egeria-server-config.ipynb +2137 -0
  96. examples/Jupyter Notebooks/README.md +2 -0
  97. examples/Jupyter Notebooks/common/P-environment-check.ipynb +115 -0
  98. examples/Jupyter Notebooks/common/__init__.py +14 -0
  99. examples/Jupyter Notebooks/common/common-functions.ipynb +4694 -0
  100. examples/Jupyter Notebooks/common/environment-check.ipynb +52 -0
  101. examples/Jupyter Notebooks/common/globals.ipynb +184 -0
  102. examples/Jupyter Notebooks/common/globals.py +154 -0
  103. examples/Jupyter Notebooks/common/orig_globals.py +152 -0
  104. examples/format_sets/all_format_sets.json +910 -0
  105. examples/format_sets/custom_format_sets.json +268 -0
  106. examples/format_sets/subset_format_sets.json +187 -0
  107. examples/format_sets_save_load_example.py +291 -0
  108. examples/jacquard_data_sets.py +129 -0
  109. examples/output_formats_example.py +193 -0
  110. examples/test_jacquard_data_sets.py +54 -0
  111. examples/test_jacquard_data_sets_scenarios.py +94 -0
  112. md_processing/__init__.py +90 -0
  113. md_processing/command_dispatcher.py +33 -0
  114. md_processing/command_mapping.py +221 -0
  115. md_processing/data/commands/commands_data_designer.json +537 -0
  116. md_processing/data/commands/commands_external_reference.json +733 -0
  117. md_processing/data/commands/commands_feedback.json +155 -0
  118. md_processing/data/commands/commands_general.json +204 -0
  119. md_processing/data/commands/commands_glossary.json +218 -0
  120. md_processing/data/commands/commands_governance.json +3678 -0
  121. md_processing/data/commands/commands_product_manager.json +865 -0
  122. md_processing/data/commands/commands_project.json +642 -0
  123. md_processing/data/commands/commands_solution_architect.json +366 -0
  124. md_processing/data/commands.json +17568 -0
  125. md_processing/data/commands_working.json +30641 -0
  126. md_processing/data/gened_report_specs.py +6584 -0
  127. md_processing/data/generated_format_sets.json +6533 -0
  128. md_processing/data/generated_format_sets_old.json +4137 -0
  129. md_processing/data/generated_format_sets_old.py +45 -0
  130. md_processing/dr_egeria.py +182 -0
  131. md_processing/md_commands/__init__.py +3 -0
  132. md_processing/md_commands/data_designer_commands.py +1276 -0
  133. md_processing/md_commands/ext_ref_commands.py +530 -0
  134. md_processing/md_commands/feedback_commands.py +726 -0
  135. md_processing/md_commands/glossary_commands.py +684 -0
  136. md_processing/md_commands/governance_officer_commands.py +600 -0
  137. md_processing/md_commands/product_manager_commands.py +1266 -0
  138. md_processing/md_commands/project_commands.py +383 -0
  139. md_processing/md_commands/solution_architect_commands.py +1184 -0
  140. md_processing/md_commands/view_commands.py +295 -0
  141. md_processing/md_processing_utils/__init__.py +4 -0
  142. md_processing/md_processing_utils/common_md_proc_utils.py +1249 -0
  143. md_processing/md_processing_utils/common_md_utils.py +578 -0
  144. md_processing/md_processing_utils/determine_width.py +103 -0
  145. md_processing/md_processing_utils/extraction_utils.py +547 -0
  146. md_processing/md_processing_utils/gen_report_specs.py +643 -0
  147. md_processing/md_processing_utils/generate_dr_help.py +193 -0
  148. md_processing/md_processing_utils/generate_md_cmd_templates.py +144 -0
  149. md_processing/md_processing_utils/generate_md_templates.py +83 -0
  150. md_processing/md_processing_utils/md_processing_constants.py +1228 -0
  151. md_processing/md_processing_utils/message_constants.py +19 -0
  152. pyegeria/__init__.py +201 -443
  153. pyegeria/core/__init__.py +40 -0
  154. pyegeria/core/_base_platform_client.py +574 -0
  155. pyegeria/core/_base_server_client.py +573 -0
  156. pyegeria/core/_exceptions.py +457 -0
  157. pyegeria/core/_globals.py +60 -0
  158. pyegeria/core/_server_client.py +6073 -0
  159. pyegeria/core/_validators.py +257 -0
  160. pyegeria/core/config.py +654 -0
  161. pyegeria/{create_tech_guid_lists.py → core/create_tech_guid_lists.py} +0 -1
  162. pyegeria/core/load_config.py +37 -0
  163. pyegeria/core/logging_configuration.py +207 -0
  164. pyegeria/core/mcp_adapter.py +144 -0
  165. pyegeria/core/mcp_server.py +212 -0
  166. pyegeria/core/utils.py +405 -0
  167. pyegeria/deprecated/__init__.py +0 -0
  168. pyegeria/{_client.py → deprecated/_client.py} +62 -24
  169. pyegeria/{_deprecated_gov_engine.py → deprecated/_deprecated_gov_engine.py} +16 -16
  170. pyegeria/{classification_manager_omvs.py → deprecated/classification_manager_omvs.py} +1988 -1878
  171. pyegeria/deprecated/output_formatter_with_machine_keys.py +1127 -0
  172. pyegeria/{runtime_manager_omvs.py → deprecated/runtime_manager_omvs.py} +216 -229
  173. pyegeria/{valid_metadata_omvs.py → deprecated/valid_metadata_omvs.py} +93 -93
  174. pyegeria/{x_action_author_omvs.py → deprecated/x_action_author_omvs.py} +2 -3
  175. pyegeria/egeria_cat_client.py +25 -51
  176. pyegeria/egeria_client.py +140 -98
  177. pyegeria/egeria_config_client.py +48 -24
  178. pyegeria/egeria_tech_client.py +170 -83
  179. pyegeria/models/__init__.py +150 -0
  180. pyegeria/models/collection_models.py +168 -0
  181. pyegeria/models/models.py +654 -0
  182. pyegeria/omvs/__init__.py +84 -0
  183. pyegeria/omvs/action_author.py +342 -0
  184. pyegeria/omvs/actor_manager.py +5980 -0
  185. pyegeria/omvs/asset_catalog.py +842 -0
  186. pyegeria/omvs/asset_maker.py +2736 -0
  187. pyegeria/omvs/automated_curation.py +4403 -0
  188. pyegeria/omvs/classification_manager.py +11213 -0
  189. pyegeria/omvs/collection_manager.py +5780 -0
  190. pyegeria/omvs/community_matters_omvs.py +468 -0
  191. pyegeria/{core_omag_server_config.py → omvs/core_omag_server_config.py} +157 -157
  192. pyegeria/{data_designer_omvs.py → omvs/data_designer.py} +1991 -1691
  193. pyegeria/omvs/data_discovery.py +869 -0
  194. pyegeria/omvs/data_engineer.py +372 -0
  195. pyegeria/omvs/digital_business.py +1133 -0
  196. pyegeria/omvs/external_links.py +1752 -0
  197. pyegeria/omvs/feedback_manager.py +834 -0
  198. pyegeria/{full_omag_server_config.py → omvs/full_omag_server_config.py} +73 -69
  199. pyegeria/omvs/glossary_manager.py +3231 -0
  200. pyegeria/omvs/governance_officer.py +3009 -0
  201. pyegeria/omvs/lineage_linker.py +314 -0
  202. pyegeria/omvs/location_arena.py +1525 -0
  203. pyegeria/omvs/metadata_expert.py +668 -0
  204. pyegeria/omvs/metadata_explorer_omvs.py +2943 -0
  205. pyegeria/omvs/my_profile.py +1042 -0
  206. pyegeria/omvs/notification_manager.py +358 -0
  207. pyegeria/omvs/people_organizer.py +394 -0
  208. pyegeria/{platform_services.py → omvs/platform_services.py} +113 -193
  209. pyegeria/omvs/product_manager.py +1825 -0
  210. pyegeria/omvs/project_manager.py +1907 -0
  211. pyegeria/omvs/reference_data.py +1140 -0
  212. pyegeria/omvs/registered_info.py +334 -0
  213. pyegeria/omvs/runtime_manager.py +2817 -0
  214. pyegeria/omvs/schema_maker.py +446 -0
  215. pyegeria/{server_operations.py → omvs/server_operations.py} +27 -26
  216. pyegeria/omvs/solution_architect.py +6490 -0
  217. pyegeria/omvs/specification_properties.py +37 -0
  218. pyegeria/omvs/subject_area.py +1042 -0
  219. pyegeria/omvs/template_manager_omvs.py +236 -0
  220. pyegeria/omvs/time_keeper.py +1761 -0
  221. pyegeria/omvs/valid_metadata.py +3221 -0
  222. pyegeria/omvs/valid_metadata_lists.py +37 -0
  223. pyegeria/omvs/valid_type_lists.py +37 -0
  224. pyegeria/view/__init__.py +28 -0
  225. pyegeria/view/_output_format_models.py +514 -0
  226. pyegeria/view/_output_formats.py +14 -0
  227. pyegeria/view/base_report_formats.py +2719 -0
  228. pyegeria/view/dr_egeria_reports.py +56 -0
  229. pyegeria/view/format_set_executor.py +397 -0
  230. pyegeria/{md_processing_utils.py → view/md_processing_utils.py} +5 -5
  231. pyegeria/{mermaid_utilities.py → view/mermaid_utilities.py} +2 -154
  232. pyegeria/view/output_formatter.py +1297 -0
  233. pyegeria-5.5.3.3.dist-info/METADATA +218 -0
  234. pyegeria-5.5.3.3.dist-info/RECORD +241 -0
  235. {pyegeria-5.3.9.9.3.dist-info → pyegeria-5.5.3.3.dist-info}/WHEEL +2 -1
  236. pyegeria-5.5.3.3.dist-info/entry_points.txt +103 -0
  237. pyegeria-5.5.3.3.dist-info/top_level.txt +4 -0
  238. commands/cat/.DS_Store +0 -0
  239. commands/cat/README.md +0 -16
  240. commands/cli/txt_custom_v2.tcss +0 -19
  241. commands/my/README.md +0 -17
  242. commands/ops/README.md +0 -24
  243. commands/ops/monitor_asset_events.py +0 -108
  244. commands/tech/README.md +0 -24
  245. pyegeria/.DS_Store +0 -0
  246. pyegeria/README.md +0 -35
  247. pyegeria/_globals.py +0 -47
  248. pyegeria/_validators.py +0 -385
  249. pyegeria/asset_catalog_omvs.py +0 -864
  250. pyegeria/automated_curation_omvs.py +0 -3765
  251. pyegeria/collection_manager_omvs.py +0 -2744
  252. pyegeria/dr.egeria spec.md +0 -9
  253. pyegeria/egeria_my_client.py +0 -56
  254. pyegeria/feedback_manager_omvs.py +0 -4573
  255. pyegeria/glossary_browser_omvs.py +0 -3728
  256. pyegeria/glossary_manager_omvs.py +0 -2440
  257. pyegeria/m_test.py +0 -118
  258. pyegeria/md_processing_helpers.py +0 -58
  259. pyegeria/md_processing_utils_orig.py +0 -1103
  260. pyegeria/metadata_explorer_omvs.py +0 -2326
  261. pyegeria/my_profile_omvs.py +0 -1022
  262. pyegeria/output_formatter.py +0 -389
  263. pyegeria/project_manager_omvs.py +0 -1933
  264. pyegeria/registered_info.py +0 -167
  265. pyegeria/solution_architect_omvs.py +0 -2156
  266. pyegeria/template_manager_omvs.py +0 -1414
  267. pyegeria/utils.py +0 -197
  268. pyegeria-5.3.9.9.3.dist-info/METADATA +0 -72
  269. pyegeria-5.3.9.9.3.dist-info/RECORD +0 -143
  270. pyegeria-5.3.9.9.3.dist-info/entry_points.txt +0 -99
  271. /pyegeria/{_exceptions.py → deprecated/_exceptions.py} +0 -0
  272. {pyegeria-5.3.9.9.3.dist-info → pyegeria-5.5.3.3.dist-info/licenses}/LICENSE +0 -0
@@ -1,1022 +0,0 @@
1
- """
2
-
3
- This module contains the MyProfile class and its methods.
4
-
5
- """
6
-
7
- import asyncio
8
- import json
9
-
10
- from pyegeria.utils import body_slimmer
11
- from pyegeria._client import Client
12
- from pyegeria._validators import validate_name, validate_search_string
13
- from pyegeria._globals import NO_ELEMENTS_FOUND
14
-
15
- class MyProfile(Client):
16
- """A class representing the profile of a user.
17
-
18
- This class provides methods for retrieving the profile details
19
- of a user associated with a token.
20
-
21
- Parameters
22
- ----------
23
- view_server : str
24
- The name of the view server to configure.
25
- platform_url : str
26
- The URL of the platform.
27
- token : str, optional
28
- The token associated with the user. Default is None.
29
- user_id : str, optional
30
- The user ID. Default is None.
31
- user_pwd : str, optional
32
- The user password. Default is None.
33
-
34
- """
35
-
36
- def __init__(
37
- self,
38
- view_server: str,
39
- platform_url: str,
40
- user_id: str = None,
41
- user_pwd: str = None,
42
- token: str = None,
43
- ):
44
- Client.__init__(
45
- self,
46
- view_server,
47
- platform_url,
48
- user_id=user_id,
49
- user_pwd=user_pwd,
50
- token=token,
51
- )
52
- self.view_server = view_server
53
- self.platform_url = platform_url
54
- self.user_id = user_id
55
- self.user_pwd = user_pwd
56
-
57
- self.my_profile_command_root: str = f"{platform_url}/servers"
58
-
59
- #
60
- # MyProfile
61
- #
62
-
63
- async def _async_get_my_profile(self) -> dict | str:
64
- """Get the profile of the user associated with the token used.
65
-
66
- Parameters
67
- ----------
68
-
69
- Returns
70
- -------
71
- List | str
72
-
73
- Profile details as a dict.
74
-
75
- Raises
76
- ------
77
-
78
- InvalidParameterException
79
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
80
- PropertyServerException
81
- Raised by the server when an issue arises in processing a valid request
82
- NotAuthorizedException
83
- The principle specified by the user_id does not have authorization for the requested action
84
- """
85
-
86
- url = f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile"
87
-
88
- response = await self._async_make_request("GET", url)
89
- return response
90
-
91
- def get_my_profile(self) -> dict | str:
92
- """Get the profile of the user associated with the token used.
93
-
94
- Parameters
95
- ----------
96
-
97
-
98
- Returns
99
- -------
100
- List | str
101
-
102
- Profile details as a dict.
103
-
104
- Raises
105
- ------
106
-
107
- InvalidParameterException
108
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
109
- PropertyServerException
110
- Raised by the server when an issue arises in processing a valid request
111
- NotAuthorizedException
112
- The principle specified by the user_id does not have authorization for the requested action
113
- """
114
- loop = asyncio.get_event_loop()
115
- response = loop.run_until_complete(self._async_get_my_profile())
116
-
117
- return response.json().get("personalProfile", "No one found")
118
-
119
- async def _async_get_assigned_actions(
120
- self,
121
- actor_guid: str,
122
- status: str = "OPEN",
123
- start_from: int = 0,
124
- page_size: int = 100,
125
- ) -> list | str:
126
- """Get assigned actions for the actor. Async version.
127
-
128
- Parameters
129
- ----------
130
- actor_guid: str
131
- The GUID of the actor whose assigned actions are to be retrieved.
132
- status: str
133
- The status of teh action to filter on. Default value is "OPEN".
134
-
135
- start_from: int, optional
136
- The index from which to start retrieving the assigned actions. Default is 0.
137
- page_size: int, optional
138
- The number of assigned actions to retrieve per page. Default is 100.
139
-
140
- Returns
141
- -------
142
- list or str
143
- A list of assigned actions is returned. If there aren't any, a string is returned indicating that.
144
-
145
- Raises
146
- ------
147
- InvalidParameterException
148
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
149
- PropertyServerException
150
- Raised by the server when an issue arises in processing a valid request
151
- NotAuthorizedException
152
- The principle specified by the user_id does not have authorization for the requested action
153
- """
154
-
155
- if page_size is None:
156
- page_size = self.page_size
157
-
158
- body = {"status": status}
159
-
160
- url = (
161
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/actors/{actor_guid}"
162
- f"/assigned/to-dos?startFrom={start_from}&pageSize={page_size}&"
163
- )
164
-
165
- response = await self._async_make_request("POST", url, body)
166
-
167
- return response.json().get("elements", "No entries found")
168
-
169
- def get_assigned_actions(
170
- self,
171
- actor_guid: str,
172
- status: str = "OPEN",
173
- start_from: int = 0,
174
- page_size: int = 100,
175
- ) -> list | str:
176
- """Get assigned actions for the actor.
177
- Parameters
178
- ----------
179
- actor_guid: str
180
- The GUID of the actor whose assigned actions are to be retrieved.
181
- status: str
182
- The status of teh action to filter on. Default value is "OPEN".
183
-
184
- start_from: int, optional
185
- The index from which to start retrieving the assigned actions. Default is 0.
186
- page_size: int, optional
187
- The number of assigned actions to retrieve per page. Default is 100.
188
-
189
- Returns
190
- -------
191
- list or str
192
- A list of assigned actions is returned. If there aren't any, a string is returned indicating that.
193
-
194
- Raises
195
- ------
196
- InvalidParameterException
197
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
198
- PropertyServerException
199
- Raised by the server when an issue arises in processing a valid request
200
- NotAuthorizedException
201
- The principle specified by the user_id does not have authorization for the requested action
202
- """
203
- loop = asyncio.get_event_loop()
204
- response = loop.run_until_complete(
205
- self._async_get_assigned_actions(actor_guid, status, start_from, page_size)
206
- )
207
-
208
- return response
209
-
210
- async def _async_get_actions_for_action_target(
211
- self,
212
- element_guid: str,
213
- status: str = "OPEN",
214
- start_from: int = 0,
215
- page_size: int = 100,
216
- ) -> list | str:
217
- """Get actions assigned to the action target. Async version.
218
-
219
- Parameters
220
- ----------
221
- element_guid: str
222
- The GUID of the target whose assigned actions are to be retrieved.
223
- status: str
224
- The status of teh action to filter on. Default value is "OPEN".
225
-
226
- start_from: int, optional
227
- The index from which to start retrieving the assigned actions. Default is 0.
228
- page_size: int, optional
229
- The number of assigned actions to retrieve per page. Default is 100.
230
-
231
- Returns
232
- -------
233
- list or str
234
- A list of assigned actions is returned. If there aren't any, a string is returned indicating that.
235
-
236
- Raises
237
- ------
238
- InvalidParameterException
239
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
240
- PropertyServerException
241
- Raised by the server when an issue arises in processing a valid request
242
- NotAuthorizedException
243
- The principle specified by the user_id does not have authorization for the requested action
244
- """
245
-
246
- validate_name(element_guid)
247
-
248
- body = {"status": status}
249
-
250
- url = (
251
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/elements/{element_guid}"
252
- f"/action-targets/to-dos?start-from={start_from}&page-size={page_size}"
253
- )
254
-
255
- response = await self._async_make_request("POST", url, body)
256
- return response.json() if response is not None else "No Results"
257
-
258
- def get_actions_for_action_target(
259
- self,
260
- element_guid: str,
261
- status: str = "OPEN",
262
- start_from: int = 0,
263
- page_size: int = 100,
264
- ) -> list | str:
265
- """Get actions assigned to the action target.
266
-
267
- Parameters
268
- ----------
269
- element_guid: str
270
- The GUID of the target whose assigned actions are to be retrieved.
271
- status: str
272
- The status of teh action to filter on. Default value is "OPEN"
273
-
274
- start_from: int, optional
275
- The index from which to start retrieving the assigned actions. Default is 0.
276
- page_size: int, optional
277
- The number of assigned actions to retrieve per page. Default is 100.
278
-
279
- Returns
280
- -------
281
- list or str
282
- A list of assigned actions is returned. If there aren't any, a string is returned indicating that.
283
-
284
- Raises
285
- ------
286
- InvalidParameterException
287
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
288
- PropertyServerException
289
- Raised by the server when an issue arises in processing a valid request
290
- NotAuthorizedException
291
- The principle specified by the user_id does not have authorization for the requested action
292
- """
293
- loop = asyncio.get_event_loop()
294
- response = loop.run_until_complete(
295
- self._async_get_actions_for_action_target(
296
- element_guid, status, start_from, page_size
297
- )
298
- )
299
-
300
- return response
301
-
302
- async def _async_get_actions_for_sponsor(
303
- self,
304
- element_guid: str,
305
- status: str = "",
306
- start_from: int = 0,
307
- page_size: int = 100,
308
- ) -> list | str:
309
- """Get actions assigned to an owner. Async version.
310
-
311
- Parameters
312
- ----------
313
- element_guid: str
314
- The GUID of the target whose assigned actions are to be retrieved.
315
- status: str
316
- The status of the action to filter on. Default value is "OPEN".
317
-
318
- start_from: int, optional
319
- The index from which to start retrieving the assigned actions. Default is 0.
320
- page_size: int, optional
321
- The number of assigned actions to retrieve per page. Default is 100.
322
-
323
- Returns
324
- -------
325
- list or str
326
- A list of assigned actions is returned. If there aren't any, a string is returned indicating that.
327
-
328
- Raises
329
- ------
330
- InvalidParameterException
331
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
332
- PropertyServerException
333
- Raised by the server when an issue arises in processing a valid request
334
- NotAuthorizedException
335
- The principle specified by the user_id does not have authorization for the requested action
336
- """
337
-
338
- validate_name(element_guid)
339
-
340
- body = {"status": status}
341
-
342
- url = (
343
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/elements/{element_guid}"
344
- f"/sponsored/to-dos?startFrom={start_from}&pageSize={page_size}"
345
- )
346
-
347
- response = await self._async_make_request("POST", url, body)
348
- return response.json() if response is not None else "No Results"
349
-
350
- def get_actions_for_sponsor(
351
- self,
352
- element_guid: str,
353
- status: str = "OPEN",
354
- start_from: int = 0,
355
- page_size: int = 100,
356
- ) -> list | str:
357
- """Get actions assigned to an owner.
358
- Parameters
359
- ----------
360
- element_guid: str
361
- The GUID of the target whose assigned actions are to be retrieved.
362
- status: str
363
- The status of teh action to filter on. Default value is "OPEN".
364
-
365
- start_from: int, optional
366
- The index from which to start retrieving the assigned actions. Default is 0.
367
- page_size: int, optional
368
- The number of assigned actions to retrieve per page. Default is 100.
369
-
370
- Returns
371
- -------
372
- list or str
373
- A list of assigned actions is returned. If there aren't any, a string is returned indicating that.
374
-
375
- Raises
376
- ------
377
- InvalidParameterException
378
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
379
- PropertyServerException
380
- Raised by the server when an issue arises in processing a valid request
381
- NotAuthorizedException
382
- The principle specified by the user_id does not have authorization for the requested action
383
- """
384
- loop = asyncio.get_event_loop()
385
- response = loop.run_until_complete(
386
- self._async_get_actions_for_sponsor(
387
- element_guid, status, start_from, page_size
388
- )
389
- )
390
- return response
391
-
392
- async def _async_create_to_do(self, body: dict) -> str:
393
- """Create a To-Do item. Async version.
394
- Parameters
395
- ----------
396
- body : dict
397
- The dictionary containing the details of the to-do item.
398
-
399
-
400
- Returns
401
- -------
402
- None
403
- This method does not return any value.
404
-
405
- Raises
406
- ------
407
- InvalidParameterException
408
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
409
- PropertyServerException
410
- Raised by the server when an issue arises in processing a valid request
411
- NotAuthorizedException
412
- The principle specified by the user_id does not have authorization for the requested action
413
- """
414
-
415
- url = f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos"
416
- response = await self._async_make_request("POST", url, body)
417
- return response.json().get("guid", "No guid returned")
418
-
419
- def create_to_do(self, body: dict) -> str:
420
- """Create a To-Do item.
421
- Parameters
422
- ----------
423
- body : dict
424
- The dictionary containing the details of the to-do item.
425
-
426
- Returns
427
- -------
428
- None
429
- This method does not return any value.
430
-
431
- Raises
432
- ------
433
- InvalidParameterException
434
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
435
- PropertyServerException
436
- Raised by the server when an issue arises in processing a valid request
437
- NotAuthorizedException
438
- The principle specified by the user_id does not have authorization for the requested action
439
-
440
- Notes
441
- -----
442
-
443
- Here is a typical body:
444
- body = {
445
- "properties": {
446
- "class" : "ToDoProperties",
447
- "qualifiedName": f"Test-To-Do-{time.asctime()}",
448
- "name": to_do,
449
- "description": to_do_desc,
450
- "toDoType": to_do_type,
451
- "priority": 0,
452
- "dueTime": "2024-03-11T15:42:11.307Z",
453
- "status": "OPEN"
454
- },
455
- "assignToActorGUID": erins_guid
456
- }
457
- """
458
- loop = asyncio.get_event_loop()
459
- response = loop.run_until_complete(self._async_create_to_do(body))
460
- return response
461
-
462
- async def _async_get_to_do(self, todo_guid: str) -> dict | str:
463
- """Get a To-Do item. Async version.
464
- Parameters
465
- ----------
466
- todo_guid: str
467
- Identifier of the To-Do item.
468
-
469
-
470
- Returns
471
- -------
472
- None
473
- This method does not return any value.
474
-
475
- Raises
476
- ------
477
- InvalidParameterException
478
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
479
- PropertyServerException
480
- Raised by the server when an issue arises in processing a valid request
481
- NotAuthorizedException
482
- The principle specified by the user_id does not have authorization for the requested action
483
- """
484
-
485
- validate_name(todo_guid)
486
-
487
- url = f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos/{todo_guid}"
488
-
489
- response = await self._async_make_request("GET", url)
490
- # return response.text if response is not None else "No Results"
491
- return json.loads(response.text).get("elements", "No TODO returned")
492
-
493
- def get_to_do(self, todo_guid: str) -> dict | str:
494
- """Get a To-Do item. Async version.
495
- Parameters
496
- ----------
497
- todo_guid: str
498
- Identifier of the To-Do item.
499
-
500
-
501
- Returns
502
- -------
503
- None
504
- This method does not return any value.
505
-
506
- Raises
507
- ------
508
- InvalidParameterException
509
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
510
- PropertyServerException
511
- Raised by the server when an issue arises in processing a valid request
512
- NotAuthorizedException
513
- The principle specified by the user_id does not have authorization for the requested action
514
- """
515
- loop = asyncio.get_event_loop()
516
- response = loop.run_until_complete(self._async_get_to_do(todo_guid))
517
-
518
- return response
519
-
520
- async def _async_update_to_do(
521
- self,
522
- todo_guid: str,
523
- body: dict,
524
- is_merge_update: bool = True,
525
- ) -> None:
526
- """Update a To-Do item. Async version.
527
- Parameters
528
- ----------
529
- todo_guid: str
530
- Identifier of the To-Do item.
531
- body: str
532
- The details to update the to-do item with.
533
-
534
-
535
- Returns
536
- -------
537
- None
538
- This method does not return any value.
539
-
540
- Raises
541
- ------
542
- InvalidParameterException
543
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
544
- PropertyServerException
545
- Raised by the server when an issue arises in processing a valid request
546
- NotAuthorizedException
547
- The principle specified by the user_id does not have authorization for the requested action
548
- """
549
-
550
- is_merge_update_t = str(is_merge_update).lower()
551
-
552
- validate_name(todo_guid)
553
-
554
- url = (
555
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos/"
556
- f"{todo_guid}?isMergeUpdate={is_merge_update_t}"
557
- )
558
-
559
- await self._async_make_request("POST", url, body)
560
- return
561
-
562
- def update_to_do(
563
- self,
564
- todo_guid: str,
565
- body: dict,
566
- is_merge_update: bool = True,
567
- ) -> None:
568
- """Update a To-Do item.
569
- Parameters
570
- ----------
571
- todo_guid: str
572
- Identifier of the To-Do item.
573
- body: str
574
- The details to update the to-do item with.
575
- is_merge_update: bool [default: True]
576
- If true then merges the updated information, otherwise replace the existing information.
577
-
578
-
579
- Returns
580
- -------
581
- None
582
- This method does not return any value.
583
-
584
- Raises
585
- ------
586
- InvalidParameterException
587
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
588
- PropertyServerException
589
- Raised by the server when an issue arises in processing a valid request
590
- NotAuthorizedException
591
- The principle specified by the user_id does not have authorization for the requested action
592
- """
593
-
594
- loop = asyncio.get_event_loop()
595
- loop.run_until_complete(
596
- self._async_update_to_do(todo_guid, body, is_merge_update)
597
- )
598
- return
599
-
600
- async def _async_delete_to_do(self, todo_guid: str) -> None:
601
- """Delete a To-Do item. Async version.
602
- Parameters
603
- ----------
604
- todo_guid: str
605
- Identifier of the To-Do item.
606
-
607
-
608
- Returns
609
- -------
610
- None
611
- This method does not return any value.
612
-
613
- Raises
614
- ------
615
- InvalidParameterException
616
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
617
- PropertyServerException
618
- Raised by the server when an issue arises in processing a valid request
619
- NotAuthorizedException
620
- The principle specified by the user_id does not have authorization for the requested action
621
- """
622
-
623
- validate_name(todo_guid)
624
-
625
- url = f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos/{todo_guid}/delete"
626
-
627
- await self._async_make_request("POST", url)
628
- return
629
-
630
- def delete_to_do(self, todo_guid: str) -> None:
631
- """Delete a To-Do item.
632
- Parameters
633
- ----------
634
- todo_guid: str
635
- Identifier of the To-Do item.
636
-
637
-
638
- Returns
639
- -------
640
- None
641
- This method does not return any value.
642
-
643
- Raises
644
- ------
645
- InvalidParameterException
646
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
647
- PropertyServerException
648
- Raised by the server when an issue arises in processing a valid request
649
- NotAuthorizedException
650
- The principle specified by the user_id does not have authorization for the requested action
651
- """
652
- loop = asyncio.get_event_loop()
653
- loop.run_until_complete(self._async_delete_to_do(todo_guid))
654
- return
655
-
656
- async def _async_reassign_to_do(
657
- self,
658
- todo_guid: str,
659
- actor_guid: str,
660
- status: str = "OPEN",
661
- ) -> None:
662
- """Reassign a To-Do item. Async version.
663
- Parameters
664
- ----------
665
- todo_guid: str
666
- Identifier of the To-Do item.
667
- actor_guid: str
668
- The actor to receive the reassigned to-do item.
669
- status: str [default = "OPEN"]
670
- Filter items to match this status.
671
-
672
- Returns
673
- -------
674
- None
675
- This method does not return any value.
676
-
677
- Raises
678
- ------
679
- InvalidParameterException
680
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
681
- PropertyServerException
682
- Raised by the server when an issue arises in processing a valid request
683
- NotAuthorizedException
684
- The principle specified by the user_id does not have authorization for the requested action
685
- """
686
-
687
- validate_name(todo_guid)
688
- validate_name(actor_guid)
689
- body = {"status": status}
690
-
691
- url = (
692
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos/"
693
- f"{todo_guid}/reassign/{actor_guid}"
694
- )
695
-
696
- await self._async_make_request("POST", url, body)
697
- return
698
-
699
- def reassign_to_do(
700
- self,
701
- todo_guid: str,
702
- actor_guid: str,
703
- status: str = "OPEN",
704
- ) -> None:
705
- """Reassign a To-Do item.
706
- Parameters
707
- ----------
708
- todo_guid: str
709
- Identifier of the To-Do item.
710
- actor_guid: str
711
- The actor to receive the reassigned to-do item.
712
- status: str [default = "OPEN"]
713
- Filter items to match this status.
714
-
715
- Returns
716
- -------
717
- None
718
- This method does not return any value.
719
-
720
- Raises
721
- ------
722
- InvalidParameterException
723
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
724
- PropertyServerException
725
- Raised by the server when an issue arises in processing a valid request
726
- NotAuthorizedException
727
- The principle specified by the user_id does not have authorization for the requested action
728
- """
729
- loop = asyncio.get_event_loop()
730
- loop.run_until_complete(
731
- self._async_reassign_to_do(todo_guid, actor_guid, status)
732
- )
733
- return
734
-
735
- async def _async_find_to_do(
736
- self,
737
- search_string: str = "*",
738
- status: str = None,
739
- starts_with: bool = False,
740
- ends_with: bool = False,
741
- ignore_case: bool = True,
742
- start_from: int = 0,
743
- page_size: int = 100,
744
- ) -> list | str:
745
- """find To-Do items. Async version.
746
- Parameters
747
- ----------
748
- search_string: str
749
- String to search against. If '*' then all to-do items will match.
750
- status: str
751
- Filter items to match this status. Defaults to "OPEN"
752
- starts_with : bool, [default=False], optional
753
- Starts with the supplied string.
754
- ends_with : bool, [default=False], optional
755
- Ends with the supplied string
756
- ignore_case : bool, [default=False], optional
757
- Ignore case when searching
758
- Returns
759
- -------
760
- None
761
- List of To-Do items that match the criteria
762
-
763
- Raises
764
- ------
765
- InvalidParameterException
766
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
767
- PropertyServerException
768
- Raised by the server when an issue arises in processing a valid request
769
- NotAuthorizedException
770
- The principle specified by the user_id does not have authorization for the requested action
771
- """
772
-
773
- starts_with_s = str(starts_with).lower()
774
- ends_with_s = str(ends_with).lower()
775
- ignore_case_s = str(ignore_case).lower()
776
-
777
- if search_string == "*":
778
- search_string = " "
779
-
780
- body = {
781
- "class": "ToDoStatusSearchString",
782
- "toDoStatus": status,
783
- "searchString": search_string,
784
- }
785
-
786
- validate_search_string(search_string)
787
-
788
- url = (
789
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos/"
790
- f"find-by-search-string?startFrom={start_from}&pageSize={page_size}&"
791
- f"startsWith={starts_with_s}&endsWith={ends_with_s}&ignoreCase={ignore_case_s}"
792
- )
793
-
794
- response = await self._async_make_request("POST", url, body_slimmer(body))
795
- # return response.text
796
- return response.json().get("elements", "No ToDos found")
797
-
798
- def find_to_do(
799
- self,
800
- search_string: str,
801
- status: str = "OPEN",
802
- starts_with: bool = False,
803
- ends_with: bool = False,
804
- ignore_case: bool = True,
805
- start_from: int = 0,
806
- page_size: int = 100,
807
- ) -> list | str:
808
- """find To-Do items.
809
- Parameters
810
- ----------
811
- search_string: str
812
- String to search against. If '*' then all to-do items will match.
813
- view_server : str, optional
814
- The name of the server where the to-do item will be created. If not provided,
815
- the default server name associated with the instance of the class will be used.
816
- status: str
817
- Filter items to match this status. Defaults to "OPEN"
818
- starts_with : bool, [default=False], optional
819
- Starts with the supplied string.
820
- ends_with : bool, [default=False], optional
821
- Ends with the supplied string
822
- ignore_case : bool, [default=False], optional
823
- Ignore case when searching
824
- start_from: int, [default=0], optional
825
- When multiple pages of results are available, the page number to start from.
826
- page_size: int, [default=None]
827
- The number of items to return in a single page. If not specified, the default will be taken from
828
- the class instance.
829
- Returns
830
- -------
831
- None
832
- List of To-Do items that match the criteria
833
-
834
- Raises
835
- ------
836
- InvalidParameterException
837
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
838
- PropertyServerException
839
- Raised by the server when an issue arises in processing a valid request
840
- NotAuthorizedException
841
- The principle specified by the user_id does not have authorization for the requested action
842
- """
843
- loop = asyncio.get_event_loop()
844
- response = loop.run_until_complete(
845
- self._async_find_to_do(
846
- search_string,
847
- status,
848
- starts_with,
849
- ends_with,
850
- ignore_case,
851
- start_from,
852
- page_size,
853
- )
854
- )
855
- return response
856
-
857
- async def _async_get_to_dos_by_type(
858
- self,
859
- todo_type: str,
860
- status: str = "OPEN",
861
- start_from: int = 0,
862
- page_size: int = 100,
863
- ) -> list | str:
864
- """Get To-Do items by type. Async version
865
- Parameters
866
- ----------
867
- todo_type: str
868
- Type of to-do to find
869
- status: str
870
- Filter items to match this status. Defaults to "OPEN"
871
- start_from: int, [default=0], optional
872
- When multiple pages of results are available, the page number to start from.
873
- page_size: int, [default=None]
874
- The number of items to return in a single page. If not specified, the default will be taken from
875
- the class instance.
876
- Returns
877
- -------
878
- List of To-Do items that match the criteria
879
-
880
- Raises
881
- ------
882
- InvalidParameterException
883
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
884
- PropertyServerException
885
- Raised by the server when an issue arises in processing a valid request
886
- NotAuthorizedException
887
- The principle specified by the user_id does not have authorization for the requested action
888
- """
889
-
890
- validate_name(todo_type)
891
- body = {
892
- "status": status,
893
- }
894
-
895
- url = (
896
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos/types/"
897
- f"{todo_type}?startFrom={start_from}&pageSize={page_size}"
898
- )
899
-
900
- response = await self._async_make_request("POST", url, body)
901
- return response.json().get("elements", "No ToDos found")
902
-
903
- def get_to_dos_by_type(
904
- self,
905
- todo_type: str,
906
- status: str = "OPEN",
907
- start_from: int = 0,
908
- page_size: int = 100,
909
- ) -> list | str:
910
- """Get To-Do items by type.
911
- Parameters
912
- ----------
913
- todo_type: str
914
- Type of to-do to find
915
- status: str
916
- Filter items to match this status. Defaults to "OPEN"
917
- start_from: int, [default=0], optional
918
- When multiple pages of results are available, the page number to start from.
919
- page_size: int, [default=None]
920
- The number of items to return in a single page. If not specified, the default will be taken from
921
- the class instance.
922
- Returns
923
- -------
924
- List of To-Do items that match the criteria
925
-
926
- Raises
927
- ------
928
- InvalidParameterException
929
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
930
- PropertyServerException
931
- Raised by the server when an issue arises in processing a valid request
932
- NotAuthorizedException
933
- The principle specified by the user_id does not have authorization for the requested action
934
- """
935
- loop = asyncio.get_event_loop()
936
- response = loop.run_until_complete(
937
- self._async_get_to_dos_by_type(todo_type, status, start_from, page_size)
938
- )
939
- return response
940
-
941
- async def _async_update_action_target_properties(
942
- self,
943
- action_target_guid: str,
944
- body: dict,
945
- is_merge_update: bool = True,
946
- ) -> None:
947
- """Get To-Do items by type. Async version
948
- Parameters
949
- ----------
950
- action_target_guid: str
951
- Identity of the action target to update.
952
- body: dict
953
- Details of the updates to make.
954
- is_merge_update : bool, [default=True], optional
955
- indicates if the update should be a merge or replacement.
956
-
957
- Returns
958
- -------
959
- None
960
-
961
- Raises
962
- ------
963
- InvalidParameterException
964
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
965
- PropertyServerException
966
- Raised by the server when an issue arises in processing a valid request
967
- NotAuthorizedException
968
- The principle specified by the user_id does not have authorization for the requested action
969
- """
970
-
971
- is_merge_update_t = str(is_merge_update).lower()
972
-
973
- validate_name(action_target_guid)
974
-
975
- url = (
976
- f"{self.my_profile_command_root}/{self.view_server}/api/open-metadata/my-profile/to-dos/"
977
- f"action-targets/{action_target_guid}?isMergeUpdate={is_merge_update_t}"
978
- )
979
-
980
- await self._async_make_request("POST", url, body)
981
- return
982
-
983
- def update_action_target_properties(
984
- self,
985
- action_target_guid: str,
986
- body: dict,
987
- is_merge_update: bool = True,
988
- ) -> None:
989
- """Get To-Do items by type.
990
- Parameters
991
- ----------
992
- action_target_guid: str
993
- Identity of the action target to update.
994
- body: dict
995
- Details of the updates to make.
996
- is_merge_update : bool, [default=True], optional
997
- indicates if the update should be a merge or replacement.
998
-
999
- Returns
1000
- -------
1001
- None
1002
-
1003
- Raises
1004
- ------
1005
- InvalidParameterException
1006
- If the client passes incorrect parameters on the request - such as bad URLs or invalid values
1007
- PropertyServerException
1008
- Raised by the server when an issue arises in processing a valid request
1009
- NotAuthorizedException
1010
- The principle specified by the user_id does not have authorization for the requested action
1011
- """
1012
- loop = asyncio.get_event_loop()
1013
- loop.run_until_complete(
1014
- self._async_update_action_target_properties(
1015
- action_target_guid, body, is_merge_update
1016
- )
1017
- )
1018
- return
1019
-
1020
-
1021
- if __name__ == "__main__":
1022
- print("Main-My Profile")