You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a subtle change in behavior from DiffStrategy=Classic to DiffStrategy=PlanState uncovered by the test suite when
testing PlanState in the following PR:
The failing tests highlight a change in how un-schematized fields are exposed to the provider in RawConfig during Read.
Before the change, the user program could have a property set in the inputs that is not present in the schema, and this
property would get inflected into a Pulumi naming convention and get exposed in RawConfig.
It is peculiar that this would happen with an implicit warning:
makeResourceRawConfigClassic would swallow an error from CoerceValue stating:
unexpected attribute "raw_config_value"
And then would continue recovering raw config on the approximate path:
// Once more, choosing to proceed with a slightly incorrect value rather than fail fast.
glog.V(9).Infof("failed to coerce config: %v", err)
return original
Assuming this functionality is very rarely relied on, but if it was needed, we should consider implementing this
differently to avoid triggering the panic in CoerceValue, first splitting the data into schematized and un-schematized
parts, then calling CoerceValue on the schematized parts, and then joining the translated unschematized parts back.
The text was updated successfully, but these errors were encountered:
This is a subtle change in behavior from DiffStrategy=Classic to DiffStrategy=PlanState uncovered by the test suite when
testing PlanState in the following PR:
#1976
The failing tests highlight a change in how un-schematized fields are exposed to the provider in RawConfig during Read.
Before the change, the user program could have a property set in the inputs that is not present in the schema, and this
property would get inflected into a Pulumi naming convention and get exposed in RawConfig.
It is peculiar that this would happen with an implicit warning:
pulumi-terraform-bridge/pkg/tfshim/sdk-v2/cty.go
Line 57 in 98847bf
makeResourceRawConfigClassic would swallow an error from CoerceValue stating:
And then would continue recovering raw config on the approximate path:
Assuming this functionality is very rarely relied on, but if it was needed, we should consider implementing this
differently to avoid triggering the panic in CoerceValue, first splitting the data into schematized and un-schematized
parts, then calling CoerceValue on the schematized parts, and then joining the translated unschematized parts back.
The text was updated successfully, but these errors were encountered: