Skip to content

Commit a99b6dd

Browse files
committed
Return timeout on start context
1 parent f866a92 commit a99b6dd

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

agent/agentscripts/agentscripts.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,9 @@ func (r *Runner) run(ctx context.Context, script codersdk.WorkspaceAgentScript)
202202

203203
err = cmd.Start()
204204
if err != nil {
205+
if errors.Is(err, context.DeadlineExceeded) {
206+
return ErrTimeout
207+
}
205208
return xerrors.Errorf("%s script: start command: %w", logPath, err)
206209
}
207210

0 commit comments

Comments
 (0)