Skip to content

Commit 2660dbd

Browse files
authored
fix: correct type checking (#1848)
Correct the way we check whether `self._done_timeout` is an instance of `object` class or not. Fixes #1838 🦕
1 parent 641a712 commit 2660dbd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

google/cloud/bigquery/job/query.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1409,9 +1409,9 @@ def _reload_query_results(
14091409
# Python_API_core, as part of a major rewrite of the deadline, timeout,
14101410
# retry process sets the timeout value as a Python object().
14111411
# Our system does not natively handle that and instead expects
1412-
# either none or a numeric value. If passed a Python object, convert to
1412+
# either None or a numeric value. If passed a Python object, convert to
14131413
# None.
1414-
if isinstance(self._done_timeout, object): # pragma: NO COVER
1414+
if type(self._done_timeout) is object: # pragma: NO COVER
14151415
self._done_timeout = None
14161416

14171417
if self._done_timeout is not None: # pragma: NO COVER

0 commit comments

Comments
 (0)