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 ordering when checking insync #166

Merged
merged 1 commit into from
Jun 13, 2018
Merged

Fix ordering when checking insync #166

merged 1 commit into from
Jun 13, 2018

Conversation

markeganfuller
Copy link
Contributor

is is not guaranteed to be sorted so we need to sort it before comparing to should.sort

Initially noticed on Centos 7.4 with zone interfaces:

# c7.3
$ firewall-cmd --permanent --list-interfaces --zone=trusted
eno1 enp22s0 enp2s0f0 enp4s0 enp6s0f0 enp80s0f0 ens1 ens1f0 ens2f0 ens6
# c7.4
$ firewall-cmd --permanent --list-interfaces --zone=trusted
ens6 enp2s0f0 ens1 enp22s0 enp4s0 enp6s0f0 eno1 ens2f0 ens1f0 enp80s0f0

Firewalld returns the output of a Python <dict>.keys() call which gives a non random but arbitrary order.

`is` is not guaranteed to be sorted so we need to sort it before
comparing to `should.sort`
@crayfishx crayfishx added accepted bug Something isn't working labels Feb 26, 2018
@crayfishx crayfishx added this to the 3.4.1 milestone Feb 26, 2018
@crayfishx
Copy link
Contributor

Thanks for the contribution @markeganfuller - this makes sense, I'll verify the above and then get this merged - looks good though.

@crayfishx crayfishx modified the milestones: 3.4.1, 3.5.0 May 10, 2018
@crayfishx crayfishx merged commit 0561230 into voxpupuli:master Jun 13, 2018
@markeganfuller markeganfuller deleted the fix_ordering branch June 13, 2018 09:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants