chore: add placeholder transformation function for packages error message (#35086)
## Description Adds placeholder functions to transform trigger eval error in EE PR for https://github.com/appsmithorg/appsmith-ee/pull/4695 ## Automation /ok-to-test tags="@tag.All" ### 🔍 Cypress test results <!-- This is an auto-generated comment: Cypress test results --> > [!TIP] > 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉 > Workflow run: <https://github.com/appsmithorg/appsmith/actions/runs/10040597202> > Commit: 784d698f1d7761af54b9b7e4061b77ef98cd3ce4 > <a href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10040597202&attempt=1" target="_blank">Cypress dashboard</a>. > Tags: `@tag.All` > Spec: > <hr>Mon, 22 Jul 2024 13:11:23 UTC <!-- end of auto-generated comment: Cypress test results --> ## Communication Should the DevRel and Marketing teams inform users about this change? - [ ] Yes - [ ] No <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Introduced a new function for processing evaluation errors, enhancing error management capabilities. - Improved error handling in the evaluation process for better debugging and clarity. - **Bug Fixes** - Enhanced type safety and clarity by incorporating new type definitions related to evaluation errors. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
parent
5127005129
commit
b9c5a4f2ef
|
|
@ -3,6 +3,7 @@ import { CreateNewActionKey } from "@appsmith/entities/Engine/actionHelpers";
|
|||
import type { DeleteErrorLogPayload } from "actions/debuggerActions";
|
||||
import type { Action } from "entities/Action";
|
||||
import type { Log } from "entities/AppsmithConsole";
|
||||
import type { EvaluationError } from "utils/DynamicBindingUtils";
|
||||
|
||||
export interface ResolveParentEntityMetadataReturnType {
|
||||
parentEntityId?: string;
|
||||
|
|
@ -30,3 +31,7 @@ export function* transformAddErrorLogsSaga(logs: Log[]) {
|
|||
export function* transformDeleteErrorLogsSaga(payload: DeleteErrorLogPayload) {
|
||||
return payload;
|
||||
}
|
||||
|
||||
export function* transformTriggerEvalErrors(errors: EvaluationError[]) {
|
||||
return errors;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -113,6 +113,7 @@ import { getIsCurrentEditorWorkflowType } from "@appsmith/selectors/workflowSele
|
|||
import { evalErrorHandler } from "./EvalErrorHandler";
|
||||
import AnalyticsUtil from "@appsmith/utils/AnalyticsUtil";
|
||||
import { endSpan, startRootSpan } from "UITelemetry/generateTraces";
|
||||
import { transformTriggerEvalErrors } from "@appsmith/sagas/helpers";
|
||||
|
||||
const APPSMITH_CONFIGS = getAppsmithConfigs();
|
||||
export const evalWorker = new GracefulWorkerService(
|
||||
|
|
@ -351,10 +352,16 @@ export function* evaluateAndExecuteDynamicTrigger(
|
|||
},
|
||||
);
|
||||
const { errors = [] } = response as any;
|
||||
yield call(dynamicTriggerErrorHandler, errors);
|
||||
|
||||
const transformedErrors: EvaluationError[] = yield call(
|
||||
transformTriggerEvalErrors,
|
||||
errors,
|
||||
);
|
||||
|
||||
yield call(dynamicTriggerErrorHandler, transformedErrors);
|
||||
yield fork(logDynamicTriggerExecution, {
|
||||
dynamicTrigger,
|
||||
errors,
|
||||
errors: transformedErrors,
|
||||
triggerMeta,
|
||||
});
|
||||
return response;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user