X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=clientbin%2FsfiDeleteAttribute.py;h=d60de403a78942ae9d07df67ae5105af33bb434b;hb=c9e68794de46ad75c8d24ccbf946d14bd33f1626;hp=7e6a5aeba208661bedfa0c9d16e1a981b5545b8b;hpb=cedf37c8661ec0b05349274962bf2db9cfa6a24d;p=sfa.git diff --git a/clientbin/sfiDeleteAttribute.py b/clientbin/sfiDeleteAttribute.py index 7e6a5aeb..d60de403 100755 --- a/clientbin/sfiDeleteAttribute.py +++ b/clientbin/sfiDeleteAttribute.py @@ -1,4 +1,4 @@ -#! /usr/bin/env python +#!/usr/bin/env python3 import sys @@ -28,20 +28,22 @@ if command.opts.infile: nodes = f.read().split() f.close() - for name in attrs: - print >> sys.stderr, name, attrs[name] + print(name, attrs[name], file=sys.stderr) for value in attrs[name]: if not nodes: try: rspec.version.remove_default_sliver_attribute(name, value) except: - logger.log_exc("sfiDeleteAttribute FAILED on all nodes: %s=%s" % (name, value)) + logger.log_exc( + "sfiDeleteAttribute FAILED on all nodes: %s=%s" % (name, value)) else: for node in nodes: try: - rspec.version.remove_sliver_attribute(node, name, value) + rspec.version.remove_sliver_attribute( + node, name, value) except: - logger.log_exc("sfiDeleteAttribute FAILED on node %s: %s=%s" % (node, name, value)) + logger.log_exc( + "sfiDeleteAttribute FAILED on node %s: %s=%s" % (node, name, value)) - print rspec.toxml() + print(rspec.toxml())