mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 01:18:58 +00:00
Py3 compatibility fixes.
This commit is contained in:
parent
e760a983d2
commit
e33e6ec143
@ -14,6 +14,7 @@ import tempfile
|
||||
import time
|
||||
|
||||
# Import 3rd-party libs
|
||||
import salt.ext.six as six
|
||||
from salt.ext.six.moves.urllib.request import urlopen as _urlopen # pylint: disable=no-name-in-module,import-error
|
||||
|
||||
# Import salt libs
|
||||
@ -23,7 +24,6 @@ import salt.utils
|
||||
import salt.utils.minions
|
||||
import salt.wheel
|
||||
import salt.version
|
||||
import salt.ext.six as six
|
||||
|
||||
FINGERPRINT_REGEX = re.compile(r'^([a-f0-9]{2}:){15}([a-f0-9]{2})$')
|
||||
|
||||
@ -434,7 +434,7 @@ def safe_accept(target, expr_form='glob'):
|
||||
ret = ssh_client.cmd(target, 'key.finger', expr_form=expr_form)
|
||||
|
||||
failures = {}
|
||||
for minion, finger in ret.items():
|
||||
for minion, finger in six.iteritems(ret):
|
||||
if not FINGERPRINT_REGEX.match(finger):
|
||||
failures[minion] = finger
|
||||
else:
|
||||
|
Loading…
Reference in New Issue
Block a user