From 33939758cbf7f6c4d831822b7ac0e8eab0fc5dad Mon Sep 17 00:00:00 2001 From: mstatkevych Date: Thu, 24 Aug 2023 22:23:29 +0300 Subject: [PATCH] add failsafe for scripts --- pkg/run/run.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pkg/run/run.go b/pkg/run/run.go index b6a347b..c5173ae 100644 --- a/pkg/run/run.go +++ b/pkg/run/run.go @@ -13,7 +13,7 @@ type Output struct { type Schema struct { Results map[string]float64 `json:"results"` - Labels map[string]string `json:"labels"` + Labels map[string]string `json:"labels"` } func (o *Output) RunJob(p *Params) { @@ -27,12 +27,14 @@ func (o *Output) RunExec(path *string) { out, err := exec.Command(*path).Output() if err != nil { - log.Fatal(err) + log.Print(*path) + log.Print(err) } err = json.Unmarshal(out, &o.Schema) if err != nil { - log.Fatal(err) + log.Print(*path) + log.Print(err) } }