@@ -601,21 +601,13 @@ def create_timer(self, fire_at: datetime.datetime) -> TaskBase:
601601 A Durable Timer Task that schedules the timer to wake up the activity
602602 """
603603 if self ._replay_schema .value >= ReplaySchema .V3 .value :
604- if not self ._maximum_short_timer_duration or not self ._long_timer_interval_duration :
605- raise Exception (
606- "A framework-internal error was detected: "
607- "replay schema version >= V3 is being used, "
608- "but one or more of the properties `maximumShortTimerDuration`"
609- "and `longRunningTimerIntervalDuration` are not defined. "
610- "This is likely an issue with the Durable Functions Extension. "
611- "Please report this bug here: "
612- "https://github.com/Azure/azure-functions-durable-python/issues\n "
613- f"maximumShortTimerDuration: { self ._maximum_short_timer_duration } \n "
614- f"longRunningTimerIntervalDuration: { self ._long_timer_interval_duration } "
615- )
616- if fire_at > self .current_utc_datetime + self ._maximum_short_timer_duration :
617- action = CreateTimerAction (fire_at )
618- return LongTimerTask (None , action , self )
604+ if self ._maximum_short_timer_duration and self ._long_timer_interval_duration :
605+ # These values not provided for DTS or MSSQL, so skip the LongTimerTask
606+ # and create the TimerTask as normal
607+
608+ if fire_at > self .current_utc_datetime + self ._maximum_short_timer_duration :
609+ action = CreateTimerAction (fire_at )
610+ return LongTimerTask (None , action , self )
619611
620612 action = CreateTimerAction (fire_at )
621613 task = self ._generate_task (action , task_constructor = TimerTask )
0 commit comments