Skip to content

fix: fix flake in TestWorkspaceAgent_Metadata_CatchMemoryLeak #13553

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

Merged
merged 1 commit into from
Jun 12, 2024

Conversation

spikecurtis
Copy link
Contributor

@spikecurtis spikecurtis commented Jun 12, 2024

Fixes flake seen here: https://github.com/coder/coder/actions/runs/9461246505/job/26061605278

#13486 subtly changes the test so that post uses the new v2 Agent API, and when canceling context, there is a race condition where the yamux session underpinning the API can get torn down before the RPC processes the canceled context, yielding a different error response than the test was previously expecting.

I've refactored the test to just stop posting when the test finishes, rather than depend on a context cancel to end the posting goroutine.

Copy link
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @spikecurtis and the rest of your teammates on Graphite Graphite

@spikecurtis spikecurtis requested a review from mafredri June 12, 2024 11:50
@spikecurtis spikecurtis marked this pull request as ready for review June 12, 2024 11:51
Copy link
Member

@Emyrk Emyrk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Seen this fail a few times, appreciate the fix

@spikecurtis spikecurtis merged commit ba7d183 into main Jun 12, 2024
31 checks passed
@spikecurtis spikecurtis deleted the spike/flake-catch-memory-leak branch June 12, 2024 14:33
@github-actions github-actions bot locked and limited conversation to collaborators Jun 12, 2024
@dannykopping
Copy link
Contributor

Closes #13551

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants