From 18c5927f57af1ceadec96ba2a209f6a8aea7ba91 Mon Sep 17 00:00:00 2001 From: Paul D'Ambra Date: Thu, 30 Jun 2022 17:42:28 +0100 Subject: [PATCH] fix: celery autoimport was ignoring CSV exports (#10586) * launch celery with debug logging * autoimport a single task which decides what type of export to run * still need to manually inject root folder so tests can clear up * fix mock --- .run/Celery.run.xml | 4 +-- ee/tasks/subscriptions/subscription_utils.py | 4 +-- .../subscriptions/test_subscriptions_utils.py | 2 +- posthog/api/exports.py | 13 +++------- posthog/api/test/test_exports.py | 26 +++++++++---------- posthog/tasks/__init__.py | 5 ++-- posthog/tasks/exporter.py | 20 ++++++++++++++ posthog/tasks/exports/csv_exporter.py | 8 ++---- posthog/tasks/exports/insight_exporter.py | 7 ++--- posthog/tasks/test/test_exporter.py | 5 ++-- 10 files changed, 50 insertions(+), 44 deletions(-) create mode 100644 posthog/tasks/exporter.py diff --git a/.run/Celery.run.xml b/.run/Celery.run.xml index d56e8fe2bc6..91b0cf2c2ea 100644 --- a/.run/Celery.run.xml +++ b/.run/Celery.run.xml @@ -18,7 +18,7 @@