-
Notifications
You must be signed in to change notification settings - Fork 8
fix(nautobot_device_sync): PUC-1441: refactoring #1615
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
stevekeay
reviewed
Jan 20, 2026
components/site-workflows/sensors/sensor-ironic-node-create.yaml
Outdated
Show resolved
Hide resolved
baa37dc to
802bb02
Compare
802bb02 to
4227080
Compare
The port_bios_name_hook sets local_link_connection with string "None" as a placeholder to satisfy Neutron validation. This was passing the `if not switch_info` check and causing unnecessary API calls to Nautobot with `name=None` query parameter. Now skips both Python None and the literal string "None" when looking up switch locations.
- Remove baremetal.node.create.end from event handlers since newly created nodes lack inventory and location data needed for Nautobot - Catch NotFound exception when fetching inventory for nodes that haven't been inspected yet - Skip placeholder "None" string in switch_info (set by port_bios_name_hook for Neutron compatibility) - Return failure with info log when no location available instead of error, as inspection event will trigger proper sync later Nodes will now sync to Nautobot on provision_set.end (after inspection) or update.end events when full data is available.
4227080 to
089971d
Compare
stevekeay
reviewed
Jan 22, 2026
python/understack-workflows/understack_workflows/oslo_event/nautobot_device_sync.py
Outdated
Show resolved
Hide resolved
python/understack-workflows/understack_workflows/oslo_event/nautobot_device_sync.py
Outdated
Show resolved
Hide resolved
python/understack-workflows/understack_workflows/oslo_event/nautobot_device_sync.py
Outdated
Show resolved
Hide resolved
python/understack-workflows/understack_workflows/oslo_event/nautobot_device_sync.py
Outdated
Show resolved
Hide resolved
d3e36e0 to
4192fda
Compare
stevekeay
approved these changes
Jan 23, 2026
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix Nautobot device, interface sync handling placeholder "None" string in switch_info
if not switch_infocheck and causing unnecessary API calls to Nautobot withname=Nonequery parameter).Handle uninspected nodes gracefully (no inventory yet)
Remove event trigger for baremetal.node.create.end
Preserve rack location and position when recreating Nautobot device