Skip to content

fix: Use elements match in gapsBetweenTSDBsAndMetas test - #13722

Merged
salvacorts merged 1 commit into
mainfrom
salvacorts/blooms/fix-flacky-test
Jul 31, 2024
Merged

fix: Use elements match in gapsBetweenTSDBsAndMetas test#13722
salvacorts merged 1 commit into
mainfrom
salvacorts/blooms/fix-flacky-test

Conversation

@salvacorts

Copy link
Copy Markdown
Contributor

What this PR does / why we need it:
This test was sometimes failing with:

Error:      	Not equal: 
        	            	expected: []planner.tsdbGaps{planner.tsdbGaps{tsdbIdentifier:tsdb.SingleTenantTSDBIdentifier{exportTSInSecs:false, TS:time.Time{wall:0x0, ext:62135596800, loc:(*time.Location)(0x3baad[20](https://github.com/grafana/loki/actions/runs/10176790602/job/28150967362#step:5:21))}, From:0, Through:0, Checksum:0x0}, tsdb:common.ClosableForSeries(nil), gaps:[]v1.FingerprintBounds{v1.FingerprintBounds{Min:0x6, Max:0xa}}}, planner.tsdbGaps{tsdbIdentifier:tsdb.SingleTenantTSDBIdentifier{exportTSInSecs:false, TS:time.Time{wall:0x0, ext:62135596801, loc:(*time.Location)(0x3baad20)}, From:0, Through:0, Checksum:0x0}, tsdb:common.ClosableForSeries(nil), gaps:[]v1.FingerprintBounds{v1.FingerprintBounds{Min:0x9, Max:0xa}}}}
        	            	actual  : []planner.tsdbGaps{planner.tsdbGaps{tsdbIdentifier:tsdb.SingleTenantTSDBIdentifier{exportTSInSecs:false, TS:time.Time{wall:0x0, ext:62135596801, loc:(*time.Location)(0x3baad20)}, From:0, Through:0, Checksum:0x0}, tsdb:common.ClosableForSeries(nil), gaps:[]v1.FingerprintBounds{v1.FingerprintBounds{Min:0x9, Max:0xa}}}, planner.tsdbGaps{tsdbIdentifier:tsdb.SingleTenantTSDBIdentifier{exportTSInSecs:false, TS:time.Time{wall:0x0, ext:6[21](https://github.com/grafana/loki/actions/runs/10176790602/job/28150967362#step:5:22)35596800, loc:(*time.Location)(0x3baad20)}, From:0, Through:0, Checksum:0x0}, tsdb:common.ClosableForSeries(nil), gaps:[]v1.FingerprintBounds{v1.FingerprintBounds{Min:0x6, Max:0xa}}}}

Note that the content of both slices is the same but with a different order.

Checklist

  • Reviewed the CONTRIBUTING.md guide (required)
  • Documentation added
  • Tests updated
  • Title matches the required conventional commits format, see here
    • Note that Promtail is considered to be feature complete, and future development for logs collection will be in Grafana Alloy. As such, feat PRs are unlikely to be accepted unless a case can be made for the feature actually being a bug fix to existing behavior.
  • Changes that require user attention or interaction to upgrade are documented in docs/sources/setup/upgrade/_index.md
  • For Helm chart changes bump the Helm chart version in production/helm/loki/Chart.yaml and update production/helm/loki/CHANGELOG.md and production/helm/loki/README.md. Example PR
  • If the change is deprecating or removing a configuration option, update the deprecated-config.yaml and deleted-config.yaml files respectively in the tools/deprecated-config-checker directory. Example PR
@salvacorts
salvacorts marked this pull request as ready for review July 31, 2024 11:46
@salvacorts
salvacorts requested a review from a team as a code owner July 31, 2024 11:46
@salvacorts
salvacorts merged commit 4cbe2a6 into main Jul 31, 2024
@salvacorts
salvacorts deleted the salvacorts/blooms/fix-flacky-test branch July 31, 2024 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

2 participants