Fix errors found by pylint

Signed-off-by: Benjamin Drung <benjamin.drung@canonical.com>
This commit is contained in:
Benjamin Drung 2023-01-31 10:19:24 +01:00
parent ab64467f33
commit 72add78e9d
3 changed files with 7 additions and 4 deletions

View File

@ -104,7 +104,7 @@ def main():
bug_num = int(bug_num)
bug_nums.append(bug_num)
bugs = debianbts.get_status(*bug_nums)
bugs = debianbts.get_status(bug_nums)
if not bugs:
Logger.error("Cannot find any of the listed bugs")

View File

@ -39,7 +39,8 @@ import tempfile
from abc import ABC, abstractmethod
from contextlib import closing
from pathlib import Path
from urllib.request import urljoin, urlopen, urlparse
from urllib.parse import urljoin, urlparse
from urllib.request import urlopen
import debian.deb822
from debian.changelog import Changelog
@ -1046,6 +1047,7 @@ Snapshot = _Snapshot()
class SnapshotPackage(object):
def __init__(self, obj):
self.name = None
self._obj = obj
self._files = None
self._component = None
@ -1206,7 +1208,7 @@ class SnapshotFile(object):
elif "first_seen" in self._obj:
return self._obj["first_seen"]
else:
Logger.error("File {} has no date information", self.name)
Logger.error("File %s has no date information", self.name)
return "unknown"
def getHash(self):
@ -1255,6 +1257,7 @@ class SnapshotSPPH(object):
def __init__(self, snapshot_pkg):
self._pkg = snapshot_pkg
self._changelog = None
# LP API defined fields

View File

@ -433,7 +433,7 @@ class PullPkg(object):
if options["upload_queue"]:
# upload queue API is different/simpler
self.pull_upload_queue(
self.pull_upload_queue( # pylint: disable=missing-kwoa
pull, arch=options["arch"], download_only=options["download_only"], **params
)
return