Skip to content

Commit

Permalink
Logging: harden systest teardown against 'DeadlineExceeded' retry err…
Browse files Browse the repository at this point in the history
…ors.

Closes #6115.
  • Loading branch information
tseaver committed Oct 9, 2018
1 parent 75358e5 commit d8e2095
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion logging/tests/system/test_system.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
from google.api_core.exceptions import NotFound
from google.api_core.exceptions import TooManyRequests
from google.api_core.exceptions import ResourceExhausted
from google.api_core.exceptions import RetryError
from google.api_core.exceptions import ServiceUnavailable
from google.cloud._helpers import UTC
import google.cloud.logging
Expand Down Expand Up @@ -104,7 +105,8 @@ def setUp(self):
self._handlers_cache = logging.getLogger().handlers[:]

def tearDown(self):
retry = RetryErrors((NotFound, TooManyRequests), max_tries=9)
retry = RetryErrors(
(NotFound, TooManyRequests, RetryError), max_tries=9)
for doomed in self.to_delete:
try:
retry(doomed.delete)()
Expand Down

0 comments on commit d8e2095

Please sign in to comment.