Skip to content

Tests: fix wrong WaitGroup usage#5589

Merged
ruslan-mikhailov merged 2 commits intografana:mainfrom
ruslan-mikhailov:tests/fix-wg
Aug 28, 2025
Merged

Tests: fix wrong WaitGroup usage#5589
ruslan-mikhailov merged 2 commits intografana:mainfrom
ruslan-mikhailov:tests/fix-wg

Conversation

@ruslan-mikhailov
Copy link
Copy Markdown
Contributor

What this PR does: fixes wrong usage of WaitGroup. wg.Add need to use outside of goroutine otherwise it can lead to a race where wg.Wait() call happens before Add. Another example of race: https://github.com/grafana/tempo/actions/runs/17299036103/job/49104817911?pr=5581

Which issue(s) this PR fixes:
Fixes #

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

@ruslan-mikhailov ruslan-mikhailov changed the title Tests/fix wg Tests: fix wrong WaitGroup usage Aug 28, 2025
@ruslan-mikhailov ruslan-mikhailov marked this pull request as ready for review August 28, 2025 15:50
@ruslan-mikhailov ruslan-mikhailov enabled auto-merge (squash) August 28, 2025 15:54
@ruslan-mikhailov ruslan-mikhailov merged commit d4510bc into grafana:main Aug 28, 2025
22 checks passed
@ruslan-mikhailov ruslan-mikhailov deleted the tests/fix-wg branch April 21, 2026 08:19
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