diff --git a/WORKSPACE b/WORKSPACE index caa380b6..e1c4c56e 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -496,8 +496,10 @@ go_repository( go_repository( name = "io_k8s_apimachinery", build_file_proto_mode = "disable", - commit = "08e4eafd6d11", + commit = "731dcecc205498f52a21b12e311af095efb4b188", importpath = "k8s.io/apimachinery", + patches = ["//third_party/go/k8s-apimachinery:fix-kubernetes-bug-87675.patch"], + patch_args = ["-p1"], ) go_repository( diff --git a/third_party/go/k8s-apimachinery/BUILD b/third_party/go/k8s-apimachinery/BUILD new file mode 100644 index 00000000..e69de29b diff --git a/third_party/go/k8s-apimachinery/fix-kubernetes-bug-87675.patch b/third_party/go/k8s-apimachinery/fix-kubernetes-bug-87675.patch new file mode 100644 index 00000000..a4017543 --- /dev/null +++ b/third_party/go/k8s-apimachinery/fix-kubernetes-bug-87675.patch @@ -0,0 +1,14 @@ +diff --git a/pkg/runtime/converter.go b/pkg/runtime/converter.go +index b3e8a53..2489822 100644 +--- a/pkg/runtime/converter.go ++++ b/pkg/runtime/converter.go +@@ -191,6 +191,9 @@ func fromUnstructured(sv, dv reflect.Value) error { + reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + dv.Set(sv.Convert(dt)) + return nil ++ case reflect.Float32, reflect.Float64: ++ dv.Set(sv.Convert(dt)) ++ return nil + } + case reflect.Float32, reflect.Float64: + switch dt.Kind() {