Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions sdks/python/apache_beam/io/gcp/bigtableio_it_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

# Protect against environments where bigtable library is not available.
try:
from apitools.base.py.exceptions import HttpError
from google.api_core.exceptions import GoogleAPICallError
from google.cloud.bigtable import client
from google.cloud.bigtable.row import Cell
from google.cloud.bigtable.row import DirectRow
Expand All @@ -48,7 +48,7 @@
from google.cloud.bigtable_admin_v2.types import instance
except ImportError as e:
client = None
HttpError = None
GoogleAPICallError = None


def instance_prefix(instance):
Expand Down Expand Up @@ -109,7 +109,7 @@ def tearDown(self):
self.instance.instance_id)
self.table.delete()
self.instance.delete()
except HttpError:
except GoogleAPICallError:
_LOGGER.warning(
"Failed to clean up table [%s] and instance [%s]",
self.table.table_id,
Expand Down Expand Up @@ -208,15 +208,15 @@ def tearDown(self):
try:
_LOGGER.info("Deleting table [%s]", self.table.table_id)
self.table.delete()
except HttpError:
except GoogleAPICallError:
_LOGGER.warning("Failed to clean up table [%s]", self.table.table_id)

@classmethod
def tearDownClass(cls):
try:
_LOGGER.info("Deleting instance [%s]", cls.instance.instance_id)
cls.instance.delete()
except HttpError:
except GoogleAPICallError:
_LOGGER.warning(
"Failed to clean up instance [%s]", cls.instance.instance_id)

Expand Down
Loading