#61 Workaround fedora-obsolete-packages missing distag
Merged 3 years ago by frantisekz. Opened 3 years ago by frantisekz.

@@ -101,6 +101,10 @@ 

      split = nevra.split(".")[-1]

      if len(split) <= 1:

          return "Unknown"

+     if "fedora-obsolete-packages" in nevra:

+         # fedora-obsolete-packages does not contain distag, workaround it

+         # eg. "fedora-obsolete-packages-32-51", release is "Fedora 32"

+         return release_from_dist(nevra.split("-")[3])

If it were me, I'd use [-2] instead of [3], but this obviously is a non-issue :)

      return release_from_dist(split)

  

  def release_from_dist(dist):

no initial comment

If it were me, I'd use [-2] instead of [3], but this obviously is a non-issue :)

Pull-Request has been merged by frantisekz

3 years ago
Metadata