fixing case issues with the logging of my errors

Signed-off-by: Robert Sirchia <rsirchia@outlook.com>
pull/30603/head
Robert Sirchia 7 months ago
parent 848c134e0c
commit 4422000330
No known key found for this signature in database
GPG Key ID: C2D40F4D8196E874

@ -51,7 +51,7 @@ func processDependencyConditions(reqs []*chart.Dependency, cvals Values, cpath s
slog.Warn("returned non-bool value", "path", c, "chart", r.Name) slog.Warn("returned non-bool value", "path", c, "chart", r.Name)
} else if _, ok := err.(ErrNoValue); !ok { } else if _, ok := err.(ErrNoValue); !ok {
// this is a real error // this is a real error
slog.Error("pathValue returned error", slog.Any("err", err)) slog.Error("the method PathValue returned error", slog.Any("err", err))
} }
} }
} }
@ -254,7 +254,7 @@ func processImportValues(c *chart.Chart, merge bool) error {
// get child table // get child table
vv, err := cvals.Table(r.Name + "." + child) vv, err := cvals.Table(r.Name + "." + child)
if err != nil { if err != nil {
slog.Error("importValues missing table from chart", "chart", r.Name, "value", err) slog.Error("ImportValues missing table from chart", "chart", r.Name, "value", err)
continue continue
} }
// create value map from child to be merged into parent // create value map from child to be merged into parent
@ -271,7 +271,7 @@ func processImportValues(c *chart.Chart, merge bool) error {
}) })
vm, err := cvals.Table(r.Name + "." + child) vm, err := cvals.Table(r.Name + "." + child)
if err != nil { if err != nil {
slog.Error("importValues missing table", slog.Any("err", err)) slog.Error("ImportValues missing table", slog.Any("err", err))
continue continue
} }
if merge { if merge {

@ -176,12 +176,12 @@ func tplFun(parent *template.Template, includedNames map[string]int, strict bool
// text string. (Maybe we could use a hash appended to the name?) // text string. (Maybe we could use a hash appended to the name?)
t, err = t.New(parent.Name()).Parse(tpl) t, err = t.New(parent.Name()).Parse(tpl)
if err != nil { if err != nil {
return "", errors.Wrapf(err, "Cannot parse template %q", tpl) return "", errors.Wrapf(err, "cannot parse template %q", tpl)
} }
var buf strings.Builder var buf strings.Builder
if err := t.Execute(&buf, vals); err != nil { if err := t.Execute(&buf, vals); err != nil {
return "", errors.Wrapf(err, "Error during tpl function execution for %q", tpl) return "", errors.Wrapf(err, "error during tpl function execution for %q", tpl)
} }
// See comment in renderWithReferences explaining the <no value> hack. // See comment in renderWithReferences explaining the <no value> hack.

Loading…
Cancel
Save