We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f893691 commit ced4fabCopy full SHA for ced4fab
2 files changed
changelogs/fragments/six.yml
@@ -0,0 +1,2 @@
1
+bugfixes:
2
+ - "Avoid importing ``ansible.module_utils.six`` (https://github.com/felixfontein/ansible-acme/pull/112)."
plugins/filter/_substitute_dns.py
@@ -56,8 +56,9 @@
56
type: string
57
'''
58
59
+import sys
60
+
61
from ansible.errors import AnsibleFilterError
-from ansible.module_utils.six import string_types
62
from ansible.module_utils.common.text.converters import to_text, to_native
63
64
try:
@@ -66,6 +67,11 @@
66
67
# Python 2.x compat
68
from collections import Mapping
69
70
+if sys.version_info >= (3,):
71
+ string_types = (str,)
72
+else:
73
+ string_types = basestring # pylint: disable=undefined-variable
74
75
76
def substitute_dns(name, substitution_map):
77
if not isinstance(name, string_types):
0 commit comments