pan-os-ansible icon indicating copy to clipboard operation
pan-os-ansible copied to clipboard

fix(panos_static_route): invalid nexthop for none value

Open alperenkose opened this issue 4 months ago • 0 comments

Description

This PR fixes issue with "none" value for nexthop_type in panos_static_route.

This change also requires pan-os-python to accept 'none' value for the nexthop type, proposed on the following PR: https://github.com/PaloAltoNetworks/pan-os-python/pull/578

Motivation and Context

With the recent change in pan-os-ansible, it fetches default values from pan-os-python sdk while creating or updating objects with None value params. In the existing implementation "none" string value was converted to None in the module and fetching default value from pan-os-python sdk (which is 'ip-address') for this lead to a invalid config. With this change "none" string value is passed as-is to the pan-os-python and it is also proposed to accept "none" value for the nexthop type in the linked PR.

Fixes #584

How Has This Been Tested?

Tested live on VMSeries firewalls and Panorama.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)

Checklist

  • [ ] I have updated the documentation accordingly.
  • [ ] I have read the CONTRIBUTING document.
  • [ ] I have added tests to cover my changes if appropriate.
  • [ ] All new and existing tests passed.

alperenkose avatar Oct 10 '24 12:10 alperenkose