malevich-coretools 0.3.48__tar.gz → 0.3.50__tar.gz

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 malevich-coretools might be problematic. Click here for more details.

Files changed (38) hide show
  1. {malevich_coretools-0.3.48/malevich_coretools.egg-info → malevich_coretools-0.3.50}/PKG-INFO +1 -1
  2. malevich_coretools-0.3.50/VERSION +1 -0
  3. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/abstract/abstract.py +1 -0
  4. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/funcs/funcs.py +16 -0
  5. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/secondary/const.py +2 -0
  6. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/utils.py +42 -3
  7. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50/malevich_coretools.egg-info}/PKG-INFO +1 -1
  8. malevich_coretools-0.3.48/VERSION +0 -1
  9. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/LICENSE +0 -0
  10. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/MANIFEST.in +0 -0
  11. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/README.md +0 -0
  12. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/__init__.py +0 -0
  13. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/abstract/__init__.py +0 -0
  14. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/abstract/operations.py +0 -0
  15. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/abstract/pipeline.py +0 -0
  16. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/abstract/statuses.py +0 -0
  17. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/admin/__init__.py +0 -0
  18. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/admin/utils.py +0 -0
  19. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/batch/__init__.py +0 -0
  20. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/batch/utils.py +0 -0
  21. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/funcs/__init__.py +0 -0
  22. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/funcs/checks.py +0 -0
  23. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/funcs/helpers.py +0 -0
  24. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/secondary/__init__.py +0 -0
  25. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/secondary/config.py +0 -0
  26. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/secondary/helpers.py +0 -0
  27. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/secondary/kafka_utils.py +0 -0
  28. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/tools/__init__.py +0 -0
  29. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/tools/abstract.py +0 -0
  30. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools/tools/vast.py +0 -0
  31. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools.egg-info/SOURCES.txt +0 -0
  32. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools.egg-info/dependency_links.txt +0 -0
  33. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools.egg-info/requires.txt +0 -0
  34. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/malevich_coretools.egg-info/top_level.txt +0 -0
  35. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/pyproject.toml +0 -0
  36. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/requirements.txt +0 -0
  37. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/setup.cfg +0 -0
  38. {malevich_coretools-0.3.48 → malevich_coretools-0.3.50}/setup.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: malevich-coretools
3
- Version: 0.3.48
3
+ Version: 0.3.50
4
4
  Author: Andrew Pogrebnoj
5
5
  Author-email: andrew@onjulius.co
6
6
  License-File: LICENSE
@@ -0,0 +1 @@
1
+ 0.3.50
@@ -98,6 +98,7 @@ class User(BaseModel):
98
98
 
99
99
  class JsonImage(BaseModel):
100
100
  ref: str
101
+ tag: str = ""
101
102
  user: Optional[str] = None
102
103
  token: Optional[str] = None
103
104
 
@@ -890,6 +890,22 @@ async def get_userPipelines_realId_async(id: str, *args, **kwargs) -> Pipeline:
890
890
  return model_from_json(await send_to_core_get_async(USER_PIPELINES_REAL_ID(id), *args, **kwargs), Pipeline).simplify()
891
891
 
892
892
 
893
+ def get_userPipelines_tagSearch(tag: str, *args, **kwargs) -> ResultIds:
894
+ return model_from_json(send_to_core_get(USER_PIPELINES_TAG(tag), *args, **kwargs), ResultIds)
895
+
896
+
897
+ async def get_userPipelines_tagSearch_async(tag: str, *args, **kwargs) -> ResultIds:
898
+ return model_from_json(await send_to_core_get_async(USER_PIPELINES_TAG(tag), *args, **kwargs), ResultIds)
899
+
900
+
901
+ def get_userPipelines_realIds_tagSearch(tag: str, *args, **kwargs) -> ResultIds:
902
+ return model_from_json(send_to_core_get(USER_PIPELINES_TAG_REAL_IDS(tag), *args, **kwargs), ResultIds)
903
+
904
+
905
+ async def get_userPipelines_realIds_tagSearch_async(tag: str, *args, **kwargs) -> ResultIds:
906
+ return model_from_json(await send_to_core_get_async(USER_PIPELINES_TAG_REAL_IDS(tag), *args, **kwargs), ResultIds)
907
+
908
+
893
909
  def post_userPipelines(data: UserTask, wait: bool, *args, **kwargs) -> Alias.Id:
894
910
  return send_to_core_modify(USER_PIPELINES(wait), data, *args, **kwargs)
895
911
 
@@ -139,6 +139,8 @@ USER_PIPELINES_MAP_IDS = f"{USER_PIPELINES_MAIN}/mapIds"
139
139
  USER_PIPELINES_MAP_ID = lambda id: f"{USER_PIPELINES_MAIN}/mapIds/{urllib.parse.quote(str(id), safe='')}"
140
140
  USER_PIPELINES_ID = lambda id, wait: with_wait(f"{USER_PIPELINES_MAIN}/{urllib.parse.quote(str(id), safe='')}", wait)
141
141
  USER_PIPELINES_REAL_ID = lambda id: f"{USER_PIPELINES_MAIN}/realIds/{urllib.parse.quote(str(id), safe='')}"
142
+ USER_PIPELINES_TAG = lambda tag: f"{USER_PIPELINES_MAIN}/tagSearch/{urllib.parse.quote(str(tag), safe='')}"
143
+ USER_PIPELINES_TAG_REAL_IDS = lambda tag: f"{USER_PIPELINES_MAIN}/realIds/tagSearch/{urllib.parse.quote(str(tag), safe='')}"
142
144
 
143
145
  ## UserCfgsController
144
146
  USER_CFGS_MAIN = f"{API_VERSION}/userCfgs"
@@ -1965,6 +1965,7 @@ def create_app(
1965
1965
  app_cfg: Optional[Union[Dict[str, Any], Alias.Json]] = None,
1966
1966
  image_ref: Optional[str] = None,
1967
1967
  image_auth: Optional[AUTH] = None,
1968
+ image_tag: Optional[str] = None,
1968
1969
  platform: str = "base",
1969
1970
  platform_settings: Optional[str] = None,
1970
1971
  extra_collections_from: Optional[Dict[str, Union[List[str], str]]] = None,
@@ -1990,7 +1991,7 @@ def create_app(
1990
1991
  image_token = image_auth[1] if image_auth is not None else Config.TOKEN if use_system_auth else None
1991
1992
  if Config.WITH_WARNINGS and (image_user is None or image_token is None):
1992
1993
  Config.logger.warning("image_auth not set")
1993
- json_image = JsonImage(ref=image_ref, user=image_user, token=image_token)
1994
+ json_image = JsonImage(ref=image_ref, tag=image_tag or "", user=image_user, token=image_token)
1994
1995
  if extra_collections_from is not None:
1995
1996
  for k, v in extra_collections_from.items():
1996
1997
  if isinstance(v, str):
@@ -2022,6 +2023,7 @@ def update_app(
2022
2023
  app_cfg: Optional[Union[Dict[str, Any], Alias.Json]] = None,
2023
2024
  image_ref: Optional[str] = None,
2024
2025
  image_auth: Optional[AUTH] = None,
2026
+ image_tag: Optional[str] = None,
2025
2027
  platform: str = "base",
2026
2028
  platform_settings: Optional[str] = None,
2027
2029
  extra_collections_from: Optional[Dict[str, Union[List[str], str]]] = None,
@@ -2046,7 +2048,7 @@ def update_app(
2046
2048
  image_token = image_auth[1] if image_auth is not None else Config.TOKEN if use_system_auth else None
2047
2049
  if Config.WITH_WARNINGS and (image_user is None or image_token is None):
2048
2050
  Config.logger.warning("image_auth not set")
2049
- json_image = JsonImage(ref=image_ref, user=image_user, token=image_token)
2051
+ json_image = JsonImage(ref=image_ref, tag=image_tag or "", user=image_user, token=image_token)
2050
2052
  if extra_collections_from is not None:
2051
2053
  for k, v in extra_collections_from.items():
2052
2054
  if isinstance(v, str):
@@ -2430,6 +2432,42 @@ def get_pipeline_real(
2430
2432
  return f.get_userPipelines_realId(id, auth=auth, conn_url=conn_url)
2431
2433
 
2432
2434
 
2435
+ def search_pipeline_by_image_tag(
2436
+ tag: str,
2437
+ *,
2438
+ auth: Optional[AUTH] = None,
2439
+ conn_url: Optional[str] = None,
2440
+ batcher: Optional[Batcher] = None,
2441
+ is_async: bool = False,
2442
+ ) -> ResultIds:
2443
+ """return pipelines ids by `tag`"""
2444
+ if batcher is None:
2445
+ batcher = Config.BATCHER
2446
+ if batcher is not None:
2447
+ return batcher.add("getPipelinesByTag", vars={"tag": tag}, result_model=ResultIds)
2448
+ if is_async:
2449
+ return f.get_userPipelines_tagSearch_async(tag, auth=auth, conn_url=conn_url)
2450
+ return f.get_userPipelines_tagSearch(tag, auth=auth, conn_url=conn_url)
2451
+
2452
+
2453
+ def search_pipeline_by_image_tag_real(
2454
+ tag: str,
2455
+ *,
2456
+ auth: Optional[AUTH] = None,
2457
+ conn_url: Optional[str] = None,
2458
+ batcher: Optional[Batcher] = None,
2459
+ is_async: bool = False,
2460
+ ) -> ResultIds:
2461
+ """return real pipelines ids by `tag`"""
2462
+ if batcher is None:
2463
+ batcher = Config.BATCHER
2464
+ if batcher is not None:
2465
+ return batcher.add("getPipelinesByTagReal", vars={"tag": tag}, result_model=ResultIds)
2466
+ if is_async:
2467
+ return f.get_userPipelines_realIds_tagSearch_async(tag, auth=auth, conn_url=conn_url)
2468
+ return f.get_userPipelines_realIds_tagSearch(tag, auth=auth, conn_url=conn_url)
2469
+
2470
+
2433
2471
  def create_pipeline(
2434
2472
  pipeline_id: str,
2435
2473
  processors: Dict[str, Processor] = None,
@@ -3106,6 +3144,7 @@ def get_app_info_by_real_id(
3106
3144
  def get_image_info(
3107
3145
  image_ref: str,
3108
3146
  image_auth: Optional[AUTH] = None,
3147
+ image_tag: Optional[str] = None,
3109
3148
  parse: bool = False,
3110
3149
  *,
3111
3150
  use_system_auth: bool = False,
@@ -3121,7 +3160,7 @@ def get_image_info(
3121
3160
  image_token = image_auth[1] if image_auth is not None else Config.TOKEN if use_system_auth else None
3122
3161
  if Config.WITH_WARNINGS and (image_user is None or image_token is None):
3123
3162
  Config.logger.warning("image_auth not set")
3124
- data = JsonImage(ref=image_ref, user=image_user, token=image_token)
3163
+ data = JsonImage(ref=image_ref, tag=image_tag or "", user=image_user, token=image_token)
3125
3164
  if batcher is not None:
3126
3165
  return batcher.add("imageInfo", data=data, result_model=AppFunctionsInfo if parse else None)
3127
3166
  if is_async:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: malevich-coretools
3
- Version: 0.3.48
3
+ Version: 0.3.50
4
4
  Author: Andrew Pogrebnoj
5
5
  Author-email: andrew@onjulius.co
6
6
  License-File: LICENSE
@@ -1 +0,0 @@
1
- 0.3.48