mirror of
https://github.com/go-task/task.git
synced 2025-09-16 09:26:16 +02:00
fix(precondition): do not print error if context was aborted (#1338)
This commit is contained in:
committed by
GitHub
parent
5168e54af7
commit
d741dfe26d
@@ -21,7 +21,9 @@ func (e *Executor) areTaskPreconditionsMet(ctx context.Context, t *taskfile.Task
|
|||||||
Env: env.Get(t),
|
Env: env.Get(t),
|
||||||
})
|
})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
e.Logger.Errf(logger.Magenta, "task: %s\n", p.Msg)
|
if !errors.Is(err, context.Canceled) {
|
||||||
|
e.Logger.Errf(logger.Magenta, "task: %s\n", p.Msg)
|
||||||
|
}
|
||||||
return false, ErrPreconditionFailed
|
return false, ErrPreconditionFailed
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user