Commit 2556424d authored by Iustin Pop's avatar Iustin Pop
Browse files

Small style fixes (' vs ") in network code



This is just trivial fixes; I think I caught all of them.
Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
parent 417ab39c
#
#
# Copyright (C) 2011 Google Inc.
# Copyright (C) 2011, 2012 Google Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
......@@ -90,10 +90,10 @@ def MapNetwork(opts, args):
mode = args[2]
link = args[3]
#TODO: allow comma separated group names
if groups == 'all':
# TODO: allow comma separated group names
if groups == "all":
cl = GetClient()
(groups, ) = cl.QueryGroups([], ['name'], False)
(groups, ) = cl.QueryGroups([], ["name"], False)
else:
groups = [groups]
......@@ -120,9 +120,9 @@ def UnmapNetwork(opts, args):
groups = args[1]
#TODO: allow comma separated group names
if groups == 'all':
if groups == "all":
cl = GetClient()
(groups, ) = cl.QueryGroups([], ['name'], False)
(groups, ) = cl.QueryGroups([], ["name"], False)
else:
groups = [groups]
......
......@@ -15973,7 +15973,7 @@ class _NetworkQuery(_QueryBase):
netparams = group.networks[net_uuid]
mode = netparams[constants.NIC_MODE]
link = netparams[constants.NIC_LINK]
info = group.name + '(' + mode + ', ' + link + ')'
info = group.name + "(" + mode + ", " + link + ")"
network_to_groups[net_uuid].append(info)
 
if do_instances:
......
......@@ -1072,8 +1072,8 @@ NIC_IP_POOL = "pool"
NIC_VALID_MODES = frozenset([NIC_MODE_BRIDGED, NIC_MODE_ROUTED])
RESERVE_ACTION = 'reserve'
RELEASE_ACTION = 'release'
RESERVE_ACTION = "reserve"
RELEASE_ACTION = "release"
# An extra description of the network.
# Can be used by hooks/kvm-vif-bridge to apply different rules
......
......@@ -1741,10 +1741,10 @@ class GanetiRapiClient(object): # pylint: disable=R0904
_AppendDryRunIf(query, dry_run)
if add_reserved_ips:
add_reserved_ips = add_reserved_ips.split(',')
add_reserved_ips = add_reserved_ips.split(",")
if tags:
tags = tags.split(',')
tags = tags.split(",")
body = {
"network_name": network_name,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment