Skip to content

Instantly share code, notes, and snippets.

@ganeshrn
Last active March 22, 2021 12:45
Show Gist options
  • Save ganeshrn/3ca4db5143d6c508f43c3ee8fd167c73 to your computer and use it in GitHub Desktop.
Save ganeshrn/3ca4db5143d6c508f43c3ee8fd167c73 to your computer and use it in GitHub Desktop.
netconf __init__.py diff
$git diff lib/ansible/plugins/netconf/__init__.py
diff --git a/lib/ansible/plugins/netconf/__init__.py b/lib/ansible/plugins/netconf/__init__.py
index 95442e60e9..24d04c6b82 100644
--- a/lib/ansible/plugins/netconf/__init__.py
+++ b/lib/ansible/plugins/netconf/__init__.py
@@ -32,8 +32,11 @@ try:
from ncclient.xml_ import to_xml, to_ele, NCElement
HAS_NCCLIENT = True
NCCLIENT_IMP_ERR = None
-except (ImportError, AttributeError) as err: # paramiko and gssapi are incompatible and raise AttributeError not ImportError
- HAS_NCCLIENT = False
+# paramiko and gssapi are incompatible and raise AttributeError not ImportError
+# When running in FIPS mode, cryptography raises InternalError
+# https://bugzilla.redhat.com/show_bug.cgi?id=1778939
+except Exception as err:
+ HAS_NCCLIENT = False
NCCLIENT_IMP_ERR = err
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment