Repository navigation
Restore salt.utils.network.nm_managed and rh_ip deferral to nm_ip - #70380
Merged
dwoz merged 3 commits intoNov 13, 2026
Merged
Conversation
twangboy
previously approved these changes
Oct 9, 2026
twangboy
requested changes
Oct 29, 2026
twangboy
left a comment
Contributor
There was a problem hiding this comment.
Could you validate that assessment?
charzl
force-pushed
the
charzl/fix/70354-nm-managed-3008.x
branch
from
October 29, 2026 21:25
250024c to
6b293b5
Compare
nm_ip.__virtual__ calls salt.utils.network.nm_managed(), which is missing on 3008.x, so nm_ip fails to load with "module 'salt.utils.network' has no attribute 'nm_managed'" on every run. The 3007.x -> 3008.x merge brought in nm_ip.py but reverted the network.py helper and the rh_ip.py change that makes rh_ip defer to nm_ip. Restore the helper and rh_ip.py from 3007.x, and add the nm_ip tests plus tests for nm_managed and the rh_ip deferral. Fixes saltstack#70354
Use 'or' so a host with only one of ifup/ifdown stays with rh_ip, as the docstring says. Add tests for the ifup-only and ifdown-only cases.
charzl
force-pushed
the
charzl/fix/70354-nm-managed-3008.x
branch
from
November 12, 2026 20:27
86becd5 to
a45e1bc
Compare
twangboy
approved these changes
Nov 12, 2026
This branch was previously deployed
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
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.
What does this PR do?
nm_ip.__virtual__callssalt.utils.network.nm_managed(), which does not exist on 3008.x, sonm_ipfails to load on every run:nm_managed()and the matchingrh_ipchange were added together withnm_ipin 149f343 (3006.x) and are present on 3006.x and 3007.x. They did not make it into 3008.x: in the 3007.x -> 3008.x merge (#70132, merge commit 17c1f44)nm_ip.pycame in, butsalt/utils/network.pyandsalt/modules/rh_ip.pyended up identical to the previous 3008.x versions. 3008.x had not touched either file since the merge base, so a plain 3-way merge would have taken the 3007.x changes.Restoring only the helper would silence the log, but
rh_ipwould still claimipon EL10 (noifdown), so both modules would compete for it. This PR restores both:salt/utils/network.py: addnm_managed()(same as 3007.x)salt/modules/rh_ip.py: restored from 3007.x, sorh_ipdefers tonm_ipagaintest_nm_ip.py; add tests fornm_managedand therh_ipdeferral70354.fixed.mdNot touched: the same merge also dropped the
UnicodeErrorhandling inis_reachable_host(7d709d0) and its tests. That is a separate issue and not part of this PR.What issues does this PR fix or reference?
Fixes #70354
Previous Behavior
nm_ipfails to load on 3008.x;rh_ipdoes not defer to it.New Behavior
nm_iploads on NetworkManager hosts withoutifup/ifdown;rh_ipdefers to it there.Merge requirements satisfied?