:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
fix(tiktok_ads): retry internal service timeout code 51039 (#66311)
Tom Owers217ef75cdeca
diff --git a/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/test/test_tiktok_ads_utils.py b/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/test/test_tiktok_ads_utils.pyindex 567dbcf305c1..0ad0b5445acd 100644--- a/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/test/test_tiktok_ads_utils.py+++ b/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/test/test_tiktok_ads_utils.py@@ -737,6 +737,7 @@ class TestTikTokAdsPaginator:("validation_error", 40002, "Invalid parameter", False), # Client error - not retryable("server_error", 50000, "Internal server error", True),("internal_service_timeout", 51001, "internal service timeout", True), # Transient - retryable+ ("internal_service_timeout_51039", 51039, "internal service timeout", True), # Transient - retryable])def test_update_state_api_error_codes(self, name, api_code, message, should_be_retryable):diff --git a/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/utils.py b/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/utils.pyindex 782169b7358d..6772c88d9e3a 100644--- a/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/utils.py+++ b/products/warehouse_sources/backend/temporal/data_imports/sources/tiktok_ads/utils.py@@ -402,6 +402,7 @@ class TikTokAdsPaginator(BasePaginator):50000, # System error50002, # Error processing request on TikTok side. Please see error message for details.51001, # Internal service timeout. Transient TikTok-side error; safe to retry.+ 51039, # Internal service timeout. Transient TikTok-side error; safe to retry.51305, # Satellite service error60001, # The system is in maintenance.]