kobai-sdk 0.3.5rc3__py3-none-any.whl → 0.3.5rc4__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 kobai-sdk might be problematic. Click here for more details.
- kobai/tenant_client.py +19 -8
- {kobai_sdk-0.3.5rc3.dist-info → kobai_sdk-0.3.5rc4.dist-info}/METADATA +1 -1
- {kobai_sdk-0.3.5rc3.dist-info → kobai_sdk-0.3.5rc4.dist-info}/RECORD +6 -6
- {kobai_sdk-0.3.5rc3.dist-info → kobai_sdk-0.3.5rc4.dist-info}/WHEEL +1 -1
- {kobai_sdk-0.3.5rc3.dist-info → kobai_sdk-0.3.5rc4.dist-info}/licenses/LICENSE +0 -0
- {kobai_sdk-0.3.5rc3.dist-info → kobai_sdk-0.3.5rc4.dist-info}/top_level.txt +0 -0
kobai/tenant_client.py
CHANGED
|
@@ -219,13 +219,13 @@ class TenantClient:
|
|
|
219
219
|
else:
|
|
220
220
|
return True
|
|
221
221
|
|
|
222
|
-
def spark_generate_genie_views(self, domains = None, concepts = None, not_concepts=None, enforce_map=True):
|
|
222
|
+
def spark_generate_genie_views(self, domains = None, concepts = None, not_concepts=None, enforce_map=True, local=False):
|
|
223
223
|
|
|
224
224
|
"""
|
|
225
225
|
Use the Spark Client to generate views for this tenant required to populate a Genie Data Room.
|
|
226
226
|
"""
|
|
227
227
|
|
|
228
|
-
tables = self.__get_view_sql(domains=domains, concepts=concepts, not_concepts=not_concepts, enforce_map=enforce_map)
|
|
228
|
+
tables = self.__get_view_sql(domains=domains, concepts=concepts, not_concepts=not_concepts, enforce_map=enforce_map, local=False)
|
|
229
229
|
for t in tables:
|
|
230
230
|
#print(t["sql"])
|
|
231
231
|
try:
|
|
@@ -326,15 +326,26 @@ class TenantClient:
|
|
|
326
326
|
# Semantic Profile
|
|
327
327
|
########################################
|
|
328
328
|
|
|
329
|
-
def
|
|
329
|
+
#def get_descriptions(self):
|
|
330
|
+
# response = self.api_client._TenantAPI__run_get("/episteme-svcs/api/descriptions", params={"schema": self.schema})
|
|
331
|
+
# return response.json()
|
|
330
332
|
|
|
331
|
-
|
|
332
|
-
descriptions = get_genie_descriptions(self.model_id, tenant_config, self.schema)
|
|
333
|
-
return descriptions
|
|
333
|
+
def __get_descriptions(self, local):
|
|
334
334
|
|
|
335
|
-
|
|
335
|
+
if local:
|
|
336
|
+
tenant_config = self.get_tenant_config()
|
|
337
|
+
descriptions = get_genie_descriptions(self.model_id, tenant_config, self.schema)
|
|
338
|
+
return descriptions
|
|
339
|
+
else:
|
|
340
|
+
response = self.api_client._TenantAPI__run_get("/episteme-svcs/api/descriptions", params={"schema": self.schema})
|
|
341
|
+
return response.json()
|
|
342
|
+
#tenant_config = self.get_tenant_config()
|
|
343
|
+
#descriptions = get_genie_descriptions(self.model_id, tenant_config, self.schema)
|
|
344
|
+
#return descriptions
|
|
345
|
+
|
|
346
|
+
def __get_view_sql(self, domains=None, concepts=None, not_concepts=None, enforce_map=True, local=False):
|
|
336
347
|
sql_list = []
|
|
337
|
-
descriptions = self.__get_descriptions()
|
|
348
|
+
descriptions = self.__get_descriptions(local)
|
|
338
349
|
|
|
339
350
|
for dom in descriptions["domains"]:
|
|
340
351
|
for con in dom["concepts"]:
|
|
@@ -9,9 +9,9 @@ kobai/mobi_config.py,sha256=e_O4S7YjgGOb3xEOzNDx1AELuwMwXP7F3i0kGp65IrI,531
|
|
|
9
9
|
kobai/ms_authenticate.py,sha256=f7t_BaxK8e-SUWoB6JliBEngF2iduF-COcCZq83H5t0,2297
|
|
10
10
|
kobai/spark_client.py,sha256=opM_F-4Ut5Hq5zZjWMuLvUps9sDULvyPNZHXGL8dW1k,776
|
|
11
11
|
kobai/tenant_api.py,sha256=Q5yuFd9_V4lo3LWzvYEEO3LpDRWFgQD4TlRPXDTGbiE,4368
|
|
12
|
-
kobai/tenant_client.py,sha256=
|
|
13
|
-
kobai_sdk-0.3.
|
|
14
|
-
kobai_sdk-0.3.
|
|
15
|
-
kobai_sdk-0.3.
|
|
16
|
-
kobai_sdk-0.3.
|
|
17
|
-
kobai_sdk-0.3.
|
|
12
|
+
kobai/tenant_client.py,sha256=ODlkl4SnkQN5ojuZNjh_d1Ianqb_Tv6v7SRdxwatyBw,44158
|
|
13
|
+
kobai_sdk-0.3.5rc4.dist-info/licenses/LICENSE,sha256=QwcOLU5TJoTeUhuIXzhdCEEDDvorGiC6-3YTOl4TecE,11356
|
|
14
|
+
kobai_sdk-0.3.5rc4.dist-info/METADATA,sha256=C3r6lkzXDjvxeKSm9X49Ysdkf688ADyPWMbPa9-Qr5w,19864
|
|
15
|
+
kobai_sdk-0.3.5rc4.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
|
|
16
|
+
kobai_sdk-0.3.5rc4.dist-info/top_level.txt,sha256=ns1El3BrTTHKvoAgU1XtiSaVIudYeCXbEEUVY8HFDZ4,6
|
|
17
|
+
kobai_sdk-0.3.5rc4.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|