Use print() as function under contrib/

This fixes the remaining Python 3 syntax errors, so re-enable compileall
for contrib/ again.
This commit is contained in:
Marius Gedminas
2015-08-28 09:18:13 +03:00
parent aa5f96d28d
commit 3f9879aedb
28 changed files with 105 additions and 96 deletions

View File

@@ -53,10 +53,10 @@ class SoftLayerInventory(object):
if self.args.list:
self.get_all_servers()
print self.json_format_dict(self.inventory, True)
print(self.json_format_dict(self.inventory, True))
elif self.args.host:
self.get_virtual_servers()
print self.json_format_dict(self.inventory["_meta"]["hostvars"][self.args.host], True)
print(self.json_format_dict(self.inventory["_meta"]["hostvars"][self.args.host], True))
def to_safe(self, word):
'''Converts 'bad' characters in a string to underscores so they can be used as Ansible groups'''