Skip to content

When providing empty array of validations the provider returns an inconsistent result #80

@demeyerthom

Description

@demeyerthom
╷
│ Error: Provider produced inconsistent result after apply
│ 
│ When applying changes to contentful_contenttype.example_contenttype, provider "provider[\"registry.terraform.io/labd/contentful\"]" produced an unexpected new value: .fields[0].validations: was cty.ListValEmpty(cty.Object(map[string]cty.Type{"asset_file_size":cty.Object(map[string]cty.Type{"max":cty.Number, "min":cty.Number}), "enabled_marks":cty.List(cty.String),
│ "enabled_node_types":cty.List(cty.String), "in":cty.List(cty.String), "link_content_type":cty.List(cty.String), "link_mimetype_group":cty.List(cty.String), "message":cty.String, "range":cty.Object(map[string]cty.Type{"max":cty.Number, "min":cty.Number}), "regexp":cty.Object(map[string]cty.Type{"pattern":cty.String}), "size":cty.Object(map[string]cty.Type{"max":cty.Number, "min":cty.Number}),
│ "unique":cty.Bool})), but now null.
│ 
│ This is a bug in the provider, which should be reported in the provider's own issue tracker.

Example:

resource "contentful_contenttype" "example_contenttype" {
  space_id      = local.space_id
  environment   = local.environment
  id            = "example_contenttype"
  name          = "example_contenttype"
  description   = "content type description"
  display_field = "content"

  fields = [
    {

      id   = "content"
      name = "Content"
      type = "RichText"
      validations = []
      required = false
    }
  ]
}

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions