Skip to content
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

InstantTimeProviderTest.testInstantCurrentTimeNanos is consistently failing #11680

Open
ejona86 opened this issue Nov 11, 2024 · 6 comments
Open
Labels
highly flaky Issue is for a test that is crying wolf
Milestone

Comments

@ejona86
Copy link
Member

ejona86 commented Nov 11, 2024

Inside Google:

expected         : 1730533931622822000
but was          : 1730533931609013000
outside tolerance: 10000000
	at io.grpc.internal.InstantTimeProviderTest.testInstantCurrentTimeNanos(InstantTimeProviderTest.java:48)

Another arbitrary failure:

expected         : 1731147454282900000
but was          : 1731147454264246000

@vinodhabib
CC @kannanjgithub

@ejona86 ejona86 added the highly flaky Issue is for a test that is crying wolf label Nov 11, 2024
@ejona86 ejona86 added this to the Next milestone Nov 11, 2024
@ejona86
Copy link
Member Author

ejona86 commented Nov 11, 2024

These failures are when running with --config=tsan, which runs slower.

@vinodhabib
Copy link
Contributor

vinodhabib commented Nov 13, 2024

@ejona86 @shivaspeaks @kannanjgithub I went through the details and found like above scenarios mentioned in the issue details failed because the given tolerance time of 10 milliseconds exceeded in UT ( I,e first run/failure completed in 13 milliseconds and second completed in 18 milliseconds as mentioned below).

1730533931622822000 -> November 2, 2024 1:22:11.622 PM
1730533931609013000 -> November 2, 2024 1:22:11.609 PM
tolerance time - 13 milliseconds

1731147454282900000 -> November 9, 2024 3:47:34.282 PM
1731147454264246000 -> November 9, 2024 3:47:34.264 PM
tolerance time - 18 milliseconds

As per my Analysis we can update the tolerance value to 50 from 10 milliseconds to resolve this issue, Please confirm?

@kannanjgithub
Copy link
Contributor

With 50ms it still failed 3 / 1000 times (Google internal test run)

With 75ms it still failed but only for 10 / 10000 (Google internal test run).

I think we can set the tolerance as 75ms.

@ejona86
Copy link
Member Author

ejona86 commented Nov 13, 2024

How about setting it to 100 ms or 1 second, so we don't deal with it again? 75 ms is already too large to notice precision issues, so I'm not sure what we gain by using 75 ms instead of 1 second.

@ejona86
Copy link
Member Author

ejona86 commented Nov 14, 2024

This recently flaked when not running with TSAN. http://sponge2/973b69a4-998c-457f-a496-c49bc8c3eef0

@kannanjgithub
Copy link
Contributor

Yes, lets make it 1s. @vinodhabib

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
highly flaky Issue is for a test that is crying wolf
Projects
None yet
Development

No branches or pull requests

3 participants