pyegeria 0.8.0__py3-none-any.whl → 0.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.
@@ -11,16 +11,20 @@ import time
11
11
  from rich import print
12
12
  from rich.console import Console
13
13
 
14
- from pyegeria import CollectionManager, InvalidParameterException, PropertyServerException, UserNotAuthorizedException
14
+ from pyegeria import (
15
+ CollectionManager,
16
+ InvalidParameterException,
17
+ PropertyServerException,
18
+ UserNotAuthorizedException,
19
+ )
15
20
 
16
- view_server = 'view-server'
17
- platform_url = 'https://localhost:9443'
18
- user = 'erinoverview'
21
+ view_server = "view-server"
22
+ platform_url = "https://localhost:9443"
23
+ user = "erinoverview"
19
24
  console = Console(width=200)
20
25
 
21
26
  try:
22
- c_client = CollectionManager(view_server, platform_url,
23
- user_id=user)
27
+ c_client = CollectionManager(view_server, platform_url, user_id=user)
24
28
 
25
29
  token = c_client.create_egeria_bearer_token(user, "secret")
26
30
  start_time = time.perf_counter()
@@ -35,10 +39,16 @@ try:
35
39
  collection_type = "Digital Products Root"
36
40
  is_own_anchor = True
37
41
 
38
- response = c_client.create_root_collection(anchor_guid, parent_guid,
39
- parent_relationship_type_name, parent_at_end1,
40
- display_name, description, collection_type,
41
- is_own_anchor)
42
+ response = c_client.create_root_collection(
43
+ anchor_guid,
44
+ parent_guid,
45
+ parent_relationship_type_name,
46
+ parent_at_end1,
47
+ display_name,
48
+ description,
49
+ collection_type,
50
+ is_own_anchor,
51
+ )
42
52
  # Create first folder for Agriculture Insights
43
53
  parent_guid = response
44
54
  parent_relationship_type_name = "CollectionMembership"
@@ -46,23 +56,35 @@ try:
46
56
  description = "A folder for agricultural insights data product collections"
47
57
  collection_type = "Digital Product Marketplace"
48
58
 
49
- folder1 = c_client.create_folder_collection(None, parent_guid,
50
- parent_relationship_type_name,
51
- True, display_name, description,
52
- collection_type, True, "DATE_CREATED",
53
- None
54
- )
59
+ folder1 = c_client.create_folder_collection(
60
+ None,
61
+ parent_guid,
62
+ parent_relationship_type_name,
63
+ True,
64
+ display_name,
65
+ description,
66
+ collection_type,
67
+ True,
68
+ "DATE_CREATED",
69
+ None,
70
+ )
55
71
  print(f"\n\n created a folder with guid {folder1}")
56
72
  # create second folder for Earth Observations
57
73
  display_name = "Earth Observation Data Collection"
58
74
  description = "A folder for Earth Observation data product collections"
59
75
 
60
- folder2 = c_client.create_folder_collection(None, parent_guid,
61
- parent_relationship_type_name,
62
- True, display_name, description,
63
- collection_type, True, "DATE_CREATED",
64
- None
65
- )
76
+ folder2 = c_client.create_folder_collection(
77
+ None,
78
+ parent_guid,
79
+ parent_relationship_type_name,
80
+ True,
81
+ display_name,
82
+ description,
83
+ collection_type,
84
+ True,
85
+ "DATE_CREATED",
86
+ None,
87
+ )
66
88
  print(f"\n\n created a folder with guid {folder2}")
67
89
 
68
90
  # create a digital product, child of folder 1, for Land Use products
@@ -73,36 +95,36 @@ try:
73
95
  collection_type = "Digital Product"
74
96
  classification_name = "Digital Product"
75
97
  body_3 = {
76
- "class": "NewDigitalProductRequestBody",
77
- "isOwnAnchor": True,
78
- "parentGUID": parent_guid,
79
- "parentRelationshipTypeName": parent_relationship_type_name,
80
- "parentAtEnd1": True,
81
- "collectionProperties": {
82
- "class": "CollectionProperties",
83
- "qualifiedName": f"{classification_name}-{display_name}-{time.asctime()}",
84
- "name": display_name,
85
- "description": description,
86
- "collectionType": collection_type,
87
- "collectionOrdering": "DATE_CREATED",
98
+ "class": "NewDigitalProductRequestBody",
99
+ "isOwnAnchor": True,
100
+ "parentGUID": parent_guid,
101
+ "parentRelationshipTypeName": parent_relationship_type_name,
102
+ "parentAtEnd1": True,
103
+ "collectionProperties": {
104
+ "class": "CollectionProperties",
105
+ "qualifiedName": f"{classification_name}-{display_name}-{time.asctime()}",
106
+ "name": display_name,
107
+ "description": description,
108
+ "collectionType": collection_type,
109
+ "collectionOrdering": "DATE_CREATED",
110
+ },
111
+ "digitalProductProperties": {
112
+ "class": "DigitalProductProperties",
113
+ "productStatus": "ACTIVE",
114
+ "productName": "Land Use Classifications",
115
+ "productType": "Geospatial Data Assets",
116
+ "description": "Land use classification assets",
117
+ "introductionDate": "2023-12-01",
118
+ "maturity": "Nacent",
119
+ "serviceLife": "3 years",
120
+ "currentVersion": "V.5",
121
+ "nextVersionDate": "2024-12-01",
122
+ "withdrawDate": "2030-01-01",
123
+ "additionalProperties": {
124
+ "thought_id": "a guid",
125
+ "license": "cc-by-sa",
88
126
  },
89
- "digitalProductProperties": {
90
- "class": "DigitalProductProperties",
91
- "productStatus": "ACTIVE",
92
- "productName": "Land Use Classifications",
93
- "productType": "Geospatial Data Assets",
94
- "description": "Land use classification assets",
95
- "introductionDate": "2023-12-01",
96
- "maturity": "Nacent",
97
- "serviceLife": "3 years",
98
- "currentVersion": "V.5",
99
- "nextVersionDate": "2024-12-01",
100
- "withdrawDate": "2030-01-01",
101
- "additionalProperties": {
102
- "thought_id": "a guid",
103
- "license": "cc-by-sa",
104
- }
105
- }
127
+ },
106
128
  }
107
129
  folder3 = c_client.create_digital_product(body_3)
108
130
  print(f"\n\n created a collection with guid {folder3}")
@@ -113,36 +135,36 @@ try:
113
135
  description = "Landsat 8 data products"
114
136
 
115
137
  body_4 = {
116
- "class": "NewDigitalProductRequestBody",
117
- "isOwnAnchor": True,
118
- "parentGUID": parent_guid,
119
- "parentRelationshipTypeName": parent_relationship_type_name,
120
- "parentAtEnd1": True,
121
- "collectionProperties": {
122
- "class": "CollectionProperties",
123
- "qualifiedName": f"{classification_name}-{display_name}-{time.asctime()}",
124
- "name": display_name,
125
- "description": description,
126
- "collectionType": collection_type,
127
- "collectionOrdering": "DATE_CREATED",
138
+ "class": "NewDigitalProductRequestBody",
139
+ "isOwnAnchor": True,
140
+ "parentGUID": parent_guid,
141
+ "parentRelationshipTypeName": parent_relationship_type_name,
142
+ "parentAtEnd1": True,
143
+ "collectionProperties": {
144
+ "class": "CollectionProperties",
145
+ "qualifiedName": f"{classification_name}-{display_name}-{time.asctime()}",
146
+ "name": display_name,
147
+ "description": description,
148
+ "collectionType": collection_type,
149
+ "collectionOrdering": "DATE_CREATED",
150
+ },
151
+ "digitalProductProperties": {
152
+ "class": "DigitalProductProperties",
153
+ "productStatus": "ACTIVE",
154
+ "productName": "Landsat 8 Imagery",
155
+ "productType": "Geospatial Data Assets",
156
+ "description": description,
157
+ "introductionDate": "2024-01-01",
158
+ "maturity": "Mature",
159
+ "serviceLife": "3 years",
160
+ "currentVersion": "V1.5",
161
+ "nextVersion": "2024-06-01",
162
+ "withdrawDate": "2030-01-01",
163
+ "additionalProperties": {
164
+ "thought_id": "a guid",
165
+ "license": "cc-by-sa",
128
166
  },
129
- "digitalProductProperties": {
130
- "class": "DigitalProductProperties",
131
- "productStatus": "ACTIVE",
132
- "productName": "Landsat 8 Imagery",
133
- "productType": "Geospatial Data Assets",
134
- "description": description,
135
- "introductionDate": "2024-01-01",
136
- "maturity": "Mature",
137
- "serviceLife": "3 years",
138
- "currentVersion": "V1.5",
139
- "nextVersion": "2024-06-01",
140
- "withdrawDate": "2030-01-01",
141
- "additionalProperties": {
142
- "thought_id": "a guid",
143
- "license": "cc-by-sa",
144
- }
145
- }
167
+ },
146
168
  }
147
169
  folder4 = c_client.create_digital_product(body_4)
148
170
  print(f"\n\n created a collection with guid {folder4}")
@@ -154,12 +176,18 @@ try:
154
176
  parent_relationship_type_name = "CollectionMembership"
155
177
  collection_type = "Digital Product Marketplace"
156
178
 
157
- folder5 = c_client.create_folder_collection(None, parent_guid,
158
- parent_relationship_type_name,
159
- True, display_name, description,
160
- collection_type, True, "DATE_CREATED",
161
- None
162
- )
179
+ folder5 = c_client.create_folder_collection(
180
+ None,
181
+ parent_guid,
182
+ parent_relationship_type_name,
183
+ True,
184
+ display_name,
185
+ description,
186
+ collection_type,
187
+ True,
188
+ "DATE_CREATED",
189
+ None,
190
+ )
163
191
  # Create a DigitalProduct for Level-1B
164
192
  parent_guid = folder5
165
193
  display_name = "Sentinel 2 - Level 1B"
@@ -195,8 +223,8 @@ try:
195
223
  "additionalProperties": {
196
224
  "thought_id": "a guid",
197
225
  "license": "cc-by-sa",
198
- }
199
- }
226
+ },
227
+ },
200
228
  }
