diff --git a/CHANGELOG_PENDING.md b/CHANGELOG_PENDING.md index 80b326a9..db5b3070 100644 --- a/CHANGELOG_PENDING.md +++ b/CHANGELOG_PENDING.md @@ -3,3 +3,6 @@ - [features] add "pulumi.organiztion" to the built-in "pulumi" variable to obtain the current organization. ### Bug Fixes + +- Parse the items property on config type declarations to prevent diagnostic messages about + unknown fields [#615](https://github.com/pulumi/pulumi-yaml/pull/615) diff --git a/pkg/pulumiyaml/ast/template.go b/pkg/pulumiyaml/ast/template.go index 20f98884..3357e237 100644 --- a/pkg/pulumiyaml/ast/template.go +++ b/pkg/pulumiyaml/ast/template.go @@ -276,6 +276,7 @@ type ConfigParamDecl struct { Secret *BooleanExpr Default Expr Value Expr + Items *ConfigParamDecl } func (d *ConfigParamDecl) recordSyntax() *syntax.Node { diff --git a/pkg/pulumiyaml/ast/template_test.go b/pkg/pulumiyaml/ast/template_test.go index 8f64edd3..b8966c2d 100644 --- a/pkg/pulumiyaml/ast/template_test.go +++ b/pkg/pulumiyaml/ast/template_test.go @@ -16,6 +16,23 @@ import ( const example = ` name: simple-yaml runtime: yaml +config: + some-string-array: + type: array + value: + - subnet1 + - subnet2 + - subnet3 + items: + type: string + some-nested-array: + type: array + items: + type: array + items: + type: string + some-boolean: + type: boolean resources: my-bucket: type: aws:s3/bucket:Bucket