Relax floating point precision in sum tests#143641
Merged
kkrik-es merged 3 commits intoelastic:mainfrom Mar 5, 2026
Merged
Conversation
Collaborator
|
Pinging @elastic/es-storage-engine (Team:StorageEngine) |
kkrik-es
approved these changes
Mar 5, 2026
Updated the CSV specification to include events and pod information along with the time_bucket. Adjusted the format for bytes and time_bucket entries.
jfreden
pushed a commit
to jfreden/elasticsearch
that referenced
this pull request
Mar 5, 2026
* Relax floating point precision in sum tests * Refine byte values precision in CSV spec Updated precision of byte values in k8s-timeseries-avg-over-time.csv-spec. --------- Co-authored-by: Kostas Krikellas <131142368+kkrik-es@users.noreply.github.com>
spinscale
pushed a commit
to spinscale/elasticsearch
that referenced
this pull request
Mar 6, 2026
* Relax floating point precision in sum tests * Refine byte values precision in CSV spec Updated precision of byte values in k8s-timeseries-avg-over-time.csv-spec. --------- Co-authored-by: Kostas Krikellas <131142368+kkrik-es@users.noreply.github.com>
This was referenced Mar 6, 2026
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.
The new CsvIT tests don't force-merge the test indices, unlike SpecTestCase. I think this is more correct. However, some sum tests with time-series aggregations started failing. Previously, with a single segment, time-series data was scanned in tsid+timestamp order, so the sum always added values in the same order. With multiple segments, the values are the same but the summation order is no longer guaranteed, producing floating-point differences due to non-associativity. This affects tests with
sum(time-series-aggregation). This change relaxes the floating-point precision in these tests by rounding results to 6 decimal places. Once stable, we should also remove the force-merge in SpecTestCase.Closes #143292
Closes #143616
Closes #143617
Closes #143624
Closes #143625
Closes #143631
Closes #143632
Closes #143633
Closes #143634