Giter VIP home page Giter VIP logo

crd-validation's People

Contributors

ant31 avatar brancz avatar tamalsaha avatar vineeth-thumma avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

crd-validation's Issues

runtime error when trying the example

Hi, I'm trying to validate v1.PodSpec in my crd and luckily I've found this handy tool.

I've tried the example by getting code-generator, checking out to release 1.8 and then go install.
Afterwards, I tried ~/go/bin/openapi-gen -i $(REPO)/v1,k8s.io/apimachinery/pkg/apis/meta/v1,k8s.io/api/core/v1 -p ./v1 --go-header-file="../../.header" and get the following output:

F1112 13:46:16.763309 29062 openapi.go:126] Got nil output package:
goroutine 1 [running]:
k8s.io/code-generator/vendor/github.com/golang/glog.stacks(0xc00a31b500, 0xc00a1d8be0, 0x4c, 0x9d)
/Users/xialei1/go/src/k8s.io/code-generator/vendor/github.com/golang/glog/glog.go:766 +0xb8
k8s.io/code-generator/vendor/github.com/golang/glog.(*loggingT).output(0x19dd700, 0xc000000003, 0xc00a018a80, 0x196886a, 0xa, 0x7e, 0x0)
/Users/xialei1/go/src/k8s.io/code-generator/vendor/github.com/golang/glog/glog.go:717 +0x351
k8s.io/code-generator/vendor/github.com/golang/glog.(*loggingT).printf(0x19dd700, 0xc000000003, 0x15a8984, 0x1a, 0xc0090d7cd0, 0x1, 0x1)
/Users/xialei1/go/src/k8s.io/code-generator/vendor/github.com/golang/glog/glog.go:655 +0x14b
k8s.io/code-generator/vendor/github.com/golang/glog.Fatalf(...)
/Users/xialei1/go/src/k8s.io/code-generator/vendor/github.com/golang/glog/glog.go:1145
k8s.io/code-generator/vendor/k8s.io/kube-openapi/pkg/generators.Packages(0xc00a18ad80, 0xc0004c4380, 0x15a29fc, 0xd, 0xc00a18ad80)
/Users/xialei1/go/src/k8s.io/code-generator/vendor/k8s.io/kube-openapi/pkg/generators/openapi.go:126 +0x6e2
k8s.io/code-generator/vendor/k8s.io/gengo/args.(*GeneratorArgs).Execute(0xc0004c4380, 0xc0090d7e10, 0x15a29fc, 0xd, 0x15c1b40, 0x9c54, 0xfe00)
/Users/xialei1/go/src/k8s.io/code-generator/vendor/k8s.io/gengo/args/args.go:165 +0x207
main.main()
/Users/xialei1/go/src/k8s.io/code-generator/cmd/openapi-gen/main.go:39 +0x242
make: *** [v1/openapi_generated.go] Error 255

I guess it's related to kube-openapi version. Would you specify the environment, such as by adding go.mod?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.