Skip to content

Commit

Permalink
[networking_mapper] Make null templates behave like an empty one
Browse files Browse the repository at this point in the history
Now, if the data inside a template network is null the mapper will raise
an unhandled exception, that may be fine, but for this particular case
making null and empty behave the same way will allow the mapper to raise
a meaningful error letting him know the field cannot be empty as some
child elements are mandatory.
  • Loading branch information
pablintino authored and openshift-merge-bot[bot] committed Jun 5, 2024
1 parent d881e09 commit 60d6a1b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/module_utils/net_map/networking_definition.py
Original file line number Diff line number Diff line change
Expand Up @@ -2056,7 +2056,7 @@ def __parse_raw(
for network_name, network_data in child_nets.items():
self.__parse_raw_net(
network_name,
network_data,
network_data or {},
network_definitions,
trunk_parents=set(trunk_parents.keys()),
)
Expand Down

0 comments on commit 60d6a1b

Please sign in to comment.