fix: getting_started notebook fails to remove connection created
shanecglass opened this issue · 0 comments
shanecglass commented
Thanks for stopping by to let us know something could be better!
PLEASE READ: If you have a support contract with Google, please create an issue in the support console instead of filing on GitHub. This will ensure a timely response.
Please run down the following list and make sure you've tried the usual "quick fixes":
- Search the issues already opened: https://github.com/googleapis/python-bigquery-dataframes/issues
- Search StackOverflow: https://stackoverflow.com/questions/tagged/google-cloud-platform+python
If you are still having issues, please be sure to include as much information as possible:
Environment details
- OS type and version: BigQuery Studio notebook
- Python version:
python --version
- pip version:
pip --version
bigframes
version:pip show bigframes
Steps to reproduce
- Execute the cell that to removes the BigQuery Connection created
- Cell fails to execute. This cell has the incorrect name of the default connection.
Code example
# Delete the BigQuery Connection
from google.cloud import bigquery_connection_v1 as bq_connection
client = bq_connection.ConnectionServiceClient()
CONNECTION_ID = f"projects/{PROJECT_ID}/locations/{REGION}/connections/bigframes-rf-conn"
client.delete_connection(name=CONNECTION_ID)
print("Deleted connection '{}'.".format(CONNECTION_ID))
Stack trace
---------------------------------------------------------------------------
_InactiveRpcError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/google/api_core/grpc_helpers.py in error_remapped_callable(*args, **kwargs)
71 try:
---> 72 return callable_(*args, **kwargs)
73 except grpc.RpcError as exc:
8 frames
_InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
status = StatusCode.NOT_FOUND
details = "Not found: Connection bigframes-rf-conn"
debug_error_string = "UNKNOWN:Error received from peer ipv4:74.125.200.95:443 {created_time:"2024-01-24T17:15:42.930219567+00:00", grpc_status:5, grpc_message:"Not found: Connection bigframes-rf-conn"}"
>
The above exception was the direct cause of the following exception:
NotFound Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/google/api_core/grpc_helpers.py in error_remapped_callable(*args, **kwargs)
72 return callable_(*args, **kwargs)
73 except grpc.RpcError as exc:
---> 74 raise exceptions.from_grpc_error(exc) from exc
75
76 return error_remapped_callable
NotFound: 404 Not found: Connection bigframes-rf-conn
Making sure to follow these steps will guarantee the quickest resolution possible.
Thanks!