Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix attribute Type (for tenant and vlan_group) to Accept int only #1091

Closed
wants to merge 6 commits into from

Conversation

vle99
Copy link

@vle99 vle99 commented Oct 16, 2023

Related Issue

#985

New Behavior

Fix the related issue for the attributes tenant and vlan_group.

Contrast to Current Behavior

Changing the data type of the tenant and vlan_group attribute to integer to meet NetboxAPI standards.
It should not affect the current Behaviour, only fixes the related issue.

Discussion: Benefits and Drawbacks

This change will allow Ansible variables to be passed correctly using Jinja templating. For instance, with a variable tenantid initialized with the value 100, it can be passed as "tenant: {{ tenantid }}". Currently, Ansible would interpret is as a string and due to the parameter "raw" the module accept it as a string. With the propsed change, the module will convert/enforce the datatype to be an integer.

Discussion
There are several more attributes with the datatype "raw". It should be investigated whether these can be simplified to a specific datatype.

Changes to the Documentation

*[] Docs have been updated

Proposed Release Note Entry

Changing data type to meet NetboxAPI standards.

@vle99 vle99 marked this pull request as draft October 16, 2023 13:05
@rodvand rodvand closed this Feb 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants