Improve panic error message to include the parse error.

This commit is contained in:
Brian Pursley
2023-01-18 21:37:13 -05:00
parent dbc11a43a8
commit ace8132edc

View File

@@ -609,7 +609,7 @@ func initSchema() {
if customSchema != nil {
err := parse(customSchema, JsonOrYaml)
if err != nil {
panic("invalid schema file")
panic(fmt.Errorf("invalid schema file: %w", err))
}
} else {
if kubernetesOpenAPIVersion == "" {