From b8b5341c08500f394a0a4093826978360cae9985 Mon Sep 17 00:00:00 2001 From: Stefan Nica Date: Fri, 24 Jan 2025 09:26:40 +0100 Subject: [PATCH] Fix sagemaker --- .../aws/orchestrators/sagemaker_orchestrator.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/zenml/integrations/aws/orchestrators/sagemaker_orchestrator.py b/src/zenml/integrations/aws/orchestrators/sagemaker_orchestrator.py index 164192f979..52ba430b08 100644 --- a/src/zenml/integrations/aws/orchestrators/sagemaker_orchestrator.py +++ b/src/zenml/integrations/aws/orchestrators/sagemaker_orchestrator.py @@ -15,7 +15,7 @@ import os import re -from datetime import timezone +from datetime import datetime, timezone from typing import ( TYPE_CHECKING, Any, @@ -64,7 +64,6 @@ from zenml.orchestrators.utils import get_orchestrator_run_name from zenml.stack import StackValidator from zenml.utils.env_utils import split_environment_variables -from zenml.utils.time_utils import utc_now if TYPE_CHECKING: from zenml.models import PipelineDeploymentResponse, PipelineRunResponse @@ -554,7 +553,8 @@ def prepare_or_run_pipeline( enabled=True, ) next_execution = ( - deployment.schedule.start_time or utc_now() + deployment.schedule.start_time + or datetime.now(timezone.utc) ) + deployment.schedule.interval_second else: # One-time schedule