Skip to content

Instantly share code, notes, and snippets.

@willbeason
Created September 1, 2021 17:26
Show Gist options
  • Save willbeason/cb37f922b8e028711af69375828a5339 to your computer and use it in GitHub Desktop.
Save willbeason/cb37f922b8e028711af69375828a5339 to your computer and use it in GitHub Desktop.
panic: cannot deep copy int
goroutine 1 [running]:
k8s.io/apimachinery/pkg/runtime.DeepCopyJSONValue({0x16bc1a0, 0x27a2578})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/runtime/converter.go:469 +0x273
k8s.io/apimachinery/pkg/runtime.DeepCopyJSONValue({0x1714aa0, 0xc0005c24e0})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/runtime/converter.go:453 +0x345
k8s.io/apimachinery/pkg/runtime.DeepCopyJSONValue({0x1682300, 0xc0004ffc50})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/runtime/converter.go:463 +0x2bd
k8s.io/apimachinery/pkg/runtime.DeepCopyJSONValue({0x1714aa0, 0xc0005c24b0})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/runtime/converter.go:453 +0x345
k8s.io/apimachinery/pkg/runtime.DeepCopyJSONValue({0x1714aa0, 0xc0005c2420})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/runtime/converter.go:453 +0x345
k8s.io/apimachinery/pkg/runtime.DeepCopyJSONValue({0x1714aa0, 0xc0005c2240})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/runtime/converter.go:453 +0x345
k8s.io/apimachinery/pkg/runtime.DeepCopyJSON(...)
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/runtime/converter.go:438
k8s.io/apimachinery/pkg/apis/meta/v1/unstructured.(*Unstructured).DeepCopy(0xc000217678)
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/unstructured.go:146 +0x65
github.com/open-policy-agent/frameworks/constraint/pkg/client.(*Client).AddConstraint(0xc000238d70, {0x1b2cd00, 0xc0000400a8}, 0xc000217678)
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/github.com/open-policy-agent/frameworks/constraint/pkg/client/client.go:573 +0x414
github.com/open-policy-agent/gatekeeper/pkg/gktest.(*Runner).addConstraint(0xc000a87c18, {0x1b2cd00, 0xc0000400a8}, {0xc000688f00, 0x14f25683}, {0xc000235ca0, 0x0}, {0x1b2ce88, 0xc000238d70})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/pkg/gktest/runner.go:116 +0x152
github.com/open-policy-agent/gatekeeper/pkg/gktest.(*Runner).makeTestClient(0xc000a87c18, {0x1b2cd00, 0xc0000400a8}, {0xc000688f00, 0x2b}, {{0xc00013bfa0, 0xe}, {0xc00012a870, 0x13}, {0xc000235ca0, ...}, ...})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/pkg/gktest/runner.go:98 +0x165
github.com/open-policy-agent/gatekeeper/pkg/gktest.(*Runner).runCases(0x1714aa0, {0x1b2cd00, 0xc0000400a8}, {0xc000688f00, 0x2b}, {}, {{0xc00013bfa0, 0xe}, {0xc00012a870, 0x13}, ...})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/pkg/gktest/runner.go:70 +0x96
github.com/open-policy-agent/gatekeeper/pkg/gktest.(*Runner).runTest(0x66562d, {0x1b2cd00, 0xc0000400a8}, {0xc000688f00, 0x2b}, {}, {{0xc00013bfa0, 0xe}, {0xc00012a870, 0x13}, ...})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/pkg/gktest/runner.go:57 +0x10a
github.com/open-policy-agent/gatekeeper/pkg/gktest.(*Runner).runTests(0x0, {0x1b2cd00, 0xc0000400a8}, {}, {0xc000688f00, 0xc000595b78}, {0xc0000cf440, 0x3, 0xc0})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/pkg/gktest/runner.go:46 +0x185
github.com/open-policy-agent/gatekeeper/pkg/gktest.(*Runner).Run(0xc000d2dd18, {0x1b2cd00, 0xc0000400a8}, {}, {0xc000688f00, 0x36}, 0xc0000cec60)
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/pkg/gktest/runner.go:29 +0xe5
github.com/open-policy-agent/gatekeeper/cmd/gator/test.runSuites({0x1b2cd00, 0xc0000400a8}, {0x1b034a0, 0xc00011d3d0}, 0xc000118a50, {})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/cmd/gator/test/test.go:106 +0x145
github.com/open-policy-agent/gatekeeper/cmd/gator/test.runE(0x282fbc0, {0xc0003cb840, 0x2, 0x2})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/cmd/gator/test/test.go:91 +0x1f9
github.com/spf13/cobra.(*Command).execute(0x282fbc0, {0xc0003cb800, 0x2, 0x2})
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/github.com/spf13/cobra/command.go:852 +0x60e
github.com/spf13/cobra.(*Command).ExecuteC(0x282fe40)
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/github.com/spf13/cobra/command.go:960 +0x3ad
github.com/spf13/cobra.(*Command).Execute(...)
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/vendor/github.com/spf13/cobra/command.go:897
main.main()
/usr/local/google/home/willbeason/go/src/github.com/open-policy-agent/gatekeeper/cmd/gator/gator.go:26 +0x25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment