diff --git a/src/locales/en/main.json b/src/locales/en/main.json index 8fdbe470a0..31cdd0c214 100644 --- a/src/locales/en/main.json +++ b/src/locales/en/main.json @@ -2499,6 +2499,10 @@ "errorUnsafePickleScan": "CivitAI detected potentially unsafe code in this file", "errorUnsafeVirusScan": "CivitAI detected malware or suspicious content in this file", "errorUploadFailed": "Failed to import asset. Please try again.", + "invalidAsset": "Invalid Asset", + "invalidAssetDetail": "The selected asset could not be validated. Please try again.", + "invalidFilename": "Invalid Filename", + "invalidFilenameDetail": "The asset filename could not be determined. Please try again.", "failedToCreateNode": "Failed to create node. Please try again or check console for details.", "fileFormats": "File formats", "fileName": "File Name", diff --git a/src/platform/assets/utils/createAssetWidget.ts b/src/platform/assets/utils/createAssetWidget.ts index d63c82e70e..6f23286a21 100644 --- a/src/platform/assets/utils/createAssetWidget.ts +++ b/src/platform/assets/utils/createAssetWidget.ts @@ -9,6 +9,7 @@ import { assetFilenameSchema, assetItemSchema } from '@/platform/assets/schemas/assetSchema' +import { useToastStore } from '@/platform/updates/common/toastStore' import { getAssetFilename } from '@/platform/assets/utils/assetMetadataUtils' interface CreateAssetWidgetParams { @@ -45,6 +46,8 @@ export function createAssetWidget( const assetBrowserDialog = useAssetBrowserDialog() async function openModal(widget: IBaseWidget) { + const toastStore = useToastStore() + await assetBrowserDialog.show({ nodeType: nodeTypeForBrowser, inputName: widgetName, @@ -59,6 +62,12 @@ export function createAssetWidget( 'Received:', asset ) + toastStore.add({ + severity: 'error', + summary: t('assetBrowser.invalidAsset'), + detail: t('assetBrowser.invalidAssetDetail'), + life: 5000 + }) return } @@ -72,6 +81,12 @@ export function createAssetWidget( 'for asset:', validatedAsset.data.id ) + toastStore.add({ + severity: 'error', + summary: t('assetBrowser.invalidFilename'), + detail: t('assetBrowser.invalidFilenameDetail'), + life: 5000 + }) return } diff --git a/todo.md b/todo.md deleted file mode 100644 index efa1111e02..0000000000 --- a/todo.md +++ /dev/null @@ -1,34 +0,0 @@ -# Bug Description - -When using a primitive node to select a model, this causes an issue specifically on Comfy Cloud. The issue does not appear to occur in the local version. - -## Context - -This bug was reported in the #frontend-bug-dump channel with reference links to Slack thread discussions: - -- https://comfy-organization.slack.com/archives/C07RCREPL67/p1767751867519549?thread_ts=1767751129.592359&cid=C07RCREPL67 -- https://comfy-organization.slack.com/archives/C07RCREPL67/p1767752100115359?thread_ts=1767751129.592359&cid=C07RCREPL67 - -## Reproduction - -The issue is triggered when a model is selected by a primitive node in workflows running on the cloud. - -## Expected Behavior - -Model selection via primitive nodes should work consistently between local and cloud environments. - -## Actual Behavior - -An issue occurs on cloud when using primitive nodes for model selection. - -## Additional Information - -### Related Bug Ticket - -Another bug ticket was created here: https://comfy-organization.slack.com/archives/C09FY39CC3V/p1767753991406309?thread_ts=1767734275.051999&cid=C09FY39CC3V - -### Updated Reproduction Details - -**Important:** This workflow didn't include any primitive nodes, but still caused the same issue. This indicates the problem is not limited to primitive nodes as originally thought. - -**Affected Workflow File:** video*ltx2*t2v_distilled.json (provided in Slack thread)