( payload: ScheduleExecutionPayload, requestId: string )
| 261 | } |
| 262 | |
| 263 | async function calculateNextRunFromDeployment( |
| 264 | payload: ScheduleExecutionPayload, |
| 265 | requestId: string |
| 266 | ) { |
| 267 | try { |
| 268 | const deployedData = await loadDeployedWorkflowState(payload.workflowId) |
| 269 | return calculateNextRunTime(payload, deployedData.blocks as Record<string, BlockState>) |
| 270 | } catch (error) { |
| 271 | logger.warn( |
| 272 | `[${requestId}] Unable to calculate nextRunAt for schedule ${payload.scheduleId}`, |
| 273 | error |
| 274 | ) |
| 275 | return null |
| 276 | } |
| 277 | } |
| 278 | |
| 279 | async function determineNextRunAfterError( |
| 280 | payload: ScheduleExecutionPayload, |
no test coverage detected