From bcdfa22248449cfde97c8875af151b0a9a584daf Mon Sep 17 00:00:00 2001 From: Reed Allman Date: Sun, 11 Jun 2017 02:49:42 -0700 Subject: [PATCH] fixes panic, still dk why result and err are nil. need to fix fucked up code --- api/runner/worker.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/api/runner/worker.go b/api/runner/worker.go index 77522684e..5af1a07f5 100644 --- a/api/runner/worker.go +++ b/api/runner/worker.go @@ -2,6 +2,7 @@ package runner import ( "context" + "errors" "fmt" "io" "sync" @@ -96,6 +97,9 @@ func (rnr *Runner) RunTask(ctx context.Context, cfg *task.Config) (drivers.RunRe } resp := <-treq.Response + if resp.Result == nil && resp.Err == nil { + resp.Err = errors.New("error running task with unknown error") + } return resp.Result, resp.Err }