| |
@@ -38,7 +38,7 @@
|
| |
from requests.adapters import HTTPAdapter
|
| |
from requests.exceptions import ConnectionError
|
| |
|
| |
- from oraculum import app, db, CACHE
|
| |
+ from oraculum import app, db, CACHE, BUGZILLA
|
| |
from oraculum.models.dashboard_users import DashboardUserData
|
| |
|
| |
def get_fedora_releases():
|
| |
@@ -420,31 +420,28 @@
|
| |
return data
|
| |
|
| |
def get_blocker_trackers():
|
| |
- bzapi = bugzilla.Bugzilla("bugzilla.redhat.com")
|
| |
tracker_ids = []
|
| |
releases = CACHE.get('fedora_releases')
|
| |
if releases["branched"]:
|
| |
- tracker_ids.append(bzapi.getbug("F%sBetaBlocker" % releases["branched"]).id)
|
| |
- tracker_ids.append(bzapi.getbug("F%sFinalBlocker" % releases["branched"]).id)
|
| |
- tracker_ids.append(bzapi.getbug("F%sBetaBlocker" % releases["rawhide"]).id)
|
| |
- tracker_ids.append(bzapi.getbug("F%sFinalBlocker" % releases["rawhide"]).id)
|
| |
+ tracker_ids.append(BUGZILLA.getbug("F%sBetaBlocker" % releases["branched"]).id)
|
| |
+ tracker_ids.append(BUGZILLA.getbug("F%sFinalBlocker" % releases["branched"]).id)
|
| |
+ tracker_ids.append(BUGZILLA.getbug("F%sBetaBlocker" % releases["rawhide"]).id)
|
| |
+ tracker_ids.append(BUGZILLA.getbug("F%sFinalBlocker" % releases["rawhide"]).id)
|
| |
return tracker_ids
|
| |
|
| |
def get_fti_trackers():
|
| |
- bzapi = bugzilla.Bugzilla("bugzilla.redhat.com")
|
| |
tracker_ids = []
|
| |
releases = CACHE.get('fedora_releases')["values"]
|
| |
for release in releases:
|
| |
- tracker_ids.append(bzapi.getbug("F%sFailsToInstall" % release).id)
|
| |
+ tracker_ids.append(BUGZILLA.getbug("F%sFailsToInstall" % release).id)
|
| |
return tracker_ids
|
| |
|
| |
|
| |
def get_ftbfs_trackers():
|
| |
- bzapi = bugzilla.Bugzilla("bugzilla.redhat.com")
|
| |
tracker_ids = []
|
| |
releases = CACHE.get('fedora_releases')["values"]
|
| |
for release in releases:
|
| |
- tracker_ids.append(bzapi.getbug("F%sFTBFS" % release).id)
|
| |
+ tracker_ids.append(BUGZILLA.getbug("F%sFTBFS" % release).id)
|
| |
return tracker_ids
|
| |
|
| |
|
| |
@@ -453,12 +450,11 @@
|
| |
Returns all open Bugs for a single package
|
| |
"""
|
| |
data = []
|
| |
- bzapi = bugzilla.Bugzilla("bugzilla.redhat.com")
|
| |
- query = bzapi.url_to_query("https://bugzilla.redhat.com/buglist.cgi?bug_status=NEW&bug_status=__open__&"
|
| |
+ query = BUGZILLA.url_to_query("https://bugzilla.redhat.com/buglist.cgi?bug_status=NEW&bug_status=__open__&"
|
| |
"classification=Fedora&product=Fedora&product=Fedora EPEL&component=%s" % urllib.parse.quote(package))
|
| |
query["include_fields"] = ['blocks', 'comments', 'creation_time', 'creator', 'id', 'keywords', 'last_change_time',
|
| |
'severity', 'priority', 'status', 'summary', 'version', 'whiteboard']
|
| |
- bugs = bzapi.query(query)
|
| |
+ bugs = BUGZILLA.query(query)
|
| |
if len(bugs) == 0:
|
| |
return []
|
| |
ftbfs_trackers = set(CACHE.get('ftbfs_trackers'))
|
| |
We don't log in, we don't need it