yuseok89 commented on code in PR #75430:
URL: https://github.com/apache/airflow/pull/75430#discussion_r4368612872
##########
providers/google/src/airflow/providers/google/cloud/operators/bigquery.py:
##########
@@ -2633,8 +2640,18 @@ def get_job_status(self, external_id: JsonValue,
context: Any) -> str:
if self.project_id is None:
self.project_id = self.hook.project_id
+ location = self.location
+ if self.durable and (task_store := context.get("task_state_store")) is
not None:
+ saved_location = task_store.get("bigquery_job_location")
+ if (
+ isinstance(saved_location, dict)
+ and saved_location.get("job_id") == job_id
+ and isinstance(saved_location.get("location"), str)
+ ):
+ location = saved_location["location"]
+
try:
- job = self.hook.get_job(project_id=self.project_id,
location=self.location, job_id=job_id)
+ job = self.hook.get_job(project_id=self.project_id,
location=location, job_id=job_id)
Review Comment:
Sounds good, thanks for taking it on in a follow-up.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]