yellowdog-python-examples 8.2.0__py3-none-any.whl → 8.2.1__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.
yellowdog_cli/__init__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "8.2.0"
1
+ __version__ = "8.2.1"
yellowdog_cli/create.py CHANGED
@@ -48,6 +48,7 @@ from yellowdog_client.model.exceptions import InvalidRequestException
48
48
 
49
49
  from yellowdog_cli.utils.entity_utils import (
50
50
  clear_application_caches,
51
+ clear_compute_requirement_template_cache,
51
52
  clear_compute_source_template_cache,
52
53
  clear_group_caches,
53
54
  clear_image_caches,
@@ -130,6 +131,7 @@ from yellowdog_cli.utils.wrapper import ARGS_PARSER, CLIENT, CONFIG_COMMON, main
130
131
  from yellowdog_cli.utils.ydid_utils import YDIDType, get_ydid_type
131
132
 
132
133
  CLEAR_CST_CACHE: bool = False # Track whether the CST cache needs to be cleared
134
+ CLEAR_CRT_CACHE: bool = False # Track whether the CRT cache needs to be cleared
133
135
  CLEAR_IMAGE_FAMILY_CACHE: bool = (
134
136
  False # Track whether the image caches need to be cleared
135
137
  )
@@ -391,6 +393,8 @@ def create_compute_requirement_template(resource: Dict):
391
393
  template = CLIENT.compute_client.add_compute_requirement_template(
392
394
  compute_template
393
395
  )
396
+ global CLEAR_CRT_CACHE
397
+ CLEAR_CRT_CACHE = True
394
398
  print_log(f"Created Compute Requirement Template '{name}' ({template.id})")
395
399
  if ARGS_PARSER.quiet:
396
400
  print(template.id)
@@ -729,6 +733,10 @@ def create_allowance(resource: Dict):
729
733
  template_name_or_id = resource.get(PROP_SOURCE_CREATED_FROM, None)
730
734
  if template_name_or_id is not None:
731
735
  if get_ydid_type(template_name_or_id) != YDIDType.COMPUTE_SOURCE_TEMPLATE:
736
+ global CLEAR_CST_CACHE
737
+ if CLEAR_CST_CACHE: # Update the CST cache if required
738
+ clear_compute_source_template_cache()
739
+ CLEAR_CST_CACHE = False
732
740
  template_id = find_compute_source_template_id_by_name(
733
741
  client=CLIENT, name=template_name_or_id
734
742
  )
@@ -750,6 +758,10 @@ def create_allowance(resource: Dict):
750
758
  get_ydid_type(template_name_or_id)
751
759
  != YDIDType.COMPUTE_REQUIREMENT_TEMPLATE
752
760
  ):
761
+ global CLEAR_CRT_CACHE
762
+ if CLEAR_CRT_CACHE: # Update the CRT cache if required
763
+ clear_compute_requirement_template_cache()
764
+ CLEAR_CRT_CACHE = False
753
765
  template_id = find_compute_requirement_template_id_by_name(
754
766
  client=CLIENT, name=template_name_or_id
755
767
  )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: yellowdog-python-examples
3
- Version: 8.2.0
3
+ Version: 8.2.1
4
4
  Summary: Python CLI commands using the YellowDog Python SDK
5
5
  Author-email: YellowDog Limited <support@yellowdog.co>
6
6
  License-Expression: Apache-2.0
@@ -44,7 +44,7 @@ Dynamic: license-file
44
44
 
45
45
  ## Overview
46
46
 
47
- This is a set of Python CLI commands for interacting with the YellowDog Platform, providing examples of usage of the [YellowDog Python SDK](https://docs.yellowdog.co/api/python/index.html).
47
+ This is a set of Python CLI commands for interacting with the YellowDog Platform, providing examples of usage of the [YellowDog Python SDK](https://docs.yellowdog.ai/sdk/python/index.html).
48
48
 
49
49
  The commands support:
50
50
 
@@ -68,4 +68,4 @@ The commands support:
68
68
  - **Terminating** Compute Requirements with the **`yd-terminate`** command
69
69
  - **Uploading** files to the YellowDog Object Store with the **`yd-upload`** command
70
70
 
71
- Please see the documenation in the [GitHub repository](https://github.com/yellowdog/python-examples) for more details.
71
+ Please see the documentation in the [GitHub repository](https://github.com/yellowdog/python-examples) for more details.
@@ -1,11 +1,11 @@
1
- yellowdog_cli/__init__.py,sha256=Xb24P8T6pG5QQaEw-UTO0iybyDoxvRGJaUR_qFoVAJQ,22
1
+ yellowdog_cli/__init__.py,sha256=lPYx_JLWGM0F2xAcHXVLkIwicje2ZtdqEBMpuaNCsEU,22
2
2
  yellowdog_cli/abort.py,sha256=S8tCr-Fcc8zM7luQ5_xunEeo-eqmkO4pmahDZEpxWF4,4311
3
3
  yellowdog_cli/admin.py,sha256=Iipc0_A-Rf997hSDjOOYTaPpB3dsuqekV8Slmm154GI,1010
4
4
  yellowdog_cli/boost.py,sha256=JOUkXpl7yvmVZCAS_iv8GJ6g2wF1siVjGGJ-EUDI0FI,1268
5
5
  yellowdog_cli/cancel.py,sha256=Eu0FIH-VNNhW7WzvC0tcHgp7KxMVc35n5Rinu_YPeZc,6357
6
6
  yellowdog_cli/cloudwizard.py,sha256=UC1CDNPAsUMh_0C9ScLF4wGmvJ2Rbryravj67LHdFnI,2647
7
7
  yellowdog_cli/compare.py,sha256=yihgygtxedvRXz0mQV9hmvvMeKaNYIMfgBlTHetaa_s,24311
8
- yellowdog_cli/create.py,sha256=QD9Su3GXEQTOsfNt0BswEWpKcD65kpJZnwcUZMf_6-c,51944
8
+ yellowdog_cli/create.py,sha256=tr_pULYy4L9k6E6TcY6-r5gr--aCeER2E5ONh_wrWEA,52564
9
9
  yellowdog_cli/delete.py,sha256=7YWGY8vI9ec3QP2y7VSEFFyAsY3IWcsZndDDXhlUNTY,3023
10
10
  yellowdog_cli/download.py,sha256=zYlfr7jCoJGzoayjhpoy3Ku9unmXnLu5XORRuUIuDlo,5479
11
11
  yellowdog_cli/finish.py,sha256=Edcz9__13ppE2KUffuLoLTjo4Cj9FKLhj-ttxYiEKvs,5231
@@ -56,9 +56,9 @@ yellowdog_cli/utils/validate_properties.py,sha256=TsroKrf4jcAg_uQLRb9DpoSjRZ49XB
56
56
  yellowdog_cli/utils/variables.py,sha256=AHaolW682lkqm1P9MqWZnwvvK-Gd8hgV0HgzX76A1Ck,20542
57
57
  yellowdog_cli/utils/wrapper.py,sha256=TtvHmPKqKRk9meQw3LcsZcpkYNyuPSGcS0tC3fbQ4U4,3846
58
58
  yellowdog_cli/utils/ydid_utils.py,sha256=Gs98Pidkpd6v-cpL28t3z8mOW9JMB7ZY2MkGBX8EhMo,2360
59
- yellowdog_python_examples-8.2.0.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
60
- yellowdog_python_examples-8.2.0.dist-info/METADATA,sha256=wHbZAMaPm1-uvj6HCtfMBBpZlGWPx19JCRqtTQS5Hy0,3927
61
- yellowdog_python_examples-8.2.0.dist-info/WHEEL,sha256=qELbo2s1Yzl39ZmrAibXA2jjPLUYfnVhUNTlyF1rq0Y,92
62
- yellowdog_python_examples-8.2.0.dist-info/entry_points.txt,sha256=KABYVOB3kO7kVqnUplNNoz4l36KUUVY05ynsZ9jSVL8,1016
63
- yellowdog_python_examples-8.2.0.dist-info/top_level.txt,sha256=RfffFF4rsBrBbPB1qRkJsRpUn_5icIZSdCqMDLO3hgA,14
64
- yellowdog_python_examples-8.2.0.dist-info/RECORD,,
59
+ yellowdog_python_examples-8.2.1.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
60
+ yellowdog_python_examples-8.2.1.dist-info/METADATA,sha256=UEygUhsuoLT-TOJkI87SDUCU1hiCT0BnxvB5Nw0KJ0w,3928
61
+ yellowdog_python_examples-8.2.1.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
62
+ yellowdog_python_examples-8.2.1.dist-info/entry_points.txt,sha256=KABYVOB3kO7kVqnUplNNoz4l36KUUVY05ynsZ9jSVL8,1016
63
+ yellowdog_python_examples-8.2.1.dist-info/top_level.txt,sha256=RfffFF4rsBrBbPB1qRkJsRpUn_5icIZSdCqMDLO3hgA,14
64
+ yellowdog_python_examples-8.2.1.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (80.10.1)
2
+ Generator: setuptools (80.10.2)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5