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

Flaky test failure: test_ki_wakes_us_up on Windows #624

Closed
njsmith opened this issue Aug 23, 2018 · 1 comment
Closed

Flaky test failure: test_ki_wakes_us_up on Windows #624

njsmith opened this issue Aug 23, 2018 · 1 comment

Comments

@njsmith
Copy link
Member

njsmith commented Aug 23, 2018

As noticed by @Fuyukai:

https://ci.appveyor.com/project/njsmith/trio/build/1.0.1302/job/nm14lkm4vpwgk6yw

I think this is the same issue we ran into here: #575 (comment)

Basically on Windows, time.sleep and time.monotonic use slightly different clocks, so it's possible to do time.sleep(1) and then have time.monotonic report that slightly less than 1 second has passed. (trio.sleep doesn't have this problem, fortunately ­– only time.sleep does.)

For this particular test, the timing isn't too important – the only reason we check is to make sure that we notice in case something weird happens and its taking like, tens of seconds.

So the easy solution is: make it time.sleep(1.1) (with a comment back to this issue!) and move on with our lives.

@wgwz
Copy link
Contributor

wgwz commented Oct 6, 2018

Hey! So I implemented a fix for this in #723. Let me know if I should do anything else. :-)

@njsmith njsmith closed this as completed Oct 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants