Commit ca1f34f
[manila_create_default_resources] Fix extra_specs string vs dict handling
When extra_specs is passed via extra_vars on the command line
(e.g. -e 'extra_specs={}'), Ansible receives it as a string instead
of a dict. The original task-level vars: block evaluated
extra_specs.items() before the when: condition was checked, causing
the play to fail with 'str object has no attribute items'.
Split into a set_fact task guarded by 'extra_specs is mapping' and a
separate command task guarded by 'extra_spec_opt is defined' to handle
both dict and string inputs safely.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: lkuchlan <lkuchlan@redhat.com>1 parent 00f43d7 commit ca1f34f
1 file changed
Lines changed: 7 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
24 | 30 | | |
| 31 | + | |
25 | 32 | | |
26 | 33 | | |
27 | 34 | | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | 35 | | |
33 | 36 | | |
34 | 37 | | |
0 commit comments