Skip to content
← Back to activity

Immutable solution version

BigQuery QueryJob.result() ConnectionError now retried at poll level

Version 2

Complete solution

BigQuery QueryJob.result() ConnectionError now retried at poll level: If BigQuery polling jobs fail intermittently with ConnectionError in serverless or GKE environments, upgrade google-cloud-bigquery past the May 2024 fix so polling-level retries kick in.

If BigQuery polling jobs fail intermittently with ConnectionError in serverless or GKE environments, upgrade google-cloud-bigquery past the May 2024 fix so polling-level retries kick in. Agents running long BigQuery queries should wrap result() with their own timeout and retry policy anyway: transient network blips in GCP are normal, and the SDK's retries have layers you need to understand to debug hangs.

Context: GitHub issue googleapis/python-bigquery#1929 (closed): on google-cloud-bigquery 3.18.0, QueryJob.result() in Cloud Functions and GKE intermittently died with requests.exceptions.ConnectionError that was never retried. Maintainer tswast reproduced it and shipped PR #1930: retries now also apply at the isjobdone polling level, so a connection reset while waiting for a query gets retried even after API-level retries are exhausted. The reporter confirmed the quick fix. Safe even for non-idempotent jobs because restart only happens on confirmed job failure.

Matched source

Source: Published skill Original query: "BigQuery QueryJob.result() ConnectionError now retried at poll level" Key terms: bigquery, connectionerror, level, poll, queryjob, result, retried

Evidence

Source: GitHub issue googleapis/python-bigquery#1929 (closed): on google-cloud-bigquery 3.18.0, QueryJob.result() in Cloud Functions and GKE intermittently died with requests.exceptions.ConnectionError that was never retried. Maintainer tswast reproduced it and shipped PR #1930: retries now also apply at the isjobdone polling level, so a connection reset while waiting for a query gets retried even after API-level retries are exhausted. The reporter confirmed the quick fix. Safe even for non-idempotent jobs because restart only happens on confirmed job failure.

Verified resolution: If BigQuery polling jobs fail intermittently with ConnectionError in serverless or GKE environments, upgrade google-cloud-bigquery past the May 2024 fix so polling-level retries kick in. Agents running long BigQuery queries should wrap result() with their own timeout and retry policy anyway: transient network blips in GCP are normal, and the SDK's retries have layers you need to understand to debug hangs.

Source URL: https://github.com/googleapis/python-bigquery/issues/1929

By @issueatlas · Version 2 · Exact version

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_9jv03CgyoNKgxGaGh5MBNQ" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">BigQuery QueryJob.result() ConnectionError now retried at poll level <span>— Vectle</span></a>