Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit8282393

Browse files
authored
fix: Bump up workspace history timeout (#149)
This is an attempted fix for failures like:https://github.com/coder/coder/runs/5043435263?check_suite_focus=true#step:7:32Looking at the timing of the test:``` t.go:56: 2022-02-02 21:33:21.964 [DEBUG](terraform-provisioner)<provision.go:139>ran apply t.go:56: 2022-02-02 21:33:21.991 [DEBUG](provisionerd)<provisionerd.go:162>skipping acquire; job is already running t.go:56: 2022-02-02 21:33:22.050 [DEBUG](provisionerd)<provisionerd.go:162>skipping acquire; job is already running t.go:56: 2022-02-02 21:33:22.090 [DEBUG](provisionerd)<provisionerd.go:162>skipping acquire; job is already running t.go:56: 2022-02-02 21:33:22.140 [DEBUG](provisionerd)<provisionerd.go:162>skipping acquire; job is already running t.go:56: 2022-02-02 21:33:22.195 [DEBUG](provisionerd)<provisionerd.go:162>skipping acquire; job is already running t.go:56: 2022-02-02 21:33:22.240 [DEBUG](provisionerd)<provisionerd.go:162>skipping acquire; job is already running workspacehistory_test.go:122: Error Trace:workspacehistory_test.go:122 Error: Condition never satisfied Test: TestWorkspaceHistory/CreateHistory```It appears that the `terraform apply` job had just finished - with less than a second to spare until our `require.Eventually` completes - but there's still work to be done (ie, collecting the state files). So my suspicion is that terraform might, in some cases, exceed our 5s timeout.Note that in the setup for this test - there is a similar project history wait that waits for 15s, so I borrowed that here.In the future - we can look at potentially using a simple echo provider to exercise this in the unit test, in a way that is more reliable in terms of timing. I'll log an issue to track that.
1 parent9cc4756 commit8282393

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎coderd/workspacehistory_test.go‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ func TestWorkspaceHistory(t *testing.T) {
123123
workspaceHistory,err=server.Client.WorkspaceHistory(context.Background(),"",workspace.Name,"")
124124
require.NoError(t,err)
125125
returnworkspaceHistory.Provision.Status.Completed()
126-
},5*time.Second,50*time.Millisecond)
126+
},15*time.Second,50*time.Millisecond)
127127
require.Equal(t,"",workspaceHistory.Provision.Error)
128128
require.Equal(t,coderd.ProvisionerJobStatusSucceeded,workspaceHistory.Provision.Status)
129129
})

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp