Skip to content

flake: scaletest/createworkspaces: Test_Runner/CleanupPendingBuild: condition was never satisfied #324

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

Closed
johnstcn opened this issue Jan 27, 2025 · 2 comments · Fixed by coder/coder#16306
Assignees
Labels

Comments

@johnstcn
Copy link
Member

Seen here: https://github.com/coder/coder/actions/runs/12997421114/job/36248389337?pr=16303#step:8:872

    run_test.go:301: 
        	Error Trace:	/home/runner/work/coder/coder/scaletest/createworkspaces/run_test.go:301
        	Error:      	Condition never satisfied
        	Test:       	Test_Runner/CleanupPendingBuild

@johnstcn johnstcn added the flake label Jan 27, 2025
@johnstcn johnstcn self-assigned this Jan 27, 2025
@johnstcn
Copy link
Member Author

it me :(

@johnstcn
Copy link
Member Author

Seems to be a timing issue.

Workspace build job gets picked up by provisioner:

2025-01-27T20:17:23.9344000Z     t.go:106: 2025-01-27 20:16:39.628 [debu]  provisionerd: acquired job  initiator_username=scaletest-user  provisioner=echo  job_id=e24fcfcc-3a17-4959-a60e-b0f033507da9  workspace_transition=START  workspace_owner=scaletest-user  template_name=silly-banach0-HGP  template_version=interesting_mendeleev9  workspace_build_id=b8d1d3fe-f925-48bf-bbcc-cc1f21a8a770  workspace_id=e7376794-2663-49e8-8e63-44264d11d27c  workspace_name=test-7ab67965

Condition times out:

2025-01-27T20:17:23.9548868Z     t.go:106: 2025-01-27 20:16:49.489 [debu]  inmem-provisionerd-test: stage UpdateJob starting  job_id=e24fcfcc-3a17-4959-a60e-b0f033507da9
2025-01-27T20:17:23.9549268Z     run_test.go:301: 
2025-01-27T20:17:23.9549722Z         	Error Trace:	/home/runner/work/coder/coder/scaletest/createworkspaces/run_test.go:301
2025-01-27T20:17:23.9550124Z         	Error:      	Condition never satisfied
2025-01-27T20:17:23.9550439Z         	Test:       	Test_Runner/CleanupPendingBuild

And then the job is marked as 'canceled' shortly afterwards:

2025-01-27T20:17:23.9552371Z     t.go:106: 2025-01-27 20:16:49.598 [warn]  provisionerd.runner: apply failed; updating state  job_id=e24fcfcc-3a17-4959-a60e-b0f033507da9  template_name=silly-banach0-HGP  template_version=interesting_mendeleev9  workspace_build_id=b8d1d3fe-f925-48bf-bbcc-cc1f21a8a770  workspace_id=e7376794-2663-49e8-8e63-44264d11d27c  workspace_name=test-7ab67965  workspace_owner=scaletest-user  workspace_transition=start  error=canceled  state_len=0

aslilac pushed a commit to coder/coder that referenced this issue Jan 29, 2025
Fixes coder/internal#324

We had been using a `testutil.Context` in combination with a separate
`context.WithTimeout()` that smelled iffy to me.

Also reworked part of the second `require.Eventually` loop to pull a job
ID from the first one, and added some more logging to aid future
debugging.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant