From b937ff70bff56ddcf0a8a1dea443f42d78607aa8 Mon Sep 17 00:00:00 2001 From: fabiovincenzi <93596376+fabiovincenzi@users.noreply.github.com> Date: Mon, 10 Jun 2024 11:53:09 +0200 Subject: [PATCH] retrieve right description from tags (#97) --- src/src/services/models/runs/runDetailAppModel.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/src/services/models/runs/runDetailAppModel.ts b/src/src/services/models/runs/runDetailAppModel.ts index 7aaf6c41..9e817f2c 100644 --- a/src/src/services/models/runs/runDetailAppModel.ts +++ b/src/src/services/models/runs/runDetailAppModel.ts @@ -64,6 +64,7 @@ function getExperimentsData() { } function getRunInfo(runHash: string): IApiRequest { + const DESCRIPTION_TAG = 'mlflow.note.content'; if (getRunsInfoRequestRef) { getRunsInfoRequestRef.abort(); } @@ -74,6 +75,10 @@ function getRunInfo(runHash: string): IApiRequest { const data = await getRunsInfoRequestRef.call((detail: any) => { exceptionHandler({ detail, model }); }); + data.props.description = + DESCRIPTION_TAG in data.params.tags + ? data.params.tags[DESCRIPTION_TAG] + : ''; model.setState({ runParams: data.params, runTraces: data.traces, @@ -332,7 +337,7 @@ function editRunNameAndDescription( description, }, }); - if (res.id) { + if (res.ID) { onNotificationAdd({ id: Date.now(), severity: 'success',