LLM-Driven Extraction of Unstructured Data — Built for API Deployments & ETL Pipeline Workflows
Python ai-agentsdata-engineeringdocument-aigenerative-aiidpjson-extractionllmmcp-serverocrpdf-extractionprompt-engineeringstructured-output
feat: Validation for cron string to be minimum an hour (#652)
Chandrasekharan M1f59635148c0
diff --git a/backend/pipeline/serializers/crud.py b/backend/pipeline/serializers/crud.pyindex 8278d0fa2..bc4c0cc61 100644--- a/backend/pipeline/serializers/crud.py+++ b/backend/pipeline/serializers/crud.py@@ -66,6 +66,15 @@ class PipelineSerializer(AuditSerializer):logger.error(f"Invalid cron string '{cron_string}': {error}")raise serializers.ValidationError("Invalid cron string format.")+ # Check if the frequency is less than 1 hour+ cron_parts = cron_string.split()+ minute_field = cron_parts[0]+ if minute_field == "*" or any(char in minute_field for char in [",", "-", "/"]):+ raise serializers.ValidationError(+ "Cron schedule can not be more than once per hour. Please provide a "+ "cron schedule to run at an hourly or less frequent interval."+ )+return cron_stringdef get_api_endpoint(self, instance: Pipeline):diff --git a/backend/workflow_manager/workflow/execution.py b/backend/workflow_manager/workflow/execution.pyindex c1514e9a1..bbdb89be6 100644--- a/backend/workflow_manager/workflow/execution.py+++ b/backend/workflow_manager/workflow/execution.py@@ -277,7 +277,7 @@ class WorkflowExecutionServiceHelper(WorkflowExecutionService):)self.publish_log(f"Total files: {total_files}, "- f"{successful_files} successfully executed and {failed_files} errored"+ f"{successful_files} successfully executed and {failed_files} errors")def publish_initial_tool_execution_logs(diff --git a/frontend/src/App.jsx b/frontend/src/App.jsxindex 747ec8364..9fbf63bee 100644--- a/frontend/src/App.jsx+++ b/frontend/src/App.jsx@@ -6,6 +6,7 @@ import { Router } from "./routes/Router.jsx";import { useAlertStore } from "./store/alert-store.js";import { useSessionStore } from "./store/session-store.js";import PostHogPageviewTracker from "./PostHogPageviewTracker.js";+import { useEffect } from "react";let GoogleTagManagerHelper;try {@@ -40,15 +41,18 @@ function App() {</>);- alertDetails.content &&+ useEffect(() => {+ if (!alertDetails?.content) return;+notificationAPI.open({- message: alertDetails.title,- description: alertDetails.content,- type: alertDetails.type,- duration: alertDetails.duration,+ message: alertDetails?.title,+ description: alertDetails?.content,+ type: alertDetails?.type,+ duration: alertDetails?.duration,btn,- key: alertDetails.key,+ key: alertDetails?.key,});+ }, [alertDetails]);return (<ConfigProviderdiff --git a/frontend/src/store/alert-store.js b/frontend/src/store/alert-store.jsindex b95a0b66b..d066368f8 100644--- a/frontend/src/store/alert-store.js+++ b/frontend/src/store/alert-store.js@@ -14,15 +14,15 @@ const useAlertStore = create((setState) => ({...STORE_VARIABLES,setAlertDetails: (details) => {setState(() => {+ if (!details) return STORE_VARIABLES;const isErrorType = details?.type === "error";- details["title"] =- details["title"] || (isErrorType ? "Failed" : "Success");- details["duration"] = isNonNegativeNumber(details.duration)- ? details.duration+ details["title"] = details?.title || (isErrorType ? "Failed" : "Success");+ details["duration"] = isNonNegativeNumber(details?.duration)+ ? details?.duration: isErrorType? 0: undefined;- details.key = `open${Date.now()}`;+ details["key"] = `open${Date.now()}`;return { alertDetails: { ...details } };});},