From 8f7ab9b3b33cbb72165559a0bd59916c79fee185 Mon Sep 17 00:00:00 2001 From: jo Date: Sat, 19 Nov 2022 16:56:34 +0100 Subject: [PATCH] chore: fix flake8 warnings Tested-by: Marge Part-of: --- api/tests/data/youtube.py | 2 ++ api/tests/music/conftest.py | 2 ++ docs/serve.py | 2 +- scripts/get-contributions-stats.py | 4 ++-- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/api/tests/data/youtube.py b/api/tests/data/youtube.py index 9c8f9e68f..302f0a02b 100644 --- a/api/tests/data/youtube.py +++ b/api/tests/data/youtube.py @@ -1,3 +1,5 @@ +# flake8: noqa + search = {} diff --git a/api/tests/music/conftest.py b/api/tests/music/conftest.py index 0cb6f4778..dd56f0ca2 100644 --- a/api/tests/music/conftest.py +++ b/api/tests/music/conftest.py @@ -1,3 +1,5 @@ +# flake8: noqa + import pytest _artists = {"search": {}, "get": {}} diff --git a/docs/serve.py b/docs/serve.py index dfc12ebfc..b952f060f 100755 --- a/docs/serve.py +++ b/docs/serve.py @@ -3,7 +3,7 @@ from subprocess import call # initial make call(["python", "-m", "sphinx", ".", "/tmp/_build"]) -from livereload import Server, shell +from livereload import Server, shell # noqa: E402 server = Server() server.watch("..", shell("python -m sphinx . /tmp/_build")) diff --git a/scripts/get-contributions-stats.py b/scripts/get-contributions-stats.py index 7c8e4ffdc..376244d2f 100755 --- a/scripts/get-contributions-stats.py +++ b/scripts/get-contributions-stats.py @@ -69,11 +69,11 @@ def clear_list(inList): outList = list(dict.fromkeys(inList)) try: outList.remove("funkwhale-bot") - except: + except IndexError: pass try: outList.remove("weblate (bot)") - except: + except IndexError: pass outList.sort() return outList