LGTM, thanks
On Wed, Oct 21, 2015 at 5:42 PM, 'Klaus Aehlig' via ganeti-devel <
[email protected]> wrote:
> We need to distinguish between the option not being provided
> (i.e., no change requested) and the option being empty (i.e.,
> a request to reset the value). Therefore, use None as a default,
> not {}.
>
> Signed-off-by: Klaus Aehlig <[email protected]>
> ---
> lib/cli.py | 2 +-
> lib/client/gnt_cluster.py | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/lib/cli.py b/lib/cli.py
> index 2eee68b..81e362a 100644
> --- a/lib/cli.py
> +++ b/lib/cli.py
> @@ -942,7 +942,7 @@ DEFAULT_IALLOCATOR_PARAMS_OPT =
> cli_option("--default-iallocator-params",
> " template:option=value,"
> " option=value,...",
> type="keyval",
> - default={})
> + default=None)
>
> OS_OPT = cli_option("-o", "--os-type", dest="os", help="What OS to run",
> metavar="<os>",
> diff --git a/lib/client/gnt_cluster.py b/lib/client/gnt_cluster.py
> index cc4b990..0ee757f 100644
> --- a/lib/client/gnt_cluster.py
> +++ b/lib/client/gnt_cluster.py
> @@ -1120,7 +1120,7 @@ def SetClusterParams(opts, args):
> opts.add_uids is not None or
> opts.remove_uids is not None or
> opts.default_iallocator is not None or
> - opts.default_iallocator_params or
> + opts.default_iallocator_params is not None or
> opts.reserved_lvs is not None or
> opts.master_netdev is not None or
> opts.master_netmask is not None or
> --
> 2.6.0.rc2.230.g3dd15c0
>
>
Hrvoje Ribicic
Ganeti Engineering
Google Germany GmbH
Dienerstr. 12, 80331, München
Geschäftsführer: Matthew Scott Sucherman, Paul Terence Manicle
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Diese E-Mail ist vertraulich. Wenn Sie nicht der richtige Adressat sind,
leiten Sie diese bitte nicht weiter, informieren Sie den Absender und
löschen Sie die E-Mail und alle Anhänge. Vielen Dank.
This e-mail is confidential. If you are not the right addressee please do
not forward it, please inform the sender, and please erase this e-mail
including any attachments. Thanks.