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

IP-addresses created via addition of FHRP group do not inherit default custom field values #11565

Closed
olegbliaher opened this issue Jan 23, 2023 · 1 comment · Fixed by #11724
Assignees
Labels
status: accepted This issue has been accepted for implementation type: bug A confirmed report of unexpected behavior in the application

Comments

@olegbliaher
Copy link

NetBox version

3.1.10

Python version

3.9

Steps to Reproduce

  1. Create a boolean custom field with a certain default value, for example False, and assign it the ipam | IP address-model.
  2. Add a new FHRP group (IPAM -> FHRP Groups) with a new, unused IP-address under Virtual IP Address.
  3. The new IP-address object attached to the VHRP-group does not have the custom field set, which generates an error when running reports.

Expected Behavior

I'd expect the new IP-address to have the default custom field value.

Observed Behavior

An exception occurred: KeyError: 'my_custom_field' Traceback (most recent call last): File "/usr/lib/netbox/app/extras/reports.py", line 234, in run test_method() File "/usr/local/lib/netbox/reports/my_report.py", line 11, in test_for_field if ip.custom_field_data["my_custom_field"]: 'my_custom_field'

@olegbliaher olegbliaher added the type: bug A confirmed report of unexpected behavior in the application label Jan 23, 2023
@jeremystretch jeremystretch added the status: needs owner This issue is tentatively accepted pending a volunteer committed to its implementation label Jan 24, 2023
@atownson
Copy link
Contributor

Related to #11040

@kkthxbye-code kkthxbye-code self-assigned this Feb 10, 2023
@kkthxbye-code kkthxbye-code added status: accepted This issue has been accepted for implementation and removed status: needs owner This issue is tentatively accepted pending a volunteer committed to its implementation labels Feb 10, 2023
kkthxbye-code pushed a commit to kkthxbye-code/netbox that referenced this issue Feb 10, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 29, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
status: accepted This issue has been accepted for implementation type: bug A confirmed report of unexpected behavior in the application
Projects
None yet
4 participants