yellowdog-python-examples 8.1.6__py3-none-any.whl → 8.1.7__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 +1 -1
- yellowdog_cli/shutdown.py +10 -8
- yellowdog_cli/terminate.py +2 -2
- {yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/METADATA +1 -1
- {yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/RECORD +9 -9
- {yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/WHEEL +0 -0
- {yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/entry_points.txt +0 -0
- {yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/licenses/LICENSE +0 -0
- {yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/top_level.txt +0 -0
yellowdog_cli/__init__.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "8.1.
|
|
1
|
+
__version__ = "8.1.7"
|
yellowdog_cli/shutdown.py
CHANGED
|
@@ -16,11 +16,12 @@ from yellowdog_client.model import (
|
|
|
16
16
|
from yellowdog_cli.utils.entity_utils import (
|
|
17
17
|
get_worker_pool_by_id,
|
|
18
18
|
get_worker_pool_id_by_name,
|
|
19
|
+
get_worker_pools,
|
|
19
20
|
)
|
|
20
21
|
from yellowdog_cli.utils.follow_utils import follow_ids
|
|
21
22
|
from yellowdog_cli.utils.interactive import confirmed, select
|
|
22
23
|
from yellowdog_cli.utils.misc_utils import link_entity
|
|
23
|
-
from yellowdog_cli.utils.printing import print_error, print_log
|
|
24
|
+
from yellowdog_cli.utils.printing import print_error, print_log, print_warning
|
|
24
25
|
from yellowdog_cli.utils.wrapper import ARGS_PARSER, CLIENT, CONFIG_COMMON, main_wrapper
|
|
25
26
|
from yellowdog_cli.utils.ydid_utils import YDIDType, get_ydid_type
|
|
26
27
|
|
|
@@ -37,9 +38,10 @@ def main():
|
|
|
37
38
|
f"names including '{CONFIG_COMMON.name_tag}'"
|
|
38
39
|
)
|
|
39
40
|
|
|
40
|
-
worker_pool_summaries: List[WorkerPoolSummary] = (
|
|
41
|
-
CLIENT.
|
|
41
|
+
worker_pool_summaries: List[WorkerPoolSummary] = get_worker_pools(
|
|
42
|
+
CLIENT, CONFIG_COMMON.namespace, CONFIG_COMMON.name_tag
|
|
42
43
|
)
|
|
44
|
+
|
|
43
45
|
shutdown_count = 0
|
|
44
46
|
|
|
45
47
|
selected_worker_pool_summaries: List[WorkerPoolSummary] = []
|
|
@@ -73,7 +75,7 @@ def main():
|
|
|
73
75
|
print_log(f"Shut down {link_entity(CONFIG_COMMON.url, worker_pool)}")
|
|
74
76
|
optionally_terminate_compute_requirement(worker_pool_summary.id)
|
|
75
77
|
except Exception as e:
|
|
76
|
-
print_error(f"
|
|
78
|
+
print_error(f"Failed to shut down '{worker_pool_summary.name}': {e}")
|
|
77
79
|
|
|
78
80
|
if shutdown_count > 0:
|
|
79
81
|
print_log(f"Shut down {shutdown_count} Worker Pool(s)")
|
|
@@ -101,7 +103,7 @@ def shutdown_by_names_or_ids(names_or_ids: List[str]):
|
|
|
101
103
|
else:
|
|
102
104
|
worker_pool_id = get_worker_pool_id_by_name(CLIENT, name_or_id)
|
|
103
105
|
if worker_pool_id is None:
|
|
104
|
-
|
|
106
|
+
print_warning(f"Worker Pool '{name_or_id}' not found")
|
|
105
107
|
continue
|
|
106
108
|
worker_pool_ids.append(worker_pool_id)
|
|
107
109
|
|
|
@@ -120,14 +122,14 @@ def shutdown_by_names_or_ids(names_or_ids: List[str]):
|
|
|
120
122
|
print_log(f"Shut down Worker Pool '{worker_pool_id}'")
|
|
121
123
|
optionally_terminate_compute_requirement(worker_pool_id)
|
|
122
124
|
except Exception as e:
|
|
123
|
-
print_error(f"
|
|
125
|
+
print_error(f"Failed to shut down Worker Pool '{worker_pool_id}': ({e})")
|
|
124
126
|
|
|
125
127
|
for node_id in node_ids:
|
|
126
128
|
try:
|
|
127
129
|
CLIENT.worker_pool_client.shutdown_node_by_id(node_id)
|
|
128
130
|
print_log(f"Shut down Node '{node_id}'")
|
|
129
131
|
except Exception as e:
|
|
130
|
-
print_error(f"
|
|
132
|
+
print_error(f"Failed to to shut down Node '{node_id}': ({e})")
|
|
131
133
|
|
|
132
134
|
if ARGS_PARSER.follow:
|
|
133
135
|
follow_ids(worker_pool_ids, auto_cr=ARGS_PARSER.auto_cr)
|
|
@@ -151,7 +153,7 @@ def optionally_terminate_compute_requirement(worker_pool_id: str):
|
|
|
151
153
|
f"Terminated associated Compute Requirement '{worker_pool.computeRequirementId}'"
|
|
152
154
|
)
|
|
153
155
|
except Exception as e:
|
|
154
|
-
print_error(f"
|
|
156
|
+
print_error(f"Failed to terminate Compute Requirement: ({e})")
|
|
155
157
|
|
|
156
158
|
|
|
157
159
|
# Entry point
|
yellowdog_cli/terminate.py
CHANGED
|
@@ -77,7 +77,7 @@ def main():
|
|
|
77
77
|
)
|
|
78
78
|
except Exception as e:
|
|
79
79
|
print_error(
|
|
80
|
-
f"
|
|
80
|
+
f"Failed to terminate '{compute_requirement_summary.name}': {e}"
|
|
81
81
|
)
|
|
82
82
|
|
|
83
83
|
if terminated_count > 0:
|
|
@@ -125,7 +125,7 @@ def terminate_cr_by_name_or_id(names_or_ids: List[str]):
|
|
|
125
125
|
)
|
|
126
126
|
print_log(f"Terminated '{compute_requirement_id}'")
|
|
127
127
|
except Exception as e:
|
|
128
|
-
print_error(f"
|
|
128
|
+
print_error(f"Failed to terminate '{compute_requirement_id}': ({e})")
|
|
129
129
|
|
|
130
130
|
if ARGS_PARSER.follow:
|
|
131
131
|
follow_ids(compute_requirement_ids)
|
{yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/RECORD
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
yellowdog_cli/__init__.py,sha256=
|
|
1
|
+
yellowdog_cli/__init__.py,sha256=DSjpcTXEMbKTSEhH-ChqB5reU3Hdp38wfe3HkEnrtRQ,22
|
|
2
2
|
yellowdog_cli/abort.py,sha256=3mzTL8DH5InpJry4wPhwi3WJjC8_vCmPpkyf6jLDrBM,4302
|
|
3
3
|
yellowdog_cli/admin.py,sha256=Iipc0_A-Rf997hSDjOOYTaPpB3dsuqekV8Slmm154GI,1010
|
|
4
4
|
yellowdog_cli/boost.py,sha256=JOUkXpl7yvmVZCAS_iv8GJ6g2wF1siVjGGJ-EUDI0FI,1268
|
|
@@ -19,10 +19,10 @@ yellowdog_cli/provision.py,sha256=-rbFJYzd3Kfq6zpFhbM_KM0VUSkJAa3mvY2YODTNc5Q,19
|
|
|
19
19
|
yellowdog_cli/remove.py,sha256=yPZSVXY0shzcb_FN8MvW1friuixVzuVGmwqZAnFLDno,20904
|
|
20
20
|
yellowdog_cli/resize.py,sha256=5oMqZmT1KXjnqEClCVzQbCDyZaEu-oc06mypy0TlTBo,4353
|
|
21
21
|
yellowdog_cli/show.py,sha256=rOi6ROkG_o-c65XB84JvQgDHxV-h3zvTX9H09fIV2BE,11014
|
|
22
|
-
yellowdog_cli/shutdown.py,sha256=
|
|
22
|
+
yellowdog_cli/shutdown.py,sha256=Coc4qljvpUzG1r3ZuOLSLzTglzXZVbWbh3GzUH7tpeU,5605
|
|
23
23
|
yellowdog_cli/start.py,sha256=9PHUAbS6vSq9RbttKkymOBzltIlWssQvk4zHJ8R-bWw,314
|
|
24
24
|
yellowdog_cli/submit.py,sha256=Q0qUul2WqswvuxCGkpsDEAIh0Ju-iYJWaVU76S6aV5g,61680
|
|
25
|
-
yellowdog_cli/terminate.py,sha256=
|
|
25
|
+
yellowdog_cli/terminate.py,sha256=G-4yeeF6eN_VHT9wkfMeyRmu0HYm2kZ_BxiseIBAwQ0,4685
|
|
26
26
|
yellowdog_cli/upload.py,sha256=tCqspQ5xNqUFsAIqBxzvyVQ5Uhk5uZFTf1xM3JFSgBs,5389
|
|
27
27
|
yellowdog_cli/version.py,sha256=IADl53F8zo2pe1FrgZqo3hKNQXmfz7GnynIbXZ7ryQo,1208
|
|
28
28
|
yellowdog_cli/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -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.1.
|
|
60
|
-
yellowdog_python_examples-8.1.
|
|
61
|
-
yellowdog_python_examples-8.1.
|
|
62
|
-
yellowdog_python_examples-8.1.
|
|
63
|
-
yellowdog_python_examples-8.1.
|
|
64
|
-
yellowdog_python_examples-8.1.
|
|
59
|
+
yellowdog_python_examples-8.1.7.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
60
|
+
yellowdog_python_examples-8.1.7.dist-info/METADATA,sha256=5W5dmjQmQeHcAMN0ISUtdkZAez8yiFqxHS_8zyJ40Qw,3927
|
|
61
|
+
yellowdog_python_examples-8.1.7.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
62
|
+
yellowdog_python_examples-8.1.7.dist-info/entry_points.txt,sha256=KABYVOB3kO7kVqnUplNNoz4l36KUUVY05ynsZ9jSVL8,1016
|
|
63
|
+
yellowdog_python_examples-8.1.7.dist-info/top_level.txt,sha256=RfffFF4rsBrBbPB1qRkJsRpUn_5icIZSdCqMDLO3hgA,14
|
|
64
|
+
yellowdog_python_examples-8.1.7.dist-info/RECORD,,
|
{yellowdog_python_examples-8.1.6.dist-info → yellowdog_python_examples-8.1.7.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|