From 7547e9f8c3fd999c088361da04e1123276de8836 Mon Sep 17 00:00:00 2001 From: Dery Rahman Ahaddienata Date: Wed, 24 Apr 2024 08:41:23 +0700 Subject: [PATCH] fix: assigned retry object --- task/bq2bq/executor/bumblebee/bigquery_service.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/task/bq2bq/executor/bumblebee/bigquery_service.py b/task/bq2bq/executor/bumblebee/bigquery_service.py index ccf767b..c1df035 100644 --- a/task/bq2bq/executor/bumblebee/bigquery_service.py +++ b/task/bq2bq/executor/bumblebee/bigquery_service.py @@ -70,11 +70,11 @@ def __init__(self, client, labels, writer, retry_timeout = None, on_job_finish = if_additional_transient_error = if_exception_type( requests.exceptions.Timeout, requests.exceptions.SSLError, + BadRequest, ) predicate = if_exception_funcs(if_transient_error, if_additional_transient_error) retry = bigquery.DEFAULT_RETRY.with_deadline(retry_timeout) if retry_timeout else bigquery.DEFAULT_RETRY - retry.with_predicate(predicate) - self.retry = retry + self.retry = retry.with_predicate(predicate) self.on_job_finish = on_job_finish self.on_job_register = on_job_register