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
When using a dynamic string list for attribute "macs" where index values dynamicaly change it produces an error when executing apply, however the deviceprofile assigment to the respective devices mac address are executed
To Reproduce
Steps to reproduce the behavior:
Create, update or refresh '.....' resource or datasource
Configure the resource/datasource with the following HCL configuration (paste the HCL configuration, remove any sensitive information)
Use Terraform Apply / Refresh / ... command
See error
Expected behavior
A clear and concise description of what you expected to happen.
Error Message
Error: Provider produced inconsistent result after apply
When applying changes to mist_org_deviceprofile_assign.deviceprofile_ap_45_assign, provider "provider["registry.terraform.io/juniper/mist"]" produced an unexpected new value: .macs[1]: was
cty.StringVal("7090410295d1"), but now cty.StringVal("7090410296ad").
This is a bug in the provider, which should be reported in the provider's own issue tracker.
Software
OS: Windows
Terraform Version [e.g. v1.9.7]
Provider Version [e.g. v0.2.6]
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
Hi @nunopp,
This may be because the macs attribute is a "List" (ordered). I can try to change it to a "Set" (unordered).
Currently the processing of the response tries to keep the same order between the plan and the state (Mist can change the macs order in the response), but it seems this approach is not working in your case.
Can you just explain how do you generate the "dynamic string list"?
Hi @tmunzer, yes it sounds that the order is changing, I think that is because I use this to enable or not the devices that use this device profile, I'm using a csv file (which is the device mac address inventory) to then include or not the mac address for this field (DP = device profile)
ap_inventory = csvdecode(local.csv_data)
DP_list = [for item in local.ap_inventory : item["DP"]]
then inside the resource > macs = local.DP_list
fir for #70
in some condition the assigned/unassigned devices process may fail on the Mist side, and the list of MAC addresses returned may not match what is expected. This case was not processed by the provider, resulting a "This is a bug in the provider, which should be reported in the provider's own issue tracker." error message.
The provider is now returning a specific warning when it was not able to unassign a device, and a specific error when it was not able to assign a device
Describe the bug
When using a dynamic string list for attribute "macs" where index values dynamicaly change it produces an error when executing apply, however the deviceprofile assigment to the respective devices mac address are executed
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A clear and concise description of what you expected to happen.
Error Message
Error: Provider produced inconsistent result after apply
When applying changes to mist_org_deviceprofile_assign.deviceprofile_ap_45_assign, provider "provider["registry.terraform.io/juniper/mist"]" produced an unexpected new value: .macs[1]: was
cty.StringVal("7090410295d1"), but now cty.StringVal("7090410296ad").
This is a bug in the provider, which should be reported in the provider's own issue tracker.
Software
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: