Skip to content

Commit

Permalink
[ML] Fix the model state column in the Trained Models UI (#169068)
Browse files Browse the repository at this point in the history
## Summary

Fixes an issue when the `Ready to deploy` download state was overriding
the `starting` and `stopping` deployment states.
  • Loading branch information
darnautov authored Oct 17, 2023
1 parent 9e951f5 commit 3164eca
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ import {
BUILT_IN_MODEL_TAG,
BUILT_IN_MODEL_TYPE,
DEPLOYMENT_STATE,
DeploymentState,
ELASTIC_MODEL_DEFINITIONS,
ELASTIC_MODEL_TAG,
ELASTIC_MODEL_TYPE,
Expand Down Expand Up @@ -349,7 +350,7 @@ export const ModelsList: FC<Props> = ({
);
if (elasticModels.length > 0) {
for (const model of elasticModels) {
if (model.state === MODEL_STATE.STARTED) {
if (Object.values(DEPLOYMENT_STATE).includes(model.state as DeploymentState)) {
// no need to check for the download status if the model has been deployed
continue;
}
Expand Down

0 comments on commit 3164eca

Please sign in to comment.