[elbe-devel] [PATCH 3/4] finetuning: correct messages to losetup

Bastian Germann bage at linutronix.de
Mon Mar 29 14:05:12 CEST 2021


Am 29.03.21 um 13:03 schrieb Torben Hohn:
> These NotImplementedError() should never be raised, because the xml
> schema protects elbe from entering these codepaths.
> 
> Fix them anyways, as they are confusing. The xml tag is called <losetup>,
> not <mount_drive>.
> 
> Signed-off-by: Torben Hohn <torben.hohn at linutronix.de>

Reviewed-by: Bastian Germann <bage at linutronix.de>

> ---
>   elbepack/finetuning.py | 8 ++++----
>   1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/elbepack/finetuning.py b/elbepack/finetuning.py
> index d3968bb68..7a8d5b664 100644
> --- a/elbepack/finetuning.py
> +++ b/elbepack/finetuning.py
> @@ -624,7 +624,7 @@ class ExtractPartitionAction(ImageFinetuningAction):
>   
>       def execute(self, _buildenv, _target):
>           raise NotImplementedError("<extract_partition> may only be "
> -                                  "used in <mount_drive>")
> +                                  "used in <losetup>")
>   
>       def execute_img(self, _buildenv, target, builddir, loop_dev):
>           part_nr = self.node.et.attrib['part']
> @@ -646,7 +646,7 @@ class CopyFromPartition(ImageFinetuningAction):
>   
>       def execute(self, _buildenv, _target):
>           raise NotImplementedError("<copy_from_partition> may only be "
> -                                  "used in <mount_drive>")
> +                                  "used in <losetup>")
>   
>       def execute_img(self, _buildenv, target, builddir, loop_dev):
>           part_nr = self.node.et.attrib['part']
> @@ -682,7 +682,7 @@ class CopyToPartition(ImageFinetuningAction):
>   
>       def execute(self, _buildenv, _target):
>           raise NotImplementedError("<copy_to_partition> may only be "
> -                                  "used in <mount_drive>")
> +                                  "used in <losetup>")
>   
>       def execute_img(self, _buildenv, _target, builddir, loop_dev):
>           part_nr = self.node.et.attrib['part']
> @@ -704,7 +704,7 @@ class SetPartitionTypeAction(ImageFinetuningAction):
>   
>       def execute(self, _buildenv, _target):
>           raise NotImplementedError("<set_partition_type> may only be "
> -                                  "used in <mount_drive>")
> +                                  "used in <losetup>")
>   
>       def execute_img(self, _buildenv, target, builddir, loop_dev):
>           part_nr = self.node.et.attrib['part']
> 


More information about the elbe-devel mailing list