Cool! Nice catch!
LGTM.
Thanks,
Jose
On Apr 16 15:19, Ilias Tsitsimpis wrote:
> In the first branch of 'if' the 'disks' variable is of type
> 'list of tuples' whereas in the second branch ('else') it is
> of type 'list of disk objects'. Fix the second one to agree
> with the first.
>
> Signed-off-by: Ilias Tsitsimpis <[email protected]>
> ---
> lib/cmdlib/instance_storage.py | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/lib/cmdlib/instance_storage.py b/lib/cmdlib/instance_storage.py
> index 1850dd2..91372c7 100644
> --- a/lib/cmdlib/instance_storage.py
> +++ b/lib/cmdlib/instance_storage.py
> @@ -1125,7 +1125,7 @@ def ImageDisks(lu, instance, image, disks=None):
> if disks is None:
> disks = [(0, instance.disks[0])]
> else:
> - disks = map(lambda idx: instance.disks[idx], disks)
> + disks = map(lambda idx: (idx, instance.disks[idx]), disks)
>
> logging.info("Pausing synchronization of disks of instance '%s'",
> instance.name)
> --
> 1.9.1
>
--
Jose Antonio Lopes
Ganeti Engineering
Google Germany GmbH
Dienerstr. 12, 80331, München
Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Geschäftsführer: Graham Law, Christine Elizabeth Flores
Steuernummer: 48/725/00206
Umsatzsteueridentifikationsnummer: DE813741370