This commit is contained in:
space-nuko
2023-05-27 02:02:32 -05:00
parent 35b991728f
commit 17d6e68b75

View File

@@ -135,7 +135,7 @@ export type ComfyInterruptedError = {
} }
export type ComfyExecutionError = ComfyInterruptedError & { export type ComfyExecutionError = ComfyInterruptedError & {
message: string, exception_message: string,
exception_type: string, exception_type: string,
traceback: string[], traceback: string[],
current_inputs: any[], current_inputs: any[],
@@ -147,7 +147,7 @@ export function formatValidationError(error: ComfyAPIPromptErrorResponse) {
} }
export function formatExecutionError(error: ComfyExecutionError) { export function formatExecutionError(error: ComfyExecutionError) {
return `${error.message}` return error.exception_message
} }
export type ComfyGraphErrorInput = { export type ComfyGraphErrorInput = {
@@ -242,11 +242,11 @@ export function executionErrorToGraphErrors(workflowID: WorkflowInstID, executio
nodeID: executionError.node_id, nodeID: executionError.node_id,
comfyNodeType: executionError.node_type, comfyNodeType: executionError.node_type,
errorType: "execution", errorType: "execution",
message: executionError.message, message: executionError.exception_message,
dependentOutputs: [], // TODO dependentOutputs: [], // TODO
queueEntry, queueEntry,
exceptionMessage: executionError.message, exceptionMessage: executionError.exception_message,
exceptionType: executionError.exception_type, exceptionType: executionError.exception_type,
traceback: executionError.traceback, traceback: executionError.traceback,
inputValues: executionError.current_inputs, inputValues: executionError.current_inputs,
@@ -254,7 +254,7 @@ export function executionErrorToGraphErrors(workflowID: WorkflowInstID, executio
}] }]
return { return {
message: executionError.message, message: executionError.exception_message,
errors: Object.values(errorsByID).flatMap(e => e), errors: Object.values(errorsByID).flatMap(e => e),
errorsByID errorsByID
} }