pingidentity / terraform-provider-davinci

PingOne DaVinci Terraform Provider
https://registry.terraform.io/providers/pingidentity/davinci/latest
Mozilla Public License 2.0
4 stars 1 forks source link

Flow Descriptions are all blank/null #314

Closed dbryar closed 5 months ago

dbryar commented 5 months ago

Community Note

Thank you for opening an issue. Please note that we try to keep the Terraform issue tracker reserved for bug reports and feature requests. For general usage questions, please see: https://www.terraform.io/community.html.

DaVinci Terraform provider Version

0.3.1

Terraform Version

1.4.2

Affected Resource(s)

Terraform Configuration Files

# Copy-paste your DaVinci related Terraform configurations here - for large Terraform configs,
# please use a service like Dropbox and share a link to the ZIP file. For
# security, you can also encrypt the files using our GPG public key.

# Remember to replace any account/customer sensitive information in the configuration before submitting the issue

# NOTE: PLEASE DO NOT share DaVinci JSON exports publicly without encrypting files first.  DaVinci JSON exports can contain environment/tenant specific information, and may also include secrets.
resource "davinci_flow" "fingerprint_device" {
  environment_id = pingone_environment.sandbox.id
  connection_link {
    id   = data.davinci_connection.variables.id
    name = "Variables"
  }
  connection_link {
    id   = data.davinci_connection.functions.id
    name = "Functions"
  }
  connection_link {
    id   = data.davinci_connection.http.id
    name = "Http"
  }
  flow_json = ...
  description = "Check the device fingerprint and last login time to determine the number of login factors required"

Debug Output

╷
│ Error: Provider produced inconsistent result after apply
│ 
│ When applying changes to davinci_flow.fingerprint_device, provider
│ "provider[\"registry.terraform.io/pingidentity/davinci\"]" produced an
│ unexpected new value: .description: was cty.StringVal("Check the device
│ fingerprint and last login time to determine the number of login factors
│ required"), but now null.
│ 
│ This is a bug in the provider, which should be reported in the provider's
│ own issue tracker.

on every flow

Expected Behavior

Should add description to Flows

Actual Behavior

Screenshot 2024-05-29 at 12 35 49 pm

Steps to Reproduce

  1. terraform apply

Important Factoids

We were relying on flowJson.description in 0.2.x but in change to 0.3.x that was being ignored, so added a description field in the block and now we see this error message (all flows)

patrickcping commented 5 months ago

hey @dbryar thanks for raising! I'm still working to reproduce this issue, but I do think that if description is left undefined, falling back to the description value in the flow import is sensible. I'll line this change up for the next minor release