Repository navigation
Make source rewrite tests work with coarse timestamps - #538
Merged
Merged
Conversation
On Linux before 6.13 (no multigrain timestamps) two writes in the same clock tick get the same ctime, so a same-size rewrite keeps the whole stat() identity and the tests can't see the change. Repeat the write until ctime moves on. Bump to 2.34.8.
Contributor
ReviewClean, minimal fix for Linux
|
Give up after 5 seconds with an AssertionError if ctime never changes, instead of looping forever.
Contributor
Author
|
Thanks, done: the helper is now in tests/common.py and the loop gives up after 5 seconds with an AssertionError.
Thanks, done: the helper is now in tests/common.py and the loop gives up after 5 seconds with an AssertionError. |
Contributor
|
LGTM on the test helper ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On kernels without multigrain timestamps (Linux < 6.13) a same-size rewrite in the same clock tick keeps the ctime, so four tests fail with "DID NOT RAISE" or read stale data. The tests now repeat the write until ctime changes. Test-only change, bumped to 2.34.8.
Found in a Debian rebuild on Linux 6.12: https://bugs.debian.org/1154342