chore: toast message on model import fail with reason (#3276)
This commit is contained in:
parent
d074a5a445
commit
3bebdfe67e
@ -5,6 +5,8 @@ import { useAtomValue, useSetAtom } from 'jotai'
|
|||||||
|
|
||||||
import { AlertCircle } from 'lucide-react'
|
import { AlertCircle } from 'lucide-react'
|
||||||
|
|
||||||
|
import { toaster } from '@/containers/Toast'
|
||||||
|
|
||||||
import useCortex from '@/hooks/useCortex'
|
import useCortex from '@/hooks/useCortex'
|
||||||
import {
|
import {
|
||||||
getImportModelStageAtom,
|
getImportModelStageAtom,
|
||||||
@ -41,6 +43,11 @@ const ImportingModelModal = () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
setImportModelError(model.path, errorMessage)
|
setImportModelError(model.path, errorMessage)
|
||||||
|
toaster({
|
||||||
|
title: 'Import failed',
|
||||||
|
description: errorMessage,
|
||||||
|
type: 'error',
|
||||||
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user