Skip to content

Commit

Permalink
improve error message for loading files listed under crds
Browse files Browse the repository at this point in the history
  • Loading branch information
Liujingfang1 committed Mar 5, 2019
1 parent 76c6655 commit 28cefb3
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/transformers/config/factorycrd.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import (

"github.com/ghodss/yaml"
"github.com/go-openapi/spec"
"github.com/pkg/errors"
"k8s.io/kube-openapi/pkg/common"
"sigs.k8s.io/kustomize/pkg/gvk"
"sigs.k8s.io/kustomize/pkg/ifc"
Expand All @@ -41,7 +42,7 @@ func LoadConfigFromCRDs(
}
m, err := makeNameToApiMap(content)
if err != nil {
return nil, err
return nil, errors.Wrapf(err, "unable to parse open API definition from '%s'", path)
}
otherTc, err := makeConfigFromApiMap(m)
if err != nil {
Expand Down

0 comments on commit 28cefb3

Please sign in to comment.