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

Fix flaky tests #94

Merged
merged 7 commits into from
Feb 15, 2024
Merged

Fix flaky tests #94

merged 7 commits into from
Feb 15, 2024

Conversation

jmglov
Copy link
Contributor

@jmglov jmglov commented Feb 15, 2024

Please answer the following questions and leave the below in as part of your PR.

@borkdude
Copy link
Owner

Can you explain the changes in this PR?
Why is there a file removed from the function? Why is Thread/sleep added?

@jmglov
Copy link
Contributor Author

jmglov commented Feb 15, 2024

The this-file thing never actually worked, so I removed it as extraneous.

The sleeps are there to ensure that on a fast machine, at least a millisecond will have passed since the last time a file was written so the last modified timestamp won't accidentally be the same. This is my theory for why these tests were flaky on CI but not on my laptop.

Sleeping 500 ms is probably excessive, but I just wanted to be safe. Should I dial that down to 5 ms or something?

@borkdude
Copy link
Owner

yeah, ok, let's do 5ms :)

@borkdude borkdude merged commit 273f453 into borkdude:main Feb 15, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants