Merge pull request #35246 from jtand/py3_versions_support

Python3 support for versions-report
This commit is contained in:
Mike Place 2016-08-06 16:56:01 +09:00 committed by GitHub
commit a55f46f37f

View File

@ -664,7 +664,7 @@ def versions_report(include_salt_cloud=False):
for ver_type in ('Salt Version', 'Dependency Versions', 'System Versions'):
info.append('{0}:'.format(ver_type))
# List dependencies in alphabetical, case insensitive order
for name in sorted(ver_info[ver_type], cmp=lambda x, y: cmp(x.lower(), y.lower())):
for name in sorted(ver_info[ver_type], key=lambda x: x.lower()):
ver = fmt.format(name,
ver_info[ver_type][name] or 'Not Installed',
pad=padding)