We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9d4b2ef commit 6d11787Copy full SHA for 6d11787
src/dstack/_internal/core/backends/datacrunch/compute.py
@@ -161,7 +161,10 @@ def terminate_instance(
161
try:
162
self.client.instances.action(id_list=[instance_id], action="delete")
163
except APIException as e:
164
- if e.message == "Invalid instance id":
+ if e.message in [
165
+ "Invalid instance id",
166
+ "Can't discontinue a discontinued instance",
167
+ ]:
168
logger.debug("Skipping instance %s termination. Instance not found.", instance_id)
169
return
170
raise
0 commit comments