201
229
  folder6 = c_client.create_digital_product(body_6)
202
230
  print(f"\n\n created a collection with guid {folder6}")
@@ -235,8 +263,8 @@ try:
235
263
  "additionalProperties": {
236
264
  "thought_id": "a guid",
237
265
  "license": "cc-by-sa",
238
- }
239
- }
266
+ },
267
+ },
240
268
  }
241
269
  folder7 = c_client.create_digital_product(body_7)
242
270
  print(f"\n\n created a collection with guid {folder7}")
@@ -275,8 +303,8 @@ try:
275
303
  "additionalProperties": {
276
304
  "thought_id": "a guid",
277
305
  "license": "cc-by-sa",
278
- }
279
- }
306
+ },
307
+ },
280
308
  }
281
309
  folder8 = c_client.create_digital_product(body_8)
282
310
  print(f"\n\n created a collection with guid {folder8}")
@@ -284,7 +312,7 @@ try:
284
312
  except (
285
313
  InvalidParameterException,
286
314
  PropertyServerException,
287
- UserNotAuthorizedException
315
+ UserNotAuthorizedException,
288
316
  ) as e:
289
317
  console.print_exception(show_locals=True)
290
318
 
@@ -13,16 +13,20 @@ import time
13
13
  from rich import print
14
14
  from rich.console import Console
15
15
 
16
- from pyegeria import CollectionManager, InvalidParameterException, PropertyServerException, UserNotAuthorizedException
17
-
18
- view_server = 'view-server'
19
- platform_url = 'https://localhost:9443'
20
- user = 'erinoverview'
16
+ from pyegeria import (
17
+ CollectionManager,
18
+ InvalidParameterException,
19
+ PropertyServerException,
20
+ UserNotAuthorizedException,
21
+ )
22
+
23
+ view_server = "view-server"
24
+ platform_url = "https://localhost:9443"
25
+ user = "erinoverview"
21
26
  console = Console()
22
27
 
23
28
  try:
24
- c_client = CollectionManager(view_server, platform_url,
25
- user_id=user)
29
+ c_client = CollectionManager(view_server, platform_url, user_id=user)
26
30
 
27
31
  token = c_client.create_egeria_bearer_token(user, "secret")
28
32
  start_time = time.perf_counter()
@@ -34,10 +38,16 @@ try:
34
38
  description = "The root collection for our sustainability reporting project."
35
39
  collection_type = "Sustainability Collection"
36
40
 
37
- root = c_client.create_root_collection(None, parent_guid,
38
- parent_relationship_type_name,
39
- False, display_name, description,
40
- collection_type, True)
41
+ root = c_client.create_root_collection(
42
+ None,
43
+ parent_guid,
44
+ parent_relationship_type_name,
45
+ False,
46
+ display_name,
47
+ description,
48
+ collection_type,
49
+ True,
50
+ )
41
51
  print(f"\n\n created a root with guid {root}")
42
52
  # create a folder for Scope 1 Emissions
43
53
  anchor_guid = root
@@ -47,12 +57,18 @@ try:
47
57
  description = "A folder for information about scope 1 emissions."
48
58
  collection_type = "Sustainability Collection"
49
59
 
50
- scope1_folder = c_client.create_folder_collection(anchor_guid, parent_guid,
51
- parent_relationship_type_name,
52
- True, display_name, description,
53
- collection_type, False, "DATE_CREATED",
54
- None
55
- )
60
+ scope1_folder = c_client.create_folder_collection(
61
+ anchor_guid,
62
+ parent_guid,
63
+ parent_relationship_type_name,
64
+ True,
65
+ display_name,
66
+ description,
67
+ collection_type,
68
+ False,
69
+ "DATE_CREATED",
70
+ None,
71
+ )
56
72
  print(f"\n\n created scope1_folder with guid {scope1_folder}")
57
73
 
58
74
  # create a folder for Scope 2 Emissions.
@@ -63,12 +79,18 @@ try:
63
79
  description = "A folder for information about scope 2 emissions."
64
80
  collection_type = "Sustainability Collection"
65
81
 
66
- scope2_folder = c_client.create_folder_collection(anchor_guid, parent_guid,
67
- parent_relationship_type_name,
68
- True, display_name, description,
69
- collection_type, False, "DATE_CREATED",
70
- None
71
- )
82
+ scope2_folder = c_client.create_folder_collection(
83
+ anchor_guid,
84
+ parent_guid,
85
+ parent_relationship_type_name,
86
+ True,
87
+ display_name,
88
+ description,
89
+ collection_type,
90
+ False,
91
+ "DATE_CREATED",
92
+ None,
93
+ )
72
94
  print(f"\n\n created scope2_folder with guid {scope2_folder}")
73
95
 
74
96
  # create a folder for Scope 3 Emissions.
@@ -79,12 +101,18 @@ try:
79
101
  description = "A folder for information about scope 3 emissions."
80
102
  collection_type = "Sustainability Collection"
81
103
 
82
- scope3_folder = c_client.create_folder_collection(anchor_guid, parent_guid,
83
- parent_relationship_type_name,
84
- True, display_name, description,
85
- collection_type, False, "DATE_CREATED",
86
- None
87
- )
104
+ scope3_folder = c_client.create_folder_collection(
105
+ anchor_guid,
106
+ parent_guid,
107
+ parent_relationship_type_name,
108
+ True,
109
+ display_name,
110
+ description,
111
+ collection_type,
112
+ False,
113
+ "DATE_CREATED",
114
+ None,
115
+ )
88
116
  print(f"\n\n created scope3_folder with guid {scope3_folder}")
89
117
 
90
118
  # create a folder for Business Travel Emissions.
@@ -95,19 +123,25 @@ try:
95
123
  description = "A folder for information about scope 3 business travel emissions."
96
124
  collection_type = "Sustainability Collection"
97
125
 
98
- travel_folder = c_client.create_folder_collection(anchor_guid, parent_guid,
99
- parent_relationship_type_name,
100
- True, display_name, description,
101
- collection_type, False, "DATE_CREATED",
102
- None
103
- )
126
+ travel_folder = c_client.create_folder_collection(
127
+ anchor_guid,
128
+ parent_guid,
129
+ parent_relationship_type_name,
130
+ True,
131
+ display_name,
132
+ description,
133
+ collection_type,
134
+ False,
135
+ "DATE_CREATED",
136
+ None,
137
+ )
104
138
  print(f"\n\n created travel_folder with guid {travel_folder}")
105
139
 
106
140
 
107
141
  except (
108
- InvalidParameterException,
109
- PropertyServerException,
110
- UserNotAuthorizedException
142
+ InvalidParameterException,
143
+ PropertyServerException,
144
+ UserNotAuthorizedException,
111
145
  ) as e:
112
146
  console.print_exception(show_locals=True)
113
147
 
@@ -15,53 +15,89 @@ from rich.prompt import Prompt
15
15
  from rich.text import Text
16
16
  from rich.tree import Tree
17
17
 
18
- from pyegeria import CollectionManager, UserNotAuthorizedException, PropertyServerException, InvalidParameterException
18
+ from pyegeria import (
19
+ CollectionManager,
20
+ UserNotAuthorizedException,
21
+ PropertyServerException,
22
+ InvalidParameterException,
23
+ )
19
24
  from pyegeria._exceptions import (
20
25
  print_exception_response,
21
26
  )
22
27
 
23
28
  disable_ssl_warnings = True
24
29
  EGERIA_METADATA_STORE = os.environ.get("EGERIA_METADATA_STORE", "active-metadata-store")
25
- EGERIA_KAFKA_ENDPOINT = os.environ.get('KAFKA_ENDPOINT', 'localhost:9092')
26
- EGERIA_PLATFORM_URL = os.environ.get('EGERIA_PLATFORM_URL', 'https://localhost:9443')
27
- EGERIA_VIEW_SERVER = os.environ.get('VIEW_SERVER', 'view-server')
28
- EGERIA_VIEW_SERVER_URL = os.environ.get('EGERIA_VIEW_SERVER_URL', 'https://localhost:9443')
29
- EGERIA_INTEGRATION_DAEMON = os.environ.get('INTEGRATION_DAEMON', 'integration-daemon')
30
- EGERIA_ADMIN_USER = os.environ.get('ADMIN_USER', 'garygeeke')
31
- EGERIA_ADMIN_PASSWORD = os.environ.get('ADMIN_PASSWORD', 'secret')
32
- EGERIA_USER = os.environ.get('EGERIA_USER', 'erinoverview')
33
- EGERIA_USER_PASSWORD = os.environ.get('EGERIA_USER_PASSWORD', 'secret')
34
- EGERIA_JUPYTER = bool(os.environ.get('EGERIA_JUPYTER', 'False'))
35
- EGERIA_WIDTH = int(os.environ.get('EGERIA_WIDTH', '200'))
36
-
37
- def collection_viewer(root: str, server_name: str, platform_url: str, user: str, user_password: str,
38
- jupyter:bool=EGERIA_JUPYTER, width:int = EGERIA_WIDTH):
39
- """ A simple collection viewer"""
40
- def walk_collection_hierarchy(collection_client: CollectionManager, root_collection_name: str, tree: Tree) -> None:
30
+ EGERIA_KAFKA_ENDPOINT = os.environ.get("KAFKA_ENDPOINT", "localhost:9092")
31
+ EGERIA_PLATFORM_URL = os.environ.get("EGERIA_PLATFORM_URL", "https://localhost:9443")
32
+ EGERIA_VIEW_SERVER = os.environ.get("VIEW_SERVER", "view-server")
33
+ EGERIA_VIEW_SERVER_URL = os.environ.get(
34
+ "EGERIA_VIEW_SERVER_URL", "https://localhost:9443"
35
+ )
36
+ EGERIA_INTEGRATION_DAEMON = os.environ.get("INTEGRATION_DAEMON", "integration-daemon")
37
+ EGERIA_ADMIN_USER = os.environ.get("ADMIN_USER", "garygeeke")
38
+ EGERIA_ADMIN_PASSWORD = os.environ.get("ADMIN_PASSWORD", "secret")
39
+ EGERIA_USER = os.environ.get("EGERIA_USER", "erinoverview")
40
+ EGERIA_USER_PASSWORD = os.environ.get("EGERIA_USER_PASSWORD", "secret")
41
+ EGERIA_JUPYTER = bool(os.environ.get("EGERIA_JUPYTER", "False"))
42
+ EGERIA_WIDTH = int(os.environ.get("EGERIA_WIDTH", "200"))
43
+
44
+
45
+ def collection_viewer(
46
+ root: str,
47
+ server_name: str,
48
+ platform_url: str,
49
+ user: str,
50
+ user_password: str,
51
+ jupyter: bool = EGERIA_JUPYTER,
52
+ width: int = EGERIA_WIDTH,
53
+ ):
54
+ """A simple collection viewer"""
55
+
56
+ def walk_collection_hierarchy(
57
+ collection_client: CollectionManager, root_collection_name: str, tree: Tree
58
+ ) -> None:
41
59
  """Recursively build a Tree with collection contents."""
42
60
  members = collection_client.get_member_list(root_collection_name)
43
61
  if members:
44
62
  for member in members:
45
63
  style = "bold white on black"
46
- text_collection_name = Text(f"[bold white on black]Name: {member['name']}", style=style)
47
- text_qualified_name = Text(f"* QualifiedName: {member['qualifiedName']}")
64
+ text_collection_name = Text(
65
+ f"[bold white on black]Name: {member['name']}", style=style
66
+ )
67
+ text_qualified_name = Text(
68
+ f"* QualifiedName: {member['qualifiedName']}"
69
+ )
48
70
  text_guid = Text(f"* GUID: {member['guid']}", "green")
49
- text_collection_type = Text(f"* Collection Type: {member['collectionType']}")
71
+ text_collection_type = Text(
72
+ f"* Collection Type: {member['collectionType']}"
73
+ )
50
74
  text_description = Text(f"* Description: {member['description']}")
51
- p = Panel.fit(f"{text_collection_name}[green]\n{text_qualified_name}\n{text_guid}\n"
52
- f"{text_collection_type}\n{text_description}")
75
+ p = Panel.fit(
76
+ f"{text_collection_name}[green]\n{text_qualified_name}\n{text_guid}\n"
77
+ f"{text_collection_type}\n{text_description}"
78
+ )
53
79
  tt = tree.add(p, style=style)
54
80
 
55
- children = collection_client.get_collection_members(member['guid'])
81
+ children = collection_client.get_collection_members(member["guid"])
56
82
  if type(children) is list:
57
- branch = tt.add(f"[bold magenta on black]Members", style=style, guide_style=style)
58
- walk_collection_hierarchy(collection_client, member['qualifiedName'], branch),
83
+ branch = tt.add(
84
+ f"[bold magenta on black]Members",
85
+ style=style,
86
+ guide_style=style,
87
+ )
88
+ walk_collection_hierarchy(
89
+ collection_client, member["qualifiedName"], branch
90
+ ),
59
91
  else:
60
- tt = tree.add(f"[bold magenta on black]No collections match {root_collection_name}")
92
+ tt = tree.add(
93
+ f"[bold magenta on black]No collections match {root_collection_name}"
94
+ )
95
+
61
96
  try:
62
- tree = Tree(f"[bold bright green on black]{root}",guide_style="bold bright_blue")
63
- c_client = CollectionManager(server_name, platform_url,
64
- user_id=user)
97
+ tree = Tree(
98
+ f"[bold bright green on black]{root}", guide_style="bold bright_blue"
99
+ )
100
+ c_client = CollectionManager(server_name, platform_url, user_id=user)
65
101
 
66
102
  token = c_client.create_egeria_bearer_token(user, user_password)
67
103
  walk_collection_hierarchy(c_client, root, tree)
@@ -70,7 +106,7 @@ def collection_viewer(root: str, server_name: str, platform_url: str, user: str,
70
106
  except (
71
107
  InvalidParameterException,
72
108
  PropertyServerException,
73
- UserNotAuthorizedException
109
+ UserNotAuthorizedException,
74
110
  ) as e:
75
111
  print_exception_response(e)
76
112
 
@@ -90,9 +126,14 @@ def main():
90
126
  user_pass = args.password if args.password is not None else EGERIA_USER_PASSWORD
91
127
 
92
128
  try:
93
- root_collection = Prompt.ask("Enter the Root Collection to start from:", default="Root Sustainability Collection")
129
+ root_collection = Prompt.ask(
130
+ "Enter the Root Collection to start from:",
131
+ default="Root Sustainability Collection",
132
+ )
94
133
  collection_viewer(root_collection, server, url, userid, user_pass)
95
- except (KeyboardInterrupt):
134
+ except KeyboardInterrupt:
96
135
  pass
136
+
137
+
97
138
  if __name__ == "__main__":
98
- main()
139
+ main()
pyegeria/__init__.py CHANGED
@@ -14,6 +14,7 @@ the server platform and servers.
14
14
  from ._globals import (
15
15
  is_debug,
16
16
  disable_ssl_warnings,
17
+ enable_ssl_check,
17
18
  max_paging_size,
18
19
  TEMPLATE_GUIDS,
19
20
  INTEGRATION_GUIDS,
@@ -73,7 +74,7 @@ from .egeria_my_client import EgeriaMy
73
74
  from .egeria_cat_client import EgeriaCat
74
75
  from .egeria_tech_client import EgeriaTech
75
76
  from .egeria_config_client import EgeriaConfig
76
-
77
+ from .egeria_ops_client import EgeriaOps
77
78
 
78
79
  #
79
80
  # The following assignments were generated by the `create_tech_guid_lists.py` utility that uses the pyegeria functions
pyegeria/_client.py CHANGED
@@ -19,7 +19,13 @@ from pyegeria._exceptions import (
19
19
  PropertyServerException,
20
20
  UserNotAuthorizedException,
21
21
  )
22
- from pyegeria._globals import max_paging_size, TEMPLATE_GUIDS, INTEGRATION_GUIDS
22
+ from pyegeria._globals import (
23
+ max_paging_size,
24
+ TEMPLATE_GUIDS,
25
+ INTEGRATION_GUIDS,
26
+ enable_ssl_check,
27
+ disable_ssl_warnings,
28
+ )
23
29
  from pyegeria._validators import (
24
30
  validate_name,
25
31
  validate_server_name,
@@ -133,7 +139,7 @@ class Client:
133
139
  # self.session = httpx.Client(verify=self.ssl_verify)
134
140
  # else:
135
141
  # self.session = httpx.AsyncClient(verify=self.ssl_verify)
136
- self.session = AsyncClient(verify=self.ssl_verify)
142
+ self.session = AsyncClient(verify=enable_ssl_check)
137
143
  # if (len(template_guids) == 0) or (len(integration_guids) == 0):
138
144
  # self.build_global_guid_lists()
139
145
  # self.template_guids = template_guids
@@ -46,10 +46,9 @@ class CollectionManager(Client):
46
46
  self,
47
47
  server_name: str,
48
48
  platform_url: str,
49
- token: str = None,
50
49
  user_id: str = None,
51
50
  user_pwd: str = None,
52
- sync_mode: bool = True,
51
+ token: str = None,
53
52
  ):
54
53
  self.command_base: str = f"/api/open-metadata/collection-manager/collections"
55
54
  Client.__init__(self, server_name, platform_url, user_id=user_id, token=token)
@@ -58,12 +58,7 @@ class EgeriaCat(
58
58
  self, server_name, platform_url, user_id, user_pwd, token=token
59
59
  )
60
60
  CollectionManager.__init__(
61
- self,
62
- server_name,
63
- platform_url,
64
- token,
65
- user_id,
66
- user_pwd,
61
+ self, server_name, platform_url, user_id, user_pwd, token
67
62
  )
68
63
  EgeriaMy.__init__(
69
64
  self, server_name, platform_url, user_id, user_pwd, token=token
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pyegeria
3
- Version: 0.8.0
3
+ Version: 0.8.2
4
4
  Summary: A python client for Egeria
5
5
  Home-page: https://github.com/odpi/egeria-python
6
6
  License: Apache 2.0
@@ -1,9 +1,9 @@
1
- examples/doc_samples/Create_Collection_Sample.py,sha256=bz4QUbimAbp-Tn21Sr0DhwlGq53xeyNU8M23fvkjEI0,11844
2
- examples/doc_samples/Create_Sustainability_Collection_Sample.py,sha256=iLBm1LwRLi42Gayyb-wcWZ5NySQ6sc4kVSmwIAzP2Po,5049
1
+ examples/doc_samples/Create_Collection_Sample.py,sha256=ibKo0wNaF1D1s8XNR37508bZBRq7aaxKjdIdme-JzcE,11071
2
+ examples/doc_samples/Create_Sustainability_Collection_Sample.py,sha256=adM5lYFIodAhu91ece1aXz322MTP4ZKCjqIFbs4Ldcc,4232
3
3
  examples/widgets/cat/README.md,sha256=-aaAnIT2fcfU63vajgB-RzQk4l4yFdhkyVfSaTPiqRY,967
4
4
  examples/widgets/cat/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
5
  examples/widgets/cat/get_asset_graph.py,sha256=5YwgV4D1_R9pptPJuIFbPOjWpZBnfPiEan33_To75TE,11194
6
- examples/widgets/cat/get_collection.py,sha256=DBZ5-XkoYsz4WmMSPz0Ao0wz3DlAUQve89KI26-44nc,4613
6
+ examples/widgets/cat/get_collection.py,sha256=v7hCeEDcAQmcjM9qepuk8gg_RnYra3_v009AJOunkKk,5005
7
7
  examples/widgets/cat/get_project_dependencies.py,sha256=MSI7-W8Cntiv0c264g_Zmoi2pwECL75BoNZcTrtVJvg,5888
8
8
  examples/widgets/cat/get_project_structure.py,sha256=yUG5cbBfjLrHwD8fQmmmUPNlfmAKGXUedYQFMr_MlaI,5876
9
9
  examples/widgets/cat/get_tech_type_elements.py,sha256=-m3Q0BoNqkCtV8h75vMwTcOV-_ymEXmnJcr4Ec7WMAw,6180
@@ -64,8 +64,8 @@ examples/widgets/tech/list_tech_templates.py,sha256=RiyA8a4fIL9BGeGf37Bkk471mK5E
64
64
  examples/widgets/tech/list_valid_metadata_values.py,sha256=N3D0_BmREPszgde3uvvYdfzq7DJ46uMOv2t1vtncGsw,6333
65
65
  examples/widgets/tech/x_list_related_elements.py,sha256=qBsf1619cecaMCTzG0MG22fAT32WNH2Z3CXrjo9z-5Y,5853
66
66
  pyegeria/Xloaded_resources_omvs.py,sha256=xNLlmEXG8njFyiN08WKkT3D_9iLWzObM_2u5GTirjEo,3276
67
- pyegeria/__init__.py,sha256=OpppU9_cqeNBzEecgi_EOlL6YZwED0S-9JcITxKGJLo,9403
68
- pyegeria/_client.py,sha256=bX87W6_DlBIrmOJIrzzAwlCx_b2iHyUK3FPBqOUQ3dc,26522
67
+ pyegeria/__init__.py,sha256=ZYtSwZtiO3sU9xT1NNIC_rqIy-90VrfxOeH2c2EQj9c,9465
68
+ pyegeria/_client.py,sha256=05K3qJozVFsLynHisYV89DXFvcy2kAfDlfNwovXxD2o,26588
69
69
  pyegeria/_deprecated_gov_engine.py,sha256=dWNcwVsE5__dF2u4QiIyQrssozzzOjBbLld8MdpmVCQ,17264
70
70
  pyegeria/_exceptions.py,sha256=NJ7vAhmvusK1ENvY2MMrBB6A6TgpYjzS9QJxFH56b8c,18470
71
71
  pyegeria/_globals.py,sha256=1Uc8392wjbiVN5L__RzxC1-U97RMXj77_iUsMSgeAjQ,638
@@ -74,10 +74,10 @@ pyegeria/action_author_omvs.py,sha256=QZ2wMkQEvAmnr0mcgO8gnB1k95YghIgI1OBykO76O5
74
74
  pyegeria/asset_catalog_omvs.py,sha256=ss_nUCUQA0wixUeUZxZQYLcxJ_FVIhK__jn99qvyq4k,24543
75
75
  pyegeria/automated_curation_omvs.py,sha256=JdHppsoGH8bBvSRar_scEzYSVMqhOnN0Mg3PSkMOycE,150352
76
76
  pyegeria/classification_manager_omvs.py,sha256=XQ6VKz6NHtSMPr5BUnamzCBJKKVnoROoVxgz4f1N7IQ,186133
77
- pyegeria/collection_manager_omvs.py,sha256=qyWpJoClDRhlxoXqOacnxPW-pScITx8wZCSzb6Riyog,109997
77
+ pyegeria/collection_manager_omvs.py,sha256=IgemuKE-DjBkAG7y2kQFO0p3zv7YxpLHW4RU3IPuTRw,109965
78
78
  pyegeria/core_omag_server_config.py,sha256=qp1mpTm8q6QrP1IOiXIDOpAGGyIG6fJJ0Kqu-XagF88,93659
79
79
  pyegeria/create_tech_guid_lists.py,sha256=jClpvURy20o4UV83LOwhGg3TZdHGzfjZ9y0MNZyG2To,4282
80
- pyegeria/egeria_cat_client.py,sha256=qvt0YS0Xzv2xd7ZEPs0ihPhbbbwuhzBfRWWJOvMggNc,2056
80
+ pyegeria/egeria_cat_client.py,sha256=30oCGJgz0UqAnBCwet9t6Lf5iS1-6r6p1ze53_xG0io,1995
81
81
  pyegeria/egeria_config_client.py,sha256=oJ3Q4ts9ZayFJFB2cKGHaTqDyAZmsvx0GUzc35fEhdk,1030
82
82
  pyegeria/egeria_my_client.py,sha256=DfC1gdO0H3j-w62UQyAhCsVIHRcjF5oj48jDyFo-hGw,1340
83
83
  pyegeria/egeria_ops_client.py,sha256=yqwPOSKIfDsij0LD7VqY3WVk-1lit8gTtMBtJRmjFCE,1980
@@ -95,8 +95,8 @@ pyegeria/runtime_manager_omvs.py,sha256=pXsywkzAO85WCp1bqskmeG6kLHdAg12xVmjGG2WM
95
95
  pyegeria/server_operations.py,sha256=mtl3P6D9LdquBrOzvPr1zapDxSJ-97RerPUJn_NiAto,16722
96
96
  pyegeria/utils.py,sha256=pkVmS3RrbjaS9yz7FtOCwaOfV5FMqz-__Rt5koCnd9c,5374
97
97
  pyegeria/valid_metadata_omvs.py,sha256=3NjdRkcKWQclGcELJIJPtz7RuenjoVWOXazgU70uCrY,36115
98
- pyegeria-0.8.0.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
99
- pyegeria-0.8.0.dist-info/METADATA,sha256=CHLIDL0GoI42avnM_6ZPFVQNXUQ6K9q0cv8DdgDWCrc,2817
100
- pyegeria-0.8.0.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
101
- pyegeria-0.8.0.dist-info/entry_points.txt,sha256=5Q9bDxIqPgdhd3lDnzdRSCYy9hZtNm_BL49bcmbBpGQ,3808
102
- pyegeria-0.8.0.dist-info/RECORD,,
98
+ pyegeria-0.8.2.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
99
+ pyegeria-0.8.2.dist-info/METADATA,sha256=HbRZJLznWINbwpvLBq6ZSjJGj4C_RNYFw1qBDn-obgg,2817
100
+ pyegeria-0.8.2.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
101
+ pyegeria-0.8.2.dist-info/entry_points.txt,sha256=5Q9bDxIqPgdhd3lDnzdRSCYy9hZtNm_BL49bcmbBpGQ,3808
102
+ pyegeria-0.8.2.dist-info/RECORD,,