Skip to content

Commit

Permalink
BQ exception should be raised first before we check the timedout (fea…
Browse files Browse the repository at this point in the history
…st-dev#1675)

Signed-off-by: Matt Delacour <[email protected]>
Signed-off-by: Mwad22 <[email protected]>
  • Loading branch information
MattDelac authored and Mwad22 committed Jul 7, 2021
1 parent d36d1a0 commit 651bce3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions sdk/python/feast/infra/offline_stores/bigquery.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,13 +288,13 @@ def _wait_until_done(job_id):
job_id = bq_job.job_id
_wait_until_done(job_id=job_id)

if bq_job.exception():
raise bq_job.exception()

if not _is_done(job_id):
client.cancel_job(job_id)
raise BigQueryJobCancelled(job_id=job_id)

if bq_job.exception():
raise bq_job.exception()


@dataclass(frozen=True)
class FeatureViewQueryContext:
Expand Down

0 comments on commit 651bce3

Please sign in to comment.