Index: scheduler/appengine/task/swarming/swarming.go |
diff --git a/scheduler/appengine/task/swarming/swarming.go b/scheduler/appengine/task/swarming/swarming.go |
index 20928c55790c3645d5768e2d97994c94ad8302bb..8fbec30ecc01a9edbd03e454103f30ccb976ea6a 100644 |
--- a/scheduler/appengine/task/swarming/swarming.go |
+++ b/scheduler/appengine/task/swarming/swarming.go |
@@ -18,6 +18,7 @@ import ( |
"github.com/luci/gae/service/info" |
"github.com/luci/luci-go/common/api/swarming/swarming/v1" |
"github.com/luci/luci-go/common/errors" |
+ "github.com/luci/luci-go/common/retry/transient" |
"github.com/luci/luci-go/scheduler/appengine/messages" |
"github.com/luci/luci-go/scheduler/appengine/task" |
"github.com/luci/luci-go/scheduler/appengine/task/utils" |
@@ -356,7 +357,7 @@ func (m TaskManager) checkTaskStatus(c context.Context, ctl task.Controller) err |
// still running LaunchTask when saving the invocation, it will only make the |
// matters worse. |
case status == task.StatusStarting: |
- return errors.WrapTransient(errors.New("invocation is still starting, try again later")) |
+ return errors.New("invocation is still starting, try again later", transient.Tag) |
case status != task.StatusRunning: |
return fmt.Errorf("unexpected invocation status %q, expecting %q", status, task.StatusRunning) |
} |
@@ -377,7 +378,7 @@ func (m TaskManager) checkTaskStatus(c context.Context, ctl task.Controller) err |
if err != nil { |
ctl.DebugLog("Failed to fetch task results - %s", err) |
err = utils.WrapAPIError(err) |
- if !errors.IsTransient(err) { |
+ if !transient.Tag.In(err) { |
ctl.State().Status = task.StatusFailed |
} |
return err |