diff --git a/fdroidserver/__main__.py b/fdroidserver/__main__.py index 2c863d27..9a088516 100755 --- a/fdroidserver/__main__.py +++ b/fdroidserver/__main__.py @@ -134,7 +134,7 @@ def main(): sys.exit(0) command = sys.argv[1] - if command not in COMMANDS and command not in available_plugins.keys(): + if command not in COMMANDS and command not in available_plugins: if command in ('-h', '--help'): print_help(available_plugins=available_plugins) sys.exit(0) diff --git a/fdroidserver/metadata.py b/fdroidserver/metadata.py index 6e5c445b..e5f82a69 100644 --- a/fdroidserver/metadata.py +++ b/fdroidserver/metadata.py @@ -504,8 +504,8 @@ def parse_yaml_srclib(metadatapath): cause=e) return thisinfo - for key in data.keys(): - if key not in thisinfo.keys(): + for key in data: + if key not in thisinfo: _warn_or_exception(_("Invalid srclib metadata: unknown key " "'{key}' in '{file}'") .format(key=key, file=metadatapath)) diff --git a/makebuildserver b/makebuildserver index 37889694..39cbba06 100755 --- a/makebuildserver +++ b/makebuildserver @@ -312,7 +312,7 @@ def main(): version=config['basebox_version'])) sys.exit(1) # verify box - if config['basebox_version'] not in BASEBOX_CHECKSUMS.keys(): + if config['basebox_version'] not in BASEBOX_CHECKSUMS: logging.critical("can not verify '{box}', " "unknown basebox version '{version}'" .format(box=config['basebox'], diff --git a/pyproject.toml b/pyproject.toml index 79fe9f3d..489df45b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,6 @@ confidence = ["HIGH", "INFERENCE"] disable = [ "broad-exception-caught", "broad-exception-raised", - "consider-iterating-dictionary", "invalid-name", "missing-class-docstring", "missing-function-docstring",