[elbe-devel] [PATCH 3/3] Fix ValueError in finetuning rm artifact

Torben Hohn torben.hohn at linutronix.de
Wed Aug 7 15:55:27 CEST 2019


On Wed, Aug 07, 2019 at 03:25:33PM +0200, dion at linutronix.de wrote:
> From: Olivier Dion <dion at linutronix.de>
> 
> Signed-off-by: Olivier Dion <dion at linutronix.de>

Reviewed-by: Torben Hohn <torben.hohn at linutronix.de>

> ---
>  elbepack/finetuning.py | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/elbepack/finetuning.py b/elbepack/finetuning.py
> index dd037025..0ea082e9 100644
> --- a/elbepack/finetuning.py
> +++ b/elbepack/finetuning.py
> @@ -511,7 +511,11 @@ class RmArtifactAction(FinetuningAction):
>                                    "used in <project-finetuning>")
>  
>      def execute_prj(self, _log, _buildenv, target, _builddir):
> -        target.images.remove(self.node.et.text)
> +        try:
> +            target.images.remove(self.node.et.text)
> +        except ValueError:
> +            raise FinetuningException("Artifact %s doesn't exist" %
> +                                      self.node.et.text)
>  
>  
>  @FinetuningAction.register('losetup')
> -- 
> 2.11.0
> 
> 
> _______________________________________________
> elbe-devel mailing list
> elbe-devel at linutronix.de
> https://lists.linutronix.de/mailman/listinfo/elbe-devel

-- 
Torben Hohn
Linutronix GmbH | Bahnhofstrasse 3 | D-88690 Uhldingen-Mühlhofen
Phone: +49 7556 25 999 18; Fax.: +49 7556 25 999 99

Hinweise zum Datenschutz finden Sie hier (Informations on data privacy 
can be found here): https://linutronix.de/kontakt/Datenschutz.php

Linutronix GmbH | Firmensitz (Registered Office): Uhldingen-Mühlhofen | 
Registergericht (Registration Court): Amtsgericht Freiburg i.Br., HRB700 
806 | Geschäftsführer (Managing Directors): Heinz Egger, Thomas Gleixner



More information about the elbe-devel mailing list