Skip to content

Commit

Permalink
Fix schema type for Fields and RawExtension (#1086)
Browse files Browse the repository at this point in the history
  • Loading branch information
lblackstone committed Apr 29, 2020
1 parent e83039f commit 5bfc7a9
Show file tree
Hide file tree
Showing 9 changed files with 39 additions and 38 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

### Bug Fixes

- Fix schema type for Fields and RawExtension. (https://github.com/pulumi/pulumi-kubernetes/pull/1086)
- Fix error parsing YAML in python 3.8 (https://github.com/pulumi/pulumi-kubernetes/pull/1079)
- Fix HELM_HOME handling for Helm v3. (https://github.com/pulumi/pulumi-kubernetes/pull/1076)

Expand Down
4 changes: 2 additions & 2 deletions provider/pkg/gen/typegen.go
Original file line number Diff line number Diff line change
Expand Up @@ -808,8 +808,8 @@ func makeSchemaTypeSpec(prop map[string]interface{}, canonicalGroups map[string]
}}
case v1Fields, v1FieldsV1, rawExtension:
return pschema.TypeSpec{
Type: "object",
AdditionalProperties: &pschema.TypeSpec{Ref: "pulumi.json#/Any"},
Type: "object",
Ref: "pulumi.json#/Any",
}
case v1Time, v1MicroTime:
return pschema.TypeSpec{Type: "string"}
Expand Down
10 changes: 5 additions & 5 deletions sdk/go/kubernetes/apps/v1/controllerRevision.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ type ControllerRevision struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrOutput `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data pulumi.MapOutput `pulumi:"data"`
Data pulumi.AnyOutput `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrOutput `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand Down Expand Up @@ -72,7 +72,7 @@ type controllerRevisionState struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion *string `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data map[string]interface{} `pulumi:"data"`
Data interface{} `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind *string `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -85,7 +85,7 @@ type ControllerRevisionState struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrInput
// Data is the serialized representation of the state.
Data pulumi.MapInput
Data pulumi.Input
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrInput
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -102,7 +102,7 @@ type controllerRevisionArgs struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion *string `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data map[string]interface{} `pulumi:"data"`
Data interface{} `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind *string `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -116,7 +116,7 @@ type ControllerRevisionArgs struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrInput
// Data is the serialized representation of the state.
Data pulumi.MapInput
Data pulumi.Input
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrInput
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand Down
8 changes: 4 additions & 4 deletions sdk/go/kubernetes/apps/v1/pulumiTypes.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ type ControllerRevisionType struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion *string `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data map[string]interface{} `pulumi:"data"`
Data interface{} `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind *string `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -43,7 +43,7 @@ type ControllerRevisionTypeArgs struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrInput `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data pulumi.MapInput `pulumi:"data"`
Data pulumi.Input `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrInput `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand Down Expand Up @@ -111,8 +111,8 @@ func (o ControllerRevisionTypeOutput) ApiVersion() pulumi.StringPtrOutput {
}

// Data is the serialized representation of the state.
func (o ControllerRevisionTypeOutput) Data() pulumi.MapOutput {
return o.ApplyT(func(v ControllerRevisionType) map[string]interface{} { return v.Data }).(pulumi.MapOutput)
func (o ControllerRevisionTypeOutput) Data() pulumi.AnyOutput {
return o.ApplyT(func(v ControllerRevisionType) interface{} { return v.Data }).(pulumi.AnyOutput)
}

// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Expand Down
10 changes: 5 additions & 5 deletions sdk/go/kubernetes/apps/v1beta1/controllerRevision.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ type ControllerRevision struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrOutput `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data pulumi.MapOutput `pulumi:"data"`
Data pulumi.AnyOutput `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrOutput `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand Down Expand Up @@ -72,7 +72,7 @@ type controllerRevisionState struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion *string `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data map[string]interface{} `pulumi:"data"`
Data interface{} `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind *string `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -85,7 +85,7 @@ type ControllerRevisionState struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrInput
// Data is the serialized representation of the state.
Data pulumi.MapInput
Data pulumi.Input
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrInput
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -102,7 +102,7 @@ type controllerRevisionArgs struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion *string `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data map[string]interface{} `pulumi:"data"`
Data interface{} `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind *string `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -116,7 +116,7 @@ type ControllerRevisionArgs struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrInput
// Data is the serialized representation of the state.
Data pulumi.MapInput
Data pulumi.Input
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrInput
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand Down
8 changes: 4 additions & 4 deletions sdk/go/kubernetes/apps/v1beta1/pulumiTypes.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ type ControllerRevisionType struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion *string `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data map[string]interface{} `pulumi:"data"`
Data interface{} `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind *string `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand All @@ -43,7 +43,7 @@ type ControllerRevisionTypeArgs struct {
// APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
ApiVersion pulumi.StringPtrInput `pulumi:"apiVersion"`
// Data is the serialized representation of the state.
Data pulumi.MapInput `pulumi:"data"`
Data pulumi.Input `pulumi:"data"`
// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Kind pulumi.StringPtrInput `pulumi:"kind"`
// Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
Expand Down Expand Up @@ -111,8 +111,8 @@ func (o ControllerRevisionTypeOutput) ApiVersion() pulumi.StringPtrOutput {
}

// Data is the serialized representation of the state.
func (o ControllerRevisionTypeOutput) Data() pulumi.MapOutput {
return o.ApplyT(func(v ControllerRevisionType) map[string]interface{} { return v.Data }).(pulumi.MapOutput)
func (o ControllerRevisionTypeOutput) Data() pulumi.AnyOutput {
return o.ApplyT(func(v ControllerRevisionType) interface{} { return v.Data }).(pulumi.AnyOutput)
}

// Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
Expand Down
Loading

0 comments on commit 5bfc7a9

Please sign in to comment.