Skip to content

Commit 6887797

Browse files
[UX]: Make run status in UI and CLI easier to understand #2716
1 parent fdad550 commit 6887797

1 file changed

Lines changed: 0 additions & 16 deletions

File tree

  • src/dstack/_internal/cli/utils

src/dstack/_internal/cli/utils/run.py

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
TerminationPolicy,
1313
)
1414
from dstack._internal.core.models.runs import (
15-
Job,
1615
RunPlan,
1716
)
1817
from dstack._internal.core.services.profiles import get_termination
@@ -211,18 +210,3 @@ def get_runs_table(
211210
add_row_from_dict(table, job_row, style="secondary" if len(run.jobs) != 1 else None)
212211

213212
return table
214-
215-
216-
def _get_run_error(run: Run) -> str:
217-
return run._run.error or ""
218-
219-
220-
def _get_job_error(job: Job) -> str:
221-
job_submission = job.job_submissions[-1]
222-
termination_reason = job_submission.termination_reason
223-
exit_status = job_submission.exit_status
224-
if termination_reason is None:
225-
return ""
226-
if exit_status:
227-
return f"{termination_reason.name} {exit_status}"
228-
return termination_reason.name

0 commit comments

Comments
 (0)