-
Notifications
You must be signed in to change notification settings - Fork 6.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
spanner.cloud-client.snippets_test: test_query_data_with_timestamp_parameter failed #4197
Comments
Looks like this issue is flaky. 😟 I'm going to leave this open and stop commenting. A human should fix and close this. When run at the same commit (3680196), this test passed in one build (Build Status, Sponge) and failed in another build (Build Status, Sponge). |
I'm not 100% confident, but the spanner tests has the following code: def unique_database_id():
""" Creates a unique id for the database. """
return 'test-db-{}'.format(''.join(random.choice(
string.ascii_lowercase + string.digits) for _ in range(5))) Is it possible that on multiple machines, random gets the same seed then we get the same random id? Anyways, maybe we can just use uuid4. |
fixes GoogleCloudPlatform#4197 (possibly)
Oops! Looks like this issue is still flaky. It failed again. 😬 I reopened the issue, but a human will need to close it again. commit: 51a66f9 Test outputTraceback (most recent call last): File "/workspace/spanner/cloud-client/snippets_test.py", line 356, in test_query_data_with_timestamp_parameter assert 'VenueId: 4, VenueName: Venue 4, LastUpdateTime:' in out AssertionError: assert 'VenueId: 4, VenueName: Venue 4, LastUpdateTime:' in '' |
Needs more investigation |
Do you have any idea why this is happening? |
There was a similar issue in Go: GoogleCloudPlatform/golang-samples#1146 Basically, a time drift can happen between local machine and spanner servers. To resolve this, a sleep delay needs to be added. I'll create the PR now. |
Oops! Looks like this issue is still flaky. It failed again. 😬 I reopened the issue, but a human will need to close it again. commit: 3e55269 Test outputTraceback (most recent call last): File "/workspace/spanner/cloud-client/snippets_test.py", line 371, in test_query_data_with_timestamp_parameter assert 'VenueId: 4, VenueName: Venue 4, LastUpdateTime:' in out AssertionError: assert 'VenueId: 4, VenueName: Venue 4, LastUpdateTime:' in '' |
Potentially we need longer sleep. Can we just use the future time instead of using the current time in the sample code? |
I haven't seen this flake for a while. I'll close this and take care of it when we see this again. |
Oops! Looks like this issue is still flaky. It failed again. 😬 I reopened the issue, but a human will need to close it again. commit: 2c0d10c Test outputTraceback (most recent call last): File "/workspace/spanner/cloud-client/snippets_test.py", line 371, in test_query_data_with_timestamp_parameter assert 'VenueId: 4, VenueName: Venue 4, LastUpdateTime:' in out AssertionError: assert 'VenueId: 4, VenueName: Venue 4, LastUpdateTime:' in '' |
Note: #3543 was also for this test, but it was closed more than 10 days ago. So, I didn't mark it flaky.
commit: 3680196
buildURL: Build Status, Sponge
status: failed
Test output
The text was updated successfully, but these errors were encountered: