reduce log verbosity, minor CI fixes, lint (#3157)

* pkg/cwhub: redundant log messages

* CI: fixture output and elapsed time

* CI: preload only essential hub items

* report full version (including -rc2 etc.) with cscli hub update --debug

* lint
This commit is contained in:
mmetc 2024-08-01 10:55:04 +02:00 committed by GitHub
parent 6f5d75c5f1
commit 136dba61d9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
19 changed files with 119 additions and 100 deletions

View file

@ -3,6 +3,7 @@ package exprhelpers
import (
"bufio"
"encoding/base64"
"errors"
"fmt"
"math"
"net"
@ -772,7 +773,7 @@ func ParseKV(params ...any) (any, error) {
matches := keyValuePattern.FindAllStringSubmatch(blob, -1)
if matches == nil {
log.Errorf("could not find any key/value pair in line")
return nil, fmt.Errorf("invalid input format")
return nil, errors.New("invalid input format")
}
if _, ok := target[prefix]; !ok {
target[prefix] = make(map[string]string)
@ -780,7 +781,7 @@ func ParseKV(params ...any) (any, error) {
_, ok := target[prefix].(map[string]string)
if !ok {
log.Errorf("ParseKV: target is not a map[string]string")
return nil, fmt.Errorf("target is not a map[string]string")
return nil, errors.New("target is not a map[string]string")
}
}
for _, match := range matches {