From 3973f212c865541e78afa16485cc23a8f6bd8b5e Mon Sep 17 00:00:00 2001 From: Brett Hoerner Date: Mon, 18 Mar 2024 14:46:12 -0600 Subject: [PATCH] fix(batch-exports): handle null end_at in workflow_id (#20988) --- posthog/batch_exports/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/posthog/batch_exports/models.py b/posthog/batch_exports/models.py index 35fa6e8ba4754..70b85c4d35bde 100644 --- a/posthog/batch_exports/models.py +++ b/posthog/batch_exports/models.py @@ -306,5 +306,5 @@ class Status(models.TextChoices): def workflow_id(self) -> str: """Return the Workflow id that corresponds to this BatchExportBackfill model.""" start_at = self.start_at.strftime("%Y-%m-%dT%H:%M:%S") - end_at = self.end_at.strftime("%Y-%m-%dT%H:%M:%S") + end_at = self.end_at and self.end_at.strftime("%Y-%m-%dT%H:%M:%S") return f"{self.batch_export.id}-Backfill-{start_at}-{end_at}"