Uh oh!
There was an error while loading. Please reload this page.
[kms] fix flaky test - #3268
Conversation
| self.symId) | ||
| except Aborted: | ||
| # aborted by backend. Try again | ||
| try_number += 1 |
There was a problem hiding this comment.
Maybe you want to use @eventually_consistent.call?
An example commit:
c6254e4
There was a problem hiding this comment.
+1 to using eventually consistent if you can
There was a problem hiding this comment.
I didn't know about @eventually_consistent, that's much cleaner!
| self.symId) | ||
| except Aborted: | ||
| # aborted by backend. Try again | ||
| try_number += 1 |
There was a problem hiding this comment.
+1 to using eventually consistent if you can
| if b.role == self.role and self.member in b.members: | ||
| found = True | ||
| assert found | ||
| eventually_consistent.call(check_policy, |
There was a problem hiding this comment.
Unfortunately the decorator form doesn't work with the current 0.0.15 release.
See: GoogleCloudPlatform/python-repo-tools#25
I'm trying to make a new release of the above module.
I'm fine with the current form :)
gguuss
left a comment
There was a problem hiding this comment.
LGTM, just some minor nits.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
tmatsuo
left a comment
There was a problem hiding this comment.
Please see my comment about exceptions tuple.
tmatsuo
commented
Apr 7, 2020
@dansanche Sorry for "hot" repo issue ;) I needed to rebase multiple times, but it's good to see the tests are more stable :) |
fixes#2970
I added exponential backoff to the policy test, as recommended by the error message