l.b.e._.ExternalBugTracker : class documentation

Part of lp.bugs.externalbugtracker View In Hierarchy

Base class for an external bug tracker.
Method __init__ Undocumented
Method getExternalBugTrackerToUse See IExternalBugTracker.
Method getCurrentDBTime See IExternalBugTracker.
Method getModifiedRemoteBugs See IExternalBugTracker.
Method initializeRemoteBugDB See IExternalBugTracker.
Method getRemoteBug Retrieve and return a single bug from the remote database.
Method getRemoteBugBatch Retrieve and return a set of bugs from the remote database.
Method getRemoteImportance Return the remote importance for the given bug id.
Method getRemoteStatus Return the remote status for the given bug id.
Method getRemoteProduct Return the remote product for a given bug.
Method makeRequest Make a request.
Method _getHeaders Undocumented
Method _getPage GET the specified page on the remote HTTP server.
Method _postPage POST to the specified page and form.
def __init__(self, baseurl):
Undocumented
def getExternalBugTrackerToUse(self):
See IExternalBugTracker.
def getCurrentDBTime(self):
See IExternalBugTracker.
def getModifiedRemoteBugs(self, bug_ids, last_accessed):
See IExternalBugTracker.
def initializeRemoteBugDB(self, bug_ids):
See IExternalBugTracker.
def getRemoteBug(self, bug_id):
Retrieve and return a single bug from the remote database.

The bug is returned as a tuple in the form (id, bug). This ensures that bug ids are formatted correctly for the current ExternalBugTracker. If no data can be found for bug_id, (None, None) will be returned.

A BugTrackerConnectError will be raised if anything goes wrong.

def getRemoteBugBatch(self, bug_ids):
Retrieve and return a set of bugs from the remote database.

A BugTrackerConnectError will be raised if anything goes wrong.

def getRemoteImportance(self, bug_id):
Return the remote importance for the given bug id.

Raise BugNotFound if the bug can't be found. Raise InvalidBugId if the bug id has an unexpected format. Raise UnparsableBugData if the bug data cannot be parsed.

def getRemoteStatus(self, bug_id):
Return the remote status for the given bug id.

Raise BugNotFound if the bug can't be found. Raise InvalidBugId if the bug id has an unexpected format.

def getRemoteProduct(self, remote_bug):
Return the remote product for a given bug.

See IExternalBugTracker.

def _getHeaders(self):
Undocumented
@ensure_no_transaction
def makeRequest(self, method, url, **kwargs):
Make a request.
ParametersmethodThe HTTP request method.
urlThe URL to request.
ReturnsA requests.Response object.
Raisesrequests.RequestExceptionif the request fails.
def _getPage(self, page, **kwargs):
GET the specified page on the remote HTTP server.
ReturnsA requests.Response object.
def _postPage(self, page, form, repost_on_redirect=False):
POST to the specified page and form.
Parametersformis a dict of form variables being POSTed.
repost_on_redirectoverride RFC-compliant redirect handling. By default, if the POST receives a redirect response, the request to the redirection's target URL will be a GET. If repost_on_redirect is True, this method will do a second POST instead. Do this only if you are sure that repeated POST to this page is safe, as is usually the case with search forms.
ReturnsA requests.Response object.
API Documentation for Launchpad, generated by pydoctor at 2022-06-16 00:00:12.