diff --git a/lib/client/gnt_network.py b/lib/client/gnt_network.py index 91c1a1a54103cb831a23ab14e6ffa28756dfe7e1..714658214fafafcc37bd4e9e6da0dd04d1bcd9a8 100644 --- a/lib/client/gnt_network.py +++ b/lib/client/gnt_network.py @@ -24,12 +24,13 @@ # W0401: Wildcard import ganeti.cli # W0614: Unused import %s from wildcard import (since we need cli) +import textwrap + from ganeti.cli import * from ganeti import constants from ganeti import opcodes from ganeti import utils from ganeti import errors -from textwrap import wrap #: default list of fields for L{ListNetworks} @@ -215,14 +216,14 @@ def ShowNetworkConfig(_, args): 100 * float(free_count) / float(size)) ToStdout(" Usage map:") idx = 0 - for line in wrap(mapping, width=64): + for line in textwrap.wrap(mapping, width=64): ToStdout(" %s %s %d", str(idx).rjust(3), line.ljust(64), idx + 63) idx += 64 ToStdout(" (X) used (.) free") if ext_res: ToStdout(" externally reserved IPs:") - for line in wrap(ext_res, width=64): + for line in textwrap.wrap(ext_res, width=64): ToStdout(" %s" % line) if group_list: