mirror of
https://gitlab.com/fdroid/fdroidserver.git
synced 2024-11-04 22:40:12 +01:00
Fix pylint warnings
This commit is contained in:
parent
ff44488a42
commit
a872d8688d
@ -99,6 +99,7 @@ class ReproducibleZipInfo(zipfile.ZipInfo):
|
|||||||
_override = {} # type: Dict[str, Union[int, Tuple[int, ...]]]
|
_override = {} # type: Dict[str, Union[int, Tuple[int, ...]]]
|
||||||
|
|
||||||
def __init__(self, zinfo, **override):
|
def __init__(self, zinfo, **override):
|
||||||
|
super().__init__()
|
||||||
if override:
|
if override:
|
||||||
self._override = {**self._override, **override}
|
self._override = {**self._override, **override}
|
||||||
for k in self.__slots__:
|
for k in self.__slots__:
|
||||||
|
@ -48,6 +48,8 @@ try:
|
|||||||
except ImportError:
|
except ImportError:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
buildserverid = None
|
||||||
|
|
||||||
|
|
||||||
# Note that 'force' here also implies test mode.
|
# Note that 'force' here also implies test mode.
|
||||||
def build_server(app, build, vcs, build_dir, output_dir, log_dir, force):
|
def build_server(app, build, vcs, build_dir, output_dir, log_dir, force):
|
||||||
@ -951,7 +953,6 @@ def parse_commandline():
|
|||||||
|
|
||||||
options = None
|
options = None
|
||||||
config = None
|
config = None
|
||||||
buildserverid = None
|
|
||||||
fdroidserverid = None
|
fdroidserverid = None
|
||||||
start_timestamp = time.gmtime()
|
start_timestamp = time.gmtime()
|
||||||
status_output = None
|
status_output = None
|
||||||
|
@ -3257,6 +3257,7 @@ class ClonedZipInfo(zipfile.ZipInfo):
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
def __init__(self, zinfo):
|
def __init__(self, zinfo):
|
||||||
|
super().__init__()
|
||||||
self.original = zinfo
|
self.original = zinfo
|
||||||
for k in self.__slots__:
|
for k in self.__slots__:
|
||||||
try:
|
try:
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
class FDroidException(Exception):
|
class FDroidException(Exception):
|
||||||
def __init__(self, value=None, detail=None):
|
def __init__(self, value=None, detail=None):
|
||||||
|
super().__init__()
|
||||||
self.value = value
|
self.value = value
|
||||||
self.detail = detail
|
self.detail = detail
|
||||||
|
|
||||||
@ -23,6 +24,7 @@ class FDroidException(Exception):
|
|||||||
|
|
||||||
class MetaDataException(Exception):
|
class MetaDataException(Exception):
|
||||||
def __init__(self, value):
|
def __init__(self, value):
|
||||||
|
super().__init__()
|
||||||
self.value = value
|
self.value = value
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
|
@ -105,6 +105,7 @@ class Tail(object):
|
|||||||
|
|
||||||
class TailError(Exception):
|
class TailError(Exception):
|
||||||
def __init__(self, msg):
|
def __init__(self, msg):
|
||||||
|
super().__init__()
|
||||||
self.message = msg
|
self.message = msg
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
|
@ -2177,10 +2177,11 @@ def main():
|
|||||||
apks += files
|
apks += files
|
||||||
appid_has_apks = set()
|
appid_has_apks = set()
|
||||||
appid_has_repo_files = set()
|
appid_has_repo_files = set()
|
||||||
|
remove_apks = []
|
||||||
for apk in apks:
|
for apk in apks:
|
||||||
to_remove = get_apks_without_allowed_signatures(apps.get(apk['packageName']), apk)
|
to_remove = get_apks_without_allowed_signatures(apps.get(apk['packageName']), apk)
|
||||||
if to_remove:
|
if to_remove:
|
||||||
apks.remove(apk)
|
remove_apks.append(apk)
|
||||||
logging.warning(
|
logging.warning(
|
||||||
_('"{path}" is signed by a key that is not allowed:').format(
|
_('"{path}" is signed by a key that is not allowed:').format(
|
||||||
path=to_remove
|
path=to_remove
|
||||||
@ -2217,6 +2218,9 @@ def main():
|
|||||||
else:
|
else:
|
||||||
logging.warning(msg + '\n\t' + _('Use `fdroid update -c` to create it.'))
|
logging.warning(msg + '\n\t' + _('Use `fdroid update -c` to create it.'))
|
||||||
|
|
||||||
|
for apk in remove_apks:
|
||||||
|
apks.remove(apk)
|
||||||
|
|
||||||
mismatch_errors = ''
|
mismatch_errors = ''
|
||||||
for appid in appid_has_apks:
|
for appid in appid_has_apks:
|
||||||
if appid in appid_has_repo_files:
|
if appid in appid_has_repo_files:
|
||||||
|
Loading…
Reference in New Issue
Block a user