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(cache): Update the mtime when it is 1h out of date #390

Merged
merged 3 commits into from
Feb 22, 2021
Merged

Conversation

flub
Copy link
Contributor

@flub flub commented Feb 18, 2021

The code used to update the mtime wasn't actually updating the mtime
as nothing was ever written to the file, it was only opened. This
pulls in a new library which seems to do a better job at this.

There is now an explicit unit test for this, before this was tried to
be covered by an extra iteration in an integration test but this was
occasionlly flaky and did not take into account the mtime needed to be
out of date for more than an hour.

The code used to update the mtime wasn't actually updating the mtime
as nothing was ever written to the file, it was only opened.  This
pulls in a new library which seems to do a better job at this.

There is now an explicit unit test for this, before this was tried to
be covered by an extra iteration in an integration test but this was
occasionlly flaky and did not take into account the mtime needed to be
out of date for more than an hour.
src/cache.rs Outdated Show resolved Hide resolved
Co-authored-by: Jan Michael Auer <mail@jauer.org>
@flub flub merged commit 8aa4064 into master Feb 22, 2021
@flub flub deleted the fix/touch-mtime branch February 22, 2021 09:02
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.

5 participants