Skip to content

Commit 59812d0

Browse files
committed
add inspector support
1 parent 311b43b commit 59812d0

File tree

1 file changed

+9
-0
lines changed
  • extensions/positron-python/python_files/posit/positron

1 file changed

+9
-0
lines changed

extensions/positron-python/python_files/posit/positron/inspectors.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1239,6 +1239,14 @@ def _is_active(self, value) -> bool:
12391239
return True
12401240

12411241

1242+
class BigQueryConnectionInspector(BaseConnectionInspector):
1243+
CLASS_QNAME = ("google.cloud.bigquery.client.Client",)
1244+
1245+
def _is_active(self, value) -> bool:
1246+
# a connection is always active if the client exists
1247+
return True
1248+
1249+
12421250
class IbisExprInspector(PositronInspector["ibis.Expr"]):
12431251
def has_children(self) -> bool:
12441252
return False
@@ -1280,6 +1288,7 @@ def to_plaintext(self) -> str:
12801288
**dict.fromkeys(IbisDataFrameInspector.CLASS_QNAME, IbisDataFrameInspector),
12811289
**dict.fromkeys(SnowflakeConnectionInspector.CLASS_QNAME, SnowflakeConnectionInspector),
12821290
**dict.fromkeys(DatabricksConnectionInspector.CLASS_QNAME, DatabricksConnectionInspector),
1291+
**dict.fromkeys(BigQueryConnectionInspector.CLASS_QNAME, BigQueryConnectionInspector),
12831292
"ibis.Expr": IbisExprInspector,
12841293
"boolean": BooleanInspector,
12851294
"bytes": BytesInspector,

0 commit comments

Comments
 (0)