Skip to content

Commit

Permalink
Merge pull request #484 from runcom/wrapferr
Browse files Browse the repository at this point in the history
pkg/daemon: add more info to errs
  • Loading branch information
openshift-merge-robot committed Mar 1, 2019
2 parents f5ea711 + a67feb5 commit fdf41be
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/daemon/daemon.go
Original file line number Diff line number Diff line change
Expand Up @@ -878,11 +878,11 @@ func (dn *Daemon) validateOnDiskState(currentConfig *mcfgv1.MachineConfig) bool
func getRefDigest(ref string) (string, error) {
refParsed, err := imgref.ParseNamed(ref)
if err != nil {
return "", err
return "", errors.Wrapf(err, "parsing reference: %q", ref)
}
canon, ok := refParsed.(imgref.Canonical)
if !ok {
return "", fmt.Errorf("Not canonical form: %s", ref)
return "", fmt.Errorf("not canonical form: %q", ref)
}

return canon.Digest().String(), nil
Expand Down Expand Up @@ -913,7 +913,7 @@ func compareOSImageURL(current, desired string) (bool, error) {
}

if bootedDigest == desiredDigest {
glog.Infof("Current and target osImageURL have matching digest %s", bootedDigest)
glog.Infof("Current and target osImageURL have matching digest %q", bootedDigest)
return true, nil
}

Expand Down

0 comments on commit fdf41be

Please sign in to comment.