[kteam-tools][PATCH 1/1] linux-package-cleaner: Renamed linux-meta-cleaner and added additional packages.

Stefan Bader stefan.bader at canonical.com
Tue Jun 5 18:27:04 UTC 2018


On 08.05.2018 11:03, Joseph Salisbury wrote:
> Renamed the script and added the linux-signed and linux-hwe packages.  The
> script will move any packages defined in it to the linux package.
> 
> Signed-off-by: Joseph Salisbury <joseph.salisbury at canonical.com>
> ---

I think it looks ok, but would be even more appreciative if the description text
at the top of the file would be made into something more usable than the default
tutorial description...

-Stefan

>  ...nux-meta-cleaner => linux-package-cleaner} | 35 +++++++++++--------
>  1 file changed, 20 insertions(+), 15 deletions(-)
>  rename bugs/{linux-meta-cleaner => linux-package-cleaner} (67%)
> 
> diff --git a/bugs/linux-meta-cleaner b/bugs/linux-package-cleaner
> similarity index 67%
> rename from bugs/linux-meta-cleaner
> rename to bugs/linux-package-cleaner
> index f44324b8..10e88d11 100755
> --- a/bugs/linux-meta-cleaner
> +++ b/bugs/linux-package-cleaner
> @@ -13,9 +13,9 @@
>  from lpltk.LaunchpadService          import LaunchpadService
>  from datetime                        import datetime
>  
> -# LinuxMetaCleaner
> +# LinuxPackageCleaner
>  #
> -class LinuxMetaCleaner():
> +class LinuxPackageCleaner():
>      # main
>      #
>      def main(self):
> @@ -28,6 +28,8 @@ class LinuxMetaCleaner():
>          distro        = lp.distributions['ubuntu']
>          linux_package = distro.get_source_package('linux')
>          meta_package  = distro.get_source_package('linux-meta')
> +        signed_package  = distro.get_source_package('linux-signed')
> +        hwe_package  = distro.get_source_package('linux-hwe')
>  
>          # Searching for bug tasks, the search can be quite complicated and made up
>          # of several components. The following can be combined in many ways to get
> @@ -40,21 +42,24 @@ class LinuxMetaCleaner():
>          search_tags            = ['-kj-triage'] # A list of the tags we care about
>          search_tags_combinator = "All"
>          search_status          = ["New", "Confirmed"] # A list of the bug statuses that we care about
> -        tasks = meta_package.search_tasks(status=search_status, tags=search_tags, tags_combinator=search_tags_combinator)
> -
> -        for task in tasks:
> -            try:
> -                # Temp. Hack
> -                task.target = linux_package.lp_source_package
> -                bug = task.bug
> -                print(bug.id)
> -            except:
> -                bug = task.bug
> -                print(bug.id)
> -                print("  *** Warning: Exception thrown while processing %s" % (bug.id))
> +        packages_to_clean = {meta_package, signed_package, hwe_package}
> +
> +        for key in packages_to_clean:
> +            tasks = key.search_tasks(status=search_status, tags=search_tags, tags_combinator=search_tags_combinator)
> +        
> +            for task in tasks:
> +                try:
> +                    # Temp. Hack
> +                    task.target = linux_package.lp_source_package
> +                    bug = task.bug
> +                    print(bug.id)
> +                except:
> +                    bug = task.bug
> +                    print(bug.id)
> +                    print("  *** Warning: Exception thrown while processing %s" % (bug.id))
>  
>  if __name__ == '__main__':
> -    app = LinuxMetaCleaner()
> +    app = LinuxPackageCleaner()
>      app.main()
>  
>  # vi:set ts=4 sw=4 expandtab:
> 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20180605/c0f635df/attachment.sig>


More information about the kernel-team mailing list