ERROR: The command failed with an unexpected error. Here is the traceback:
ERROR: Expect <class 'str'>, got {'id': '/subscriptions/ad123456789/resourceGroups/front-door/providers/Microsoft.Network/frontdoorWebApplicationFirewallPolicies/ttkxwaf'} (<class 'dict'>)
Traceback (most recent call last):
File "/usr/lib64/az/lib/python3.9/site-packages/knack/cli.py", line 233, in invoke
cmd_result = self.invocation.execute(args)
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 664, in execute
raise ex
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 731, in _run_jobs_serially
results.append(self._run_job(expanded_arg, cmd_copy))
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 712, in _run_job
result = LongRunningOperation(cmd_copy.cli_ctx, 'Starting {}'.format(cmd_copy.name))(result)
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 1039, in call
result = poller.result()
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_poller.py", line 108, in result
self.wait(timeout)
File "/usr/lib64/az/lib/python3.9/site-packages/azure/core/tracing/decorator.py", line 76, in wrapper_use_tracer
return func(*args, **kwargs)
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_poller.py", line 130, in wait
raise self._exception
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_poller.py", line 83, in _start
for polling_method in self._polling_generator:
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/command_modules/cdn/aaz/latest/afd/security_policy/_update.py", line 122, in _execute_operations
self.pre_operations()
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/command_modules/cdn/custom/custom_afdx.py", line 1321, in pre_operations
args.web_application_firewall = {
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_value.py", line 90, in setattr
self[key] = data
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_value.py", line 76, in setitem
self._data[name] = attr_schema.process_data(data, key=name)
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_type.py", line 234, in process_data
value[key] = sub_data
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_value.py", line 76, in setitem
self._data[name] = attr_schema.process_data(data, key=name)
File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_type.py", line 48, in process_data
raise AAZInvalidValueError('Expect {}, got {} ({})'.format(self.DataType, data, type(data)))
azure.cli.core.aaz.exceptions.AAZInvalidValueError: Expect <class 'str'>, got {'id': '/subscriptions/ad123456789/resourceGroups/front-door/providers/Microsoft.Network/frontdoorWebApplicationFirewallPolicies/ttkxwaf'} (<class 'dict'>)
To check existing issues, please visit: https://github.com/Azure/azure-cli/issues
Describe the bug
os:rocky linux 9.3 ARM { "azure-cli": "2.61.0", "azure-cli-core": "2.61.0", "azure-cli-telemetry": "1.1.0", "extensions": {} }
Related command
az afd security-policy update --resource-group front-door --security-policy-name ttkx --profile-name ttkx-fd --domains '/subscriptions/ad123456789/resourcegroups/front-door/providers/Microsoft.Cdn/profiles/ttkx-fd/customdomains/ttkxsscom'
Errors
ERROR: The command failed with an unexpected error. Here is the traceback: ERROR: Expect <class 'str'>, got {'id': '/subscriptions/ad123456789/resourceGroups/front-door/providers/Microsoft.Network/frontdoorWebApplicationFirewallPolicies/ttkxwaf'} (<class 'dict'>) Traceback (most recent call last): File "/usr/lib64/az/lib/python3.9/site-packages/knack/cli.py", line 233, in invoke cmd_result = self.invocation.execute(args) File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 664, in execute raise ex File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 731, in _run_jobs_serially results.append(self._run_job(expanded_arg, cmd_copy)) File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 712, in _run_job result = LongRunningOperation(cmd_copy.cli_ctx, 'Starting {}'.format(cmd_copy.name))(result) File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/commands/init.py", line 1039, in call result = poller.result() File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_poller.py", line 108, in result self.wait(timeout) File "/usr/lib64/az/lib/python3.9/site-packages/azure/core/tracing/decorator.py", line 76, in wrapper_use_tracer return func(*args, **kwargs) File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_poller.py", line 130, in wait raise self._exception File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_poller.py", line 83, in _start for polling_method in self._polling_generator: File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/command_modules/cdn/aaz/latest/afd/security_policy/_update.py", line 122, in _execute_operations self.pre_operations() File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/command_modules/cdn/custom/custom_afdx.py", line 1321, in pre_operations args.web_application_firewall = { File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_value.py", line 90, in setattr self[key] = data File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_value.py", line 76, in setitem self._data[name] = attr_schema.process_data(data, key=name) File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_type.py", line 234, in process_data value[key] = sub_data File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_value.py", line 76, in setitem self._data[name] = attr_schema.process_data(data, key=name) File "/usr/lib64/az/lib/python3.9/site-packages/azure/cli/core/aaz/_field_type.py", line 48, in process_data raise AAZInvalidValueError('Expect {}, got {} ({})'.format(self.DataType, data, type(data))) azure.cli.core.aaz.exceptions.AAZInvalidValueError: Expect <class 'str'>, got {'id': '/subscriptions/ad123456789/resourceGroups/front-door/providers/Microsoft.Network/frontdoorWebApplicationFirewallPolicies/ttkxwaf'} (<class 'dict'>) To check existing issues, please visit: https://github.com/Azure/azure-cli/issues
Issue script & Debug output
.
Expected behavior
The command should succeed.
Environment Summary
{ "azure-cli": "2.61.0", "azure-cli-core": "2.61.0", "azure-cli-telemetry": "1.1.0", "extensions": {} }
Additional context
No response