1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

iptables_state: fix broken query of async_status result (#2671) (#2676)

* use get() rather than querying the key directly

* add a changelog fragment

* re-enable CI tests

* Update changelog fragment

Co-authored-by: Felix Fontein <felix@fontein.de>

Co-authored-by: Felix Fontein <felix@fontein.de>
(cherry picked from commit f09c39b71e)

Co-authored-by: quidame <quidame@poivron.org>
This commit is contained in:
patchback[bot] 2021-05-29 13:58:03 +02:00 committed by GitHub
parent 6b215e3a9c
commit 7483f71d31
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 2 deletions

View file

@ -0,0 +1,6 @@
---
bugfixes:
- "iptables_state - fix a broken query of ``async_status`` result
with current ansible-core development version
(https://github.com/ansible-collections/community.general/issues/2627,
https://github.com/ansible-collections/community.general/pull/2671)."

View file

@ -52,7 +52,7 @@ class ActionModule(ActionBase):
module_args=module_args,
task_vars=task_vars,
wrap_async=False)
if async_result['finished'] == 1:
if async_result.get('finished', 0) == 1:
break
time.sleep(min(1, timeout))

View file

@ -5,4 +5,3 @@ skip/freebsd # no iptables/netfilter (Linux specific)
skip/osx # no iptables/netfilter (Linux specific)
skip/macos # no iptables/netfilter (Linux specific)
skip/aix # no iptables/netfilter (Linux specific)
disabled # FIXME