#9662 Few improvements for ftbfs-fti and mass-rebuild-close-bugs
Merged 4 months ago by mohanboddu. Opened 4 months ago by ignatenkobrain.
ignatenkobrain/releng ftbfs-fti  into  master

@@ -251,7 +251,7 @@ 

          for pkg, rules in pkg_rules.items():

              if re.search(r"^rust-.*-devel$", pkg):

                  continue

-             if pkg.startswith("dummy-test-packagep"):

+             if pkg.startswith("dummy-test-package"):

                  continue

  

              # All direct problems will be in the first rule
@@ -378,9 +378,10 @@ 

      orphaned = {

          src: b

          for src, b in current_ftis.items()

-         if b.assigned_to == "extras-orphan@fedoraproject.org"

+         if pkg_owners["rpms"][src]["fedora"] == "orphan"

      }

      for src, b in orphaned.items():

+         click.echo(f"Checking if need to send notice to the orphaned package: {src} ({b.id})", err=True)

          comments = b.getcomments()

          update = False

          try:

@@ -2,7 +2,7 @@ 

  # SPDX-License-Identifier: MIT

  

  import argparse

- from datetime import datetime

+ from datetime import datetime, timezone

  import logging

  import queue

  import threading
@@ -15,7 +15,7 @@ 

  LOGGER = logging.getLogger(__name__)

  

  def koji2datetime(d):

-     return datetime.strptime(d, "%Y-%m-%d %H:%M:%S.%f")

+     return datetime.fromisoformat(d)

  

  def bug2str(bug):

      return f"{bug.id} ({bug.summary})"
@@ -90,7 +90,7 @@ 

          args.threads = multiprocessing.cpu_count()

  

      massrebuild = rebuilds_info[args.release]

-     rebuild_time = koji2datetime(massrebuild["epoch"])

+     rebuild_time = koji2datetime(massrebuild["epoch"]).replace(tzinfo=timezone.utc)

  

      bz = bugzilla.Bugzilla("https://bugzilla.redhat.com")

      ks = koji.ClientSession("https://koji.fedoraproject.org/kojihub")

no initial comment

rebased onto 871bf80

4 months ago

Pull-Request has been merged by mohanboddu

4 months ago