summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/get-bugzilla-attachments-by-mimetype17
1 files changed, 14 insertions, 3 deletions
diff --git a/bin/get-bugzilla-attachments-by-mimetype b/bin/get-bugzilla-attachments-by-mimetype
index ef44dbd2caaa..0600ac5bceb9 100755
--- a/bin/get-bugzilla-attachments-by-mimetype
+++ b/bin/get-bugzilla-attachments-by-mimetype
@@ -239,6 +239,19 @@ def get_through_rss_query(queryurl, mimetype, prefix, suffix):
print('looking for all bugs having %s attachment(s)' % mimetype)
process(query, True, get_file_bz_ids(files, prefix))
+#since searching bugs having attachments with specific mimetypes is not available in launchpad API
+#we're iterating over all bugs of the most interesting source packages
+launchpad_pkgs = (
+ "abiword",
+ "calligra",
+ "gnumeric",
+ "inkscape",
+ "koffice",
+ "libreoffice",
+ "openoffice.org",
+ "sk1",
+)
+
def get_launchpad_bugs(prefix):
#launchpadlib python module is required to download launchpad attachments
from launchpadlib.launchpad import Launchpad
@@ -246,9 +259,7 @@ def get_launchpad_bugs(prefix):
launchpad = Launchpad.login_anonymously("attachmentdownload", "production")
ubuntu = launchpad.distributions["ubuntu"]
- #since searching bugs having attachments with specific mimetypes is not available in launchpad API
- #we're iterating over all bugs of the most interesting source packages
- for pkg in ["libreoffice", "openoffice.org", "abiword", "gnumeric", "koffice", "calligra", "inkscape", "sk1"]:
+ for pkg in launchpad_pkgs:
srcpkg = ubuntu.getSourcePackage(name=pkg)
pkgbugs = srcpkg.searchTasks(status=["New", "Fix Committed", "Invalid", "Won't Fix", "Confirmed", "Triaged", "In Progress", "Incomplete", "Incomplete (with response)", "Incomplete (without response)", "Fix Released", "Opinion", "Expired"])