镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

spanner.cloud-client.snippets_test: test_query_data_with_timestamp_parameter failed #4197

Closed

Description

@flaky-bot

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
Traceback (most recent call last):
  File "/workspace/spanner/cloud-client/snippets_test.py", line 358, 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 ''

Activity

  1. added
    priority: p1Important issue which blocks shipping the next release. Will be fixed prior to next release.
    type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.
    on Jun 29, 2020
  2. flaky-bot commented on Jun 29, 2020

    @flaky-bot
    Author

    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).

  3. self-assigned this
    on Jun 29, 2020
  4. tmatsuo commented on Jun 29, 2020

    @tmatsuo
    Contributor

    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.

  5. added a commit that references this issue on Jun 29, 2020
    fcf05ed
  6. added a commit that references this issue on Jun 29, 2020
    32f6dcc
  7. flaky-bot commented on Jul 3, 2020

    @flaky-bot
    Author

    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
    buildURL: Build Status, Sponge
    status: failed

    Test output
    Traceback (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 ''
  8. removed
    🚨This issue needs some love.
    priority: p1Important issue which blocks shipping the next release. Will be fixed prior to next release.
    on Jul 6, 2020
  9. 1 remaining item

  10. tmatsuo commented on Jul 6, 2020

    @tmatsuo
    Contributor

    Needs more investigation

  11. tmatsuo commented on Jul 8, 2020

    @tmatsuo
    Contributor

    @larkee

    test_query_data_with_timestamp_parameter occasionally fails. The output seems empty.

    Do you have any idea why this is happening?

  12. larkee commented on Jul 13, 2020

    @larkee
    Contributor

    There was a similar issue in Go: GoogleCloudPlatform/golang-samples#1146

    Basically, a time drift can happen between local machine and spanner servers. insert_datatypes_data uses the spanner server time for the commit timestamp while query_data_with_timestamp_parameter uses the local server time. This means if not enough time has passed, the local server time could still be less than the commit time which means no results are returned.

    To resolve this, a sleep delay needs to be added. I'll create the PR now.

  13. flaky-bot commented on Jul 20, 2020

    @flaky-bot
    Author

    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
    buildURL: Build Status, Sponge
    status: failed

    Test output
    Traceback (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 ''
  14. tmatsuo commented on Jul 20, 2020

    @tmatsuo
    Contributor

    Potentially we need longer sleep. Can we just use the future time instead of using the current time in the sample code?

  15. tmatsuo commented on Aug 5, 2020

    @tmatsuo
    Contributor

    I haven't seen this flake for a while. I'll close this and take care of it when we see this again.

  16. flaky-bot commented on Aug 10, 2020

    @flaky-bot
    Author

    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
    buildURL: Build Status, Sponge
    status: failed

    Test output
    Traceback (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 ''
  17. added a commit that references this issue on Aug 10, 2020
    5c271df
  18. added a commit that references this issue on Aug 13, 2020
    b523300
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

priority: p2Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions