added a comment for package version history and change the login part so it doesnt just say just testing when logging in

This commit is contained in:
Brendan McDevitt 2022-08-18 23:27:51 -05:00
parent 24c474d5df
commit 91c2af27d0

View file

@ -1,15 +1,18 @@
from launchpadlib.launchpad import Launchpad from launchpadlib.launchpad import Launchpad
from collections import defaultdict from collections import defaultdict
class PackageVersionHistory: class PackageVersionHistory:
"""
Use launchpadlib api to query for the package history tree
of a target source_package_name + distro_series
"""
def __init__(self, name, distro_series): def __init__(self, name, distro_series):
self.name = name self.name = name
self.distro_series = distro_series self.distro_series = distro_series
self.launchpad = self.login() self.launchpad = self.login()
def login(self): def login(self):
return Launchpad.login_anonymously('just testing', 'production') return Launchpad.login_anonymously('package_version_history_lookup', 'production')
def set_ubuntu(self): def set_ubuntu(self):
return self.launchpad.distributions['ubuntu'] return self.launchpad.distributions['ubuntu']