ACK/cmnt: [PATCH] swm: promote_to_updates.py: check for snap tasks before closing tb

Khaled Elmously khalid.elmously at canonical.com
Wed Jan 31 19:29:31 UTC 2018


On 2017-12-18 09:34:14 , Kleber Sacilotto de Souza wrote:
> Do not close the tracking bug until all the snap-related tasks are
> either Invalid or Fix Released.
> 
> Signed-off-by: Kleber Sacilotto de Souza <kleber.souza at canonical.com>
> ---
>  stable/wfl/wft/promote_to_updates.py | 9 +++++++++
>  1 file changed, 9 insertions(+)
> 
> diff --git a/stable/wfl/wft/promote_to_updates.py b/stable/wfl/wft/promote_to_updates.py
> index d0377cf4..29f6c393 100644
> --- a/stable/wfl/wft/promote_to_updates.py
> +++ b/stable/wfl/wft/promote_to_updates.py
> @@ -141,6 +141,15 @@ class PromoteToUpdates(Promoter):
>                      cinfo('            package promote-to-security status (%s) does not match security-signoff status (%s)' % (promote_to_security.status, security_signoff.status), 'yellow')
>                      break
>  
> +                # Check that all snap tasks are either "Invalid" or "Fix Released"
> +                snap_done = True
> +                for taskname in s.bug.tasks_by_name:
> +                    if taskname.startswith('snap-') and s.bug.tasks_by_name[taskname].status not in ['Invalid', 'Fix Released']:
> +                        cinfo('            %s is neither "Fix Released" nor "Invalid" (%s)' % (taskname, s.bug.tasks_by_name[taskname].status), 'yellow')
> +                        snap_done = False
> +                if not snap_done:
> +                    break
> +
>              # All is completed so we can finally close out this workflow bug.
>              s.bug.tasks_by_name[s.bug.workflow_project].status = 'Fix Released'
>              if promote_to_updates.status == 'Invalid':



I don't know much about the 'snap-related tasks' - but could they also end up as 'Won't fix" ?

Either way:
Acked-by: Khalid Elmously <khalid.elmously at canonical.com>





More information about the kernel-team mailing